George Command to set (and/or read) Filling Shape parameters

This section is dedicated to the feature & improvement requests (be sure what you are asking does not exist yet in TVPaint Animation ;) )
Post Reply
Svengali
Posts: 1571
Joined: 28 Dec 2006, 10:08

George Command to set (and/or read) Filling Shape parameters

Post by Svengali »

Is there a George command that will let you set and/or read the Filling Shape parameters?

If not, it could be very useful for managing scripted filling operations. Please consider such a command to manage the following parameters for the next release?
FillingShapeParameters.jpg
FillingShapeParameters.jpg (19.5 KiB) Viewed 17116 times
thanks, Sven
User avatar
Mads Juul
Posts: 3992
Joined: 02 May 2007, 19:18

Re: George Command to set (and/or read) Filling Shape parame

Post by Mads Juul »

You can use

Code: Select all

tv_setActiveShape flood backup
properties = result
to read most of the parameters and

Code: Select all

tv_setActiveShape properties
to set them.

some of the parameters is not read/written though.
-Mads
Svengali
Posts: 1571
Joined: 28 Dec 2006, 10:08

Re: George Command to set (and/or read) Filling Shape parame

Post by Svengali »

Thanks Mads,

I guess I should have been more exact. The critical FloodFill, Filling Shape properties that I can't access or set are as follows:

Source: with four options - Layer, Above, Below, Display (all useful in their own way)
Fill: with five options - Color & Density, Color Only, Density Only, B Color, Luma
Gap Closer: numeric value
Expand: numeric value
Range: numeric value
AutoPicker: a check box (on or off)

Perhaps a new pair of commands: tv_GetFillingShape and tv_SetFillingShape as in:

tv_GetFillingShape
parse result xSource xFill xGap xExpand xRange xAutoPicker

As you say, all the other important FloodFill settings can be read and written using tv_GetActiveShape and tv_SetActiveShape.

Sven
User avatar
ZigOtto
Posts: 4102
Joined: 17 Feb 2006, 22:50
Location: south-Petazonia

Re: George Command to set (and/or read) Filling Shape parame

Post by ZigOtto »

Svengali wrote:...
Source: with four options - Layer, Above, Below, Display (all useful in their own way)
Fill: with five options - Color & Density, Color Only, Density Only, B Color, Luma
Gap Closer: numeric value
Expand: numeric value
Range: numeric value
AutoPicker: a check box (on or off)

Perhaps a new pair of commands: tv_GetFillingShape and tv_SetFillingShape as in:

tv_GetFillingShape
parse result xSource xFill xGap xExpand xRange xAutoPicker

...
+1 ! :wink:
Svengali
Posts: 1571
Joined: 28 Dec 2006, 10:08

Re: George Command to set (and/or read) Filling Shape parame

Post by Svengali »

An alternative to creating a completely new pair of commands might be to simply extend the existing parameters for the tv_AreaInit command which are:

tv_areainit ["RESET"] ["mode VAL"] ["vector x1 y1 x2 y2"] ["map_xbrush PARAM"] ["map_ybrush PARAM"] ["map_xopacity PARAM"] ["map_yopacity PARAM"] ["map_gradient PARAM"] ["opacity VAL"] ["smooth VAL"] ["aaliasing VAL"]

to include the Filling Shape Parameters as follows:

tv_areainit ["RESET"] ["mode VAL"] ["vector x1 y1 x2 y2"] ["map_xbrush PARAM"] ["map_ybrush PARAM"] ["map_xopacity PARAM"] ["map_yopacity PARAM"] ["map_gradient PARAM"] ["opacity VAL"] ["smooth VAL"] ["aaliasing VAL"] ["source VAL"] ["fill VAL"] ["gap VAL"] ["expand VAL"] ["range VAL"] ["autopicker PARAM"]

Sven
User avatar
Mads Juul
Posts: 3992
Joined: 02 May 2007, 19:18

Re: George Command to set (and/or read) Filling Shape parame

Post by Mads Juul »

Why not add the rest of the parameters to tv_setactiveshape backup? that is where we get the parameters in the first place. Also for the other shapes. So it seems most natural to me.
Svengali
Posts: 1571
Joined: 28 Dec 2006, 10:08

Re: George Command to set (and/or read) Filling Shape parame

Post by Svengali »

Mads,
Thank you.

Your response prompted me to have a look at "AreaInit on the WIKI site" where I discovered that four of the five parameters ARE already there! Only thing missing seems to be the FILL parameter according to the details there.

(It seems my personal documentation on the newer GEORGE commands is slightly out of date).

This means that I can now post the FigFill button and FigureFill.grg script over in your original thread, once I tweak a few lines and test the results. If it all works I'll try to post the FigureFill zipfile later this morning.

A few other scripts I've been waiting on should now also be do-able using this same info.

Sven
User avatar
Mads Juul
Posts: 3992
Joined: 02 May 2007, 19:18

Re: George Command to set (and/or read) Filling Shape parame

Post by Mads Juul »

Sounds cool.
I think as well we should be able to read the fill property with tv_areaInit backup
-Mads
Post Reply