Can you assign line smoothing to a brush in a custom panel? Topic is solved

Please use this part to report bugs & errors, ask questions & "How to..."
Post Reply
BruceM
Posts: 245
Joined: 17 Jan 2014, 15:39

Can you assign line smoothing to a brush in a custom panel?

Post by BruceM »

With regards to creating custom panels, can you assign a particular line smoothing value to a brush that would be saved within that custom panel? I'm attempting to create a custom panel for a pen that I can click on that will already have a value of line smoothing assigned to it, however the line smoothing setting doesn't seem to program in as part of that brush.
Is this something that you can't do in TVP?
Svengali
Posts: 1553
Joined: 28 Dec 2006, 10:08

Re: Can you assign line smoothing to a brush in a custom panel?

Post by Svengali »

to guarantee the linesmoothing you want, insert the following line in each button defining a brush or tool:
Select Type Script's Command after the Tool line and type the following GEORGE command and parameters...

tv_DrawSmoothing 1 1 10 1 PullString

tv_drawsmoothing activate[0|1] realtime[0|1] value(pixeloffset) HUD [0|1] [PulledString|Average] (mode)

first number either 0 or 1 turns drawsmoothing off or on
second number either 0 or 1 turns realtime off or on
third number = length in pixels of the tow-line which offsets the cursor and the line being drawn
fourth number either 0 or 1 turn the tow-line visibility off or on
last parameter = PulledString or Average, (a word) which either leaves line as drawn or redraws the line after drawn to look smoother

Any button tool that doesn't have this George command line appended following the Tool define line will inherit the existing smoothing settings.

Sven
TVP Pro 11.0.10-64bit Win10 - 64GB ram -2TB HHD - 256GB SSD - Wacom Cintiq 16, driver 6.3.41-1
Android Tablet: rel. 11, Samsung Galaxy Note10.1 - 32GB with microSD 32GB
Android Tablet: rel. 11.5, Samsung Galaxy Tab S7plus - 128GB with microSD 64GB
BruceM
Posts: 245
Joined: 17 Jan 2014, 15:39

Re: Can you assign line smoothing to a brush in a custom panel?

Post by BruceM »

Thanks Svengali!
One additional question-- I've never done coding of any kind, so this will probably sound like a stupid question, but do I copy the 2 lines verbatim, including the words inside the parentheses:

"tv_DrawSmoothing 1 1 10 1 PullString
tv_drawsmoothing activate[0|1] realtime[0|1] value(pixeloffset) HUD [0|1] [PulledString|Average] (mode)"

Thanks!

-Bruce
Svengali
Posts: 1553
Joined: 28 Dec 2006, 10:08

Re: Can you assign line smoothing to a brush in a custom panel?

Post by Svengali »

BruceM wrote: 19 May 2017, 14:47 One additional question-- I've never done coding of any kind, so this will probably sound like a stupid question, but do I copy the 2 lines verbatim, including the words inside the parentheses:

tv_DrawSmoothing 1 1 10 1 PullString
tv_drawsmoothing activate[0|1] realtime[0|1] value(pixeloffset) HUD [0|1] [PulledString|Average] (mode)"
Only the first line needs to be cut and pasted into your brush button list.

The second line explains the first line order and options for the required parameters. For instance [0|1] means choose either 0 (for off) or 1 (for on).

If you want the tow-rope drag distance between line and cursor to be longer, increase the 10 parameter to 15 or 20, if you want the "tow-rope" hidden, set the HUD 1 (between 10 and PullString) to zero.

You can experiment by creating several copies of your original brush button and in each copy combine different parameter values to see how the smoothing of the brush-line changes.




Sven
Last edited by Svengali on 19 May 2017, 16:42, edited 1 time in total.
TVP Pro 11.0.10-64bit Win10 - 64GB ram -2TB HHD - 256GB SSD - Wacom Cintiq 16, driver 6.3.41-1
Android Tablet: rel. 11, Samsung Galaxy Note10.1 - 32GB with microSD 32GB
Android Tablet: rel. 11.5, Samsung Galaxy Tab S7plus - 128GB with microSD 64GB
BruceM
Posts: 245
Joined: 17 Jan 2014, 15:39

Re: Can you assign line smoothing to a brush in a custom panel?

Post by BruceM »

Thanks so much, Svengali!
I'll give it a go!
Post Reply