MoI discussion forum
MoI discussion forum

Full Version: CustomUI

Show messages:  1-6  7-26  27-46  47-66  67-86  87-106  107-126  …  507-522

From: Max Smirnov (SMIRNOV)
10 Feb 2014   [#47]
Hi BurrMan,
The Objects folder in the MoI folder is just an example. Object library plugin can use any folder specified in the ObjLibrary.cfg.htm
Could you test the plugin with a different folders?
From: DannyT (DANTAS)
10 Feb 2014   [#48] In reply to [#46]
>I'd recommend putting these folders inside the %AppData%\Moi folder

I have to agree, not liking storing stuff in the applications install directory.

-
From: BurrMan
10 Feb 2014   [#49] In reply to [#47]
Hi Max,
So I created a folder inside of MoI's install dir and it didn't work. However I created one on my desktop and it did work.

So maybe we need to just setup a "my docs" folder? Or a means to set the path from inside the plug.
From: Michael Gibson
10 Feb 2014   [#50] In reply to [#46]
Hi Burr,

> But there should also be a means to keep them in the install folder.

So probably it would be best to have the same behavior as moi.ini - by default moi.ini will get created in %AppData%\Moi , for these same reasons such as not running into permissions problems with not being able to write to Program files by default.

But before doing that, MoI checks if there is an existing moi.ini file in the same directory as moi.exe , and if that exists and has write access then it uses that one.

- Michael
From: BurrMan
10 Feb 2014   [#51] In reply to [#50]
I havnt tested it yet, but I'm assuming that Max's plug works great "as-is" on a usb stick.

So, a means to select the user folders for snapshot and objects. Can this be done from his plug with a dialogue? or does it have to be a hand edit?

Maybe these can be set the same as the exepath entry in the inifile that he's doing now?
From: BurrMan
10 Feb 2014   [#52] In reply to [#51]
Now that I think about it, setting the path to somewhere else and storing it in the ini file is probably good. I wouldn't want to have to lug around a 10 gig "object data store".... :o

Of course, it works great on a usb stick with no mods made. Just tested.

I suppose I could live with manually setting the data paths.... I really want to see the cloth script! lol
From: DannyT (DANTAS)
10 Feb 2014   [#53]
Anyone know how to change the snapshots path in '84 Snapshot.htm' ?

Cheers
~Danny~
From: Max Smirnov (SMIRNOV)
10 Feb 2014   [#54] In reply to [#53]
Hi DannyT,

You can change the path manually.
Open "84 Snapshot.htm" with notepad and change this line
code:
var Path =  moi.command.getOption('ExePath', false) + "\\snapshots\\";

to this (for example)
code:
var Path =  "D:\\My photo gallery\\3D\\Snapshots\\";

You have to use double-slashes. And don't forget to put \\ at the end of the path.
From: Tommy (THOMASHELZLE)
10 Feb 2014   [#55] In reply to [#27]
> Hi Tommy,

> > I personally enjoy MoI 10 times more now with Max' script installed

> It's cool that it has made things so much better for you!

> Are there some particular plug-ins that you are using very frequently for your work? Which ones are they?

> - Michael

It's kind of part of a bigger topic for me, but here you go:

In one kind of work I do, I let myself be inspired by basic forms or certain functions, create an object out of them and then see if I can make them into interesting images, more like a photographer (using Thea Render) than like an engineer.
So for me all the generator scripts are very useful, interesting and inspiring.
For instance, this image is a Loft between the different Levels of a Hilbert Curve:
http://www.screendream.de/
(BTW. It's also an example of an object that hits the limits of 32 Bit - MoI is hardly able to build and export it. ;-) ).

But there are many other cases. One time I need a sinus curve, another time the spherical points may come in handy or a baseball.
Since I work freelance in a wide range of jobs and topics, I never know what I will need next time, so having all possible options easily accessible multiplies the usefulness of MoI and I will turn to it with more confidence.
At the same time, having all these scripts may also help me creating my own or extending one if need should be.

If the "external scripts" menu in Max' script would have some way of sorting into categories with submenues (in the best case simply from file system folders), it would be basically all I ever need from such a plugins menu.


Several things in MoI are rather hidden in the default GUI, so for instance I hardly ever use the lighting options, but with Max' script they are right at hand so I will remember to actually use them to better visualize certain surfaces.


The object library is something I'm used to from many other applications, Thea Render for instance has a brilliantly integrated library for materials, objects, textures, lights etc. and that makes scene setup much faster, so again, this part of Max' plugin will encourage me to save certain parts I use more often. In theory I could save such objects into some folder and import them, but having them close at hand in this menu makes it much more obvious.


What it all boils down to: I'm used to working with Softimage XSI, Lightwave and other much more complex tools than MoI, so complexity isn't something I have a problem with, as long as it is well presented. What I HAVE problems with is, if existing functions or possibilities are hidden under the hood or missing from the interface.

It's not so much a case of this or that script being especially useful, but the sheer wealth of scripts being usable in a well integrated way makes MoI applicable to more situations.

I believe that by trying too hard to keep MoI simple it actually can go the other way. :-)
I would be happy with an "expert view" I guess.

But that's another discussion entirely... ;-)

YMMV of course.

Cheers,

Tom
From: Michael Gibson
10 Feb 2014   [#56] In reply to [#55]
Hi Tom, basically the main goal behind MoI is to make it quick and simple to draw basic models, not really to be a big accumulation of a whole bunch of different tools just gathered together swiss army knife fashion...

That's why a "script organizer" just has not been a big priority so far. I do expect to get it to something along those lines in the future though, but there are only so many hours in the day and there are much more basic fundamental tools that I'm focused on first since they have a wider application to MoI's main goal.


> I would be happy with an "expert view" I guess.

Well, I guess you have exactly that with Max's CustomUI extension right here, don't you?


Basically I'm still right now in the process of working more on the fundamental tools in MoI, I just have not yet had the time to focus a lot of effort on extensions and scriptability, although as you can see from Max's work there is a lot you can do with scripting already right now. At some point in the future I should be able to focus a lot more attention on the general area of scripting and make a lot of improvements geared towards that, including stuff for helping both script authors and also consumers of scritps as well. But only once I've got more of the fundamentals covered to a greater degree.

- Michael
From: DannyT (DANTAS)
10 Feb 2014   [#57] In reply to [#54]
Hi Max,

>You can change the path manually.

Thanks for that, I knew where to find it I just didn't know how it should be formatted, all clear now.

Cheers
~Danny~
From: BurrMan
10 Feb 2014   [#58] In reply to [#57]
Hi Max,
So I created a copy of the 82 ExtScripts file in the customui folder so I can set a second path/menu option for scripts I store in the MoI scripts folder, outside of the commands folder.

Everything works great. I cant find the name for the commandbar item. The original produces a name of "Ext.Scripts". I thought it was from the base64 icon, but I decoded that to change and it was only the gears.

Can you describe where that name is derived, or how to get it to read Ext.Scripts_B or something like that?

Thanks
From: Max Smirnov (SMIRNOV)
10 Feb 2014   [#59] In reply to [#58]
Hi BurrMan
:) The name is right after the icon code.
code:
<moi:CommandMenuButton menu="customui/mods/ExtScriptsFull.menu.htm" icon="data:image/png;base64,...icon....">Ext.scripts</moi:CommandMenuButton>

From: BurrMan
10 Feb 2014   [#60] In reply to [#59]
Thanks Max.
Sorry about that. I don't know how I missed it....
From: BurrMan
10 Feb 2014   [#61] In reply to [#41]
Hi Shayno,

"""""""""Can I change the snapshot.htm to save as a jpg rather than a png ?""""""""""""""

Open the "84 Snapshot.htm" from the customui folder, file in notepad and look for this line towards the bottom:

vp.render(w, h).save(Path+time+"-["+vp.name+"].png");

Change the png to jpg and save the file.
From: BurrMan
10 Feb 2014   [#62] In reply to [#61]
So I did an experiment with creating some sub folders to organize my scripts and commands. It's not exactly what you would think it should be, but it works.

I've basically got "every command and script there is".... (lol)

What I would like is more of a set of categories than one huge list with 200 commands in it.

Since the script isn't reading "folders" and such (it may change later) I just used "added buttons" on the command bar, each pointing to sub folders, where I can organize my scripts into categories.

The only pitfall is you have to leave copies of all the commands and scripts in the original places also, if you want to access them from "MoI" to, and not just Max's plug.

It involves creating copies of the 2 script ui files and making a couple hand edits, then creating your sub folders and putting copies of your group of scripts in there.

If anyone was interested, I'd make a short video to explain it.
From: BurrMan
10 Feb 2014   [#63] In reply to [#62]
Hi Michael,
I was wondering what this does to MoI's "run commands and scripts differently" mechanism....

I know there needs to be a difference in running inline scripts and commands etc, but was wondering what happens to this when things are run through Max's plugin? Like, are the inline scripts in my scripts folder being run as commands now, when launched with Max's plug? Or, if I put commands, in a subfolder system, which Max's plug can access, are they then run out of commands control and only running as inline scripts?

Thanks for any help you have on this.
From: DannyT (DANTAS)
11 Feb 2014   [#64] In reply to [#54]
Hi Max,

> to this (for example)
code:
var Path =  "D:\\My photo gallery\\3D\\Snapshots\\"


Thanks for that...perfect!

Cheers
From: Michael Gibson
11 Feb 2014   [#65] In reply to [#63]
Hi Burr,

> I was wondering what this does to MoI's "run commands and scripts differently" mechanism....

It shouldn't really do anything to it... the plugin uses the same controls that MoI's regular UI uses, so it should behave the same as other things.


> but was wondering what happens to this when things are run through Max's plugin?

Which part of the plug-in are you asking about? Which particular module I mean.


> Like, are the inline scripts in my scripts folder being run as commands now, when launched with Max's plug?

I wouldn't think so... But which part of the plug-in runs scripts from your scripts folder?

Normally only things in the commands folder are run as a command.


> Or, if I put commands, in a subfolder system, which Max's plug can access, are they then
> run out of commands control and only running as inline scripts?

I guess I'm not really sure of the details here... can you maybe be a little more specific about the exact subfolder that you're talking about (under "commands" ? Or under somewhere else? and what part of the plug-in handles this piece that you're asking about?

- Michael
From: BurrMan
11 Feb 2014   [#66] In reply to [#65]
Hi Michael,
I reefing to this part of the plug here:
""""""""""""""ExtScripts
--------------
This addon dynamically generates list of all external scripts. Also it adds to the list some "hidden" MoI commands.
There is another version of this addon - ExtScriptsFull. It works exactly as ExtScripts, but It loads all MoI commands.
You can open ExtScripts.menu.htm(ExtScriptsFull.menu.htm) with Notepad and edit "maxlines" value ( default 50 ) to change the maximum number of lines."""""""""""""""""

THis is the one that generates a flyout with commands listed in it. It traverses the MoI commands folder for this.

I keep my inline scripts in the MoI "Scripts" folder, which MoI looks in also, but you had mentioned before that scripts in there will be handled differently.

I altered Max's plug to also grab my inline scripts from MoI's Scripts folder, and also did some experiments with generating some extra sub folders in there too. Max's plug will actually grab them from my "my documents" folder if I direct it to.

So I guess I was just wondering if they run in the context they would normally be run as if MoI was running them with it's default behavior..

Show messages:  1-6  7-26  27-46  47-66  67-86  87-106  107-126  …  507-522