Page 1 of 1

Brush saving/restoring! Tool Swap! QuickMask!

Posted: 21 Jun 2006, 22:37
by lemec
I've made a pair of scripts that you can use in your own scripts or as part of a CP macro. These will save/load the current brush to a slot in the user config.

One particular use for this is to save your current brush before executing a complex macro that may use all manner of different tools and settings, and then restore your brush afterwards!

*doh* grg extensions aren't allowed and I'm too lazy to zip them...

http://www.digitalartoasis.com/viewtopic.php?p=321#321

Posted: 21 Jun 2006, 23:12
by ZigOtto
it saves the brush (tool and shape) but not the color, neither when it's a custom (cut) brush,
I wonder, storing it in the brush bin isn't it a better way ?

Posted: 21 Jun 2006, 23:21
by lemec
Ah... but the special thing about this tool is it saves all your opacity/size/etc settings.

I figure that there are other commands available in the CP panel that a person could add manually, and there may be cases where you wouldn't want to have your brush colour automatically retrieved/stored.

Of course, you can do all this with tv_getAPen and tv_setAPen...

See, this tool will also know the difference between the airbrush and penbrush and propelling pencil, etc...

If you were using the penbrush and you saved it with this tool, and then you ran a script that were to put you onto a filled shape tool, or onto the airbrush, when you restored the tool, it would put you back onto the penbrush and restore all the settings.

It also performs the save dynamically -- something that CP panel buttons alone don't do. CP Panel buttons can only retrieve the tool they were set to use when they were created/edited.

The main use of this tool is for automation and macros -- being able to store a tool and switch back to it later...

If you wanted to, with a little bit of modification, you could easily create a macro to switch between the two most recently used tools (much like how the eraser end of the stylus works)

Posted: 21 Jun 2006, 23:36
by lemec
It's easy! see?

This one lets you swap between the stored tool and your current tool!
http://www.digitalartoasis.com/viewtopic.php?p=322#322

This script is a good example of what's possible with the new TVP-only command: tv_getActiveTool, one of several sdk additions I pestered poor Hervé for...

This command deserves to be the next wiki addition...

Posted: 21 Jun 2006, 23:55
by lemec

Posted: 22 Jun 2006, 00:52
by ZigOtto
lemec wrote:It's easy! see?

This one lets you swap between the stored tool and your current tool!
http://www.digitalartoasis.com/viewtopic.php?p=322#322

This script is a good example of what's possible with the new TVP-only command: tv_getActiveTool, one of several sdk additions I pestered poor Hervé for...

This command deserves to be the next wiki addition...
wait a minute!
you are so fast... ah a new swap tool! ... let me see this one...
ohhhh I think I will LOVE this one !!!
so, please, DON'T stop your pestorations !........ :D

Posted: 22 Jun 2006, 01:10
by lemec
Yes!! This is why I pester Hervé so much... now I have to catch up to him and document all the new commands in the wiki in the hopes that other people can learn to use and benefit from them and make more tools on their own!

Scripting languages like George and MEL (Maya Embedded Language) are what make an animation package especially indispensable to a production house. Back in the days when I used to work in the visual effects industry, I had to work with Maya (the 3D animation software) and I made many many tools with their MEL scripting language. The most ubiquitous 3D softwares (softimage, 3DS Max, Maya) all have scripting languages so that technical eggheads (like me) can adapt a program into a company's workflow.

I don't know of many 2D bitmap (or vector, for that matter) animation packages that have a scripting language (or easily accessible plugin API) -- and it's a huge niche that TVPaint fills. Heck, it's whats allowing a not-to-be-named former distributor to continue to expand on the functionality of their end-of-line software...

Posted: 22 Jun 2006, 10:17
by lemec
Okay, I made a Custom panel for this... plus I added a QuickMask function that could be useful for painters. It lets you mask off regions and protect them from painting over them. It's basically a nicely automated stencil tool that can be easily toggled on/off

http://www.digitalartoasis.com/viewtopic.php?p=332#332

All this is thanks to Hervé's new GRG stencil functions and him being so nice about making it possible to flip the stencil display on/off through GRG!

Posted: 22 Jun 2006, 11:52
by Hervé
lemec wrote:Okay, I made a Custom panel for this... plus I added a QuickMask function that could be useful for painters. It lets you mask off regions and protect them from painting over them. It's basically a nicely automated stencil tool that can be easily toggled on/off

http://www.digitalartoasis.com/viewtopic.php?p=332#332

All this is thanks to Hervé's new GRG stencil functions and him being so nice about making it possible to flip the stencil display on/off through GRG!
Nice, but you have wait for the next minor release.

Posted: 22 Jun 2006, 14:37
by lemec
you sure? Everything seems to work so far -- the layer stencil control, the Display Stencil option, etc...

Posted: 27 Jun 2007, 11:53
by Mads Juul
I would really like to se/try these script but the server is down??

can you please upload these scripts??

-mads

Posted: 29 Jun 2007, 17:15
by CartoonMonkey
Me too!
Aahhh!
:)

Posted: 30 Aug 2007, 19:44
by CartoonMonkey
So, no one has a copy of this script?

Posted: 18 Sep 2007, 10:51
by MrChoy
You could try PM'ing Lemec?