Quick view of drawing area as values (grayscale, b+w)

Please use this part to report bugs & errors, ask questions & "How to..."
Post Reply
johnfromncl
Posts: 41
Joined: 29 Jul 2019, 08:46
Location: Whitley Bay, England

Quick view of drawing area as values (grayscale, b+w)

Post by johnfromncl » 24 Sep 2021, 18:04

Hi
I like to view my drawing area now and then as greyscale (to see just the values of what I have created) because that gives important visibility and relative contrast information. Currently I achieve this by Effects > Colour > Black and white convertor, and have red as 76, green as 150 and blue as 29, and preview set.
I'm wondering if anyone knows of a way to show the values by simply clicking on a button or using a shortcut. Is there a script for this? Toggling would be easiest, but a different shortcut or button to revert back to the original colours in the drawing area would also be fine. Hopefully this would also NOT show the effects panels which tends to hide some of my drawing area on my setup.
Any help gratefully received.
Many thanks
John
iMac (Retina 5K, 27-inch, 2020). 3.8 Ghz 8-core Intel Core i7, 128GB 2667 MHz DDR4. MacOS Catalina 10.15.7.
TVPaint Animation 11 Pro (11.5.2-64 bits).
Wacom Cintiq pro 24". Driver using 6.3.43-3 (avoiding 6.3.44-1)
John from Newcastle, johnfromncl Updated 2021-09-24

Svengali
Posts: 1459
Joined: 28 Dec 2006, 10:08
Contact:

Re: Quick view of drawing area as values (grayscale, b+w)

Post by Svengali » 25 Sep 2021, 01:44

johnfromncl wrote:
24 Sep 2021, 18:04
Hi
I like to view my drawing area now and then as greyscale (to see just the values of what I have created) because that gives important visibility and relative contrast information. Currently I achieve this by Effects > Colour > Black and white convertor, and have red as 76, green as 150 and blue as 29, and preview set.
I'm wondering if anyone knows of a way to show the values by simply clicking on a button or using a shortcut. Is there a script for this? Toggling would be easiest, but a different shortcut or button to revert back to the original colours in the drawing area would also be fine. Hopefully this would also NOT show the effects panels which tends to hide some of my drawing area on my setup.
This should be easy to do...
1. Save the FX>Black And White Converter as a bin file into your GEORGE folder and name it "Color2Gray.bin"
2. In a new Action Button, create an embedded George Script that contains the following lines (press Select All, then copy the lines so you can paste them into the embedded script):

Code: Select all


 JohnPath = "jf/Library/tvp animation 11 pro/default/george/Color2Gray.bin"
 JohnPath = '"'JohnPath'"' // note enclosing quotes are '""'  single,double,single - necessary because of the spaces in tvp animation 11 pro

 tv_StackExecute JohnPath

 MButton = 0
 While MButton == 0
	tv_WaitButton
	parse result MButton d
END
tv_Undo

What the embedded script does is:
1. Executes the Color2Gray FX (stored in your GEORGE folder) which turns your image to gray according to your settings...
2. Then it waits for you to click any mouse button...
3. Then it executes an UNDO which restores back to the original color

you won't see the FX window.
sven

Thanks NathanOtano!!!
Last edited by Svengali on 27 Sep 2021, 20:32, edited 2 times in total.
Desktop: tvp Pro 11.0.10-64bit, Win8.1 - 24GB ram -2TB HHD - 256GB SSD - Wacom Cintiq 16, driver 6.3.36-1
Android Tablet: rel. 11, Samsung Galaxy Note10.1 - 32GB internal - microSD 32GB
Android Tablet: rel. 11.5, Samsung Galaxy Tab S7plus - 128GB internal - no microSD yet

johnfromncl
Posts: 41
Joined: 29 Jul 2019, 08:46
Location: Whitley Bay, England

Re: Quick view of drawing area as values (grayscale, b+w)

Post by johnfromncl » 25 Sep 2021, 19:01

Many thanks for this... but I haven't quite got it working yet.

My lack of knowledge means I'm not quite managing to get the steps right on my mac.
What I did was export the .bin file to jf/Library/tvp animation 11 pro/default/george/Color2Gray.bin
Notes:
1. After having first made a backup of the 'tvp animation 11 pro' folder in case!
2. jf is my home folder
3. Using 'default' as part of the path above was a bit of a guess - which I feel is possibly wrong.

I then created a button ('C2G') and copied in the script above, so when I view the button contents it is
0 Embedded George Script (which has the script copied from above)
1 End

I then quit TVPaint, and even restarted my mac.

When I come back in and click on my C2G button I get the message 'There is no FX in Stack!' - suggesting to me that it hasn't found that bin file - perhaps - since I definitely had the Black and White Converter in the stack when I did the FXBin > Export.

So, for now, I'm not quite there yet. As always, any help will be very gratefully received.

Many thanks
John
iMac (Retina 5K, 27-inch, 2020). 3.8 Ghz 8-core Intel Core i7, 128GB 2667 MHz DDR4. MacOS Catalina 10.15.7.
TVPaint Animation 11 Pro (11.5.2-64 bits).
Wacom Cintiq pro 24". Driver using 6.3.43-3 (avoiding 6.3.44-1)
John from Newcastle, johnfromncl Updated 2021-09-24

User avatar
slowtiger
Posts: 2643
Joined: 08 May 2008, 21:10
Location: berlin, germany
Contact:

Re: Quick view of drawing area as values (grayscale, b+w)

Post by slowtiger » 25 Sep 2021, 19:51

Simpler:
1. Create a new layer on top.
2. Completely fill it with middle gray (L=128).
3. Set layer mode to "colorize".
4. Switch layer visibility on and off.
TVP 10.0.18, Mac Pro Quadcore 3 GHz, 16 GB RAM, OS 10.11, QT 7.7.3

Svengali
Posts: 1459
Joined: 28 Dec 2006, 10:08
Contact:

Re: Quick view of drawing area as values (grayscale, b+w)

Post by Svengali » 25 Sep 2021, 20:10

Hi John,
I'm on Windows, so the embedded script expects that the GEORGE folder is inside the main tvpaint folder...

With Mac, I'm not sure what path needs to be included in the embedded script so that the bin file can be found (loaded and executed)... maybe one of the other TVPaint scripters (Nathan?) who knows the Mac can give you the correct syntax for that path to the .bin file.

line that needs to be edited: tv_StackExecute "George\Color2Gray.bin"

To anyone else reading this post, the script demonstrates a simple, toggle functionality that might be adapted to preview other FX (like blur or high-contrast, noise or drop-shadow.)

sven
Desktop: tvp Pro 11.0.10-64bit, Win8.1 - 24GB ram -2TB HHD - 256GB SSD - Wacom Cintiq 16, driver 6.3.36-1
Android Tablet: rel. 11, Samsung Galaxy Note10.1 - 32GB internal - microSD 32GB
Android Tablet: rel. 11.5, Samsung Galaxy Tab S7plus - 128GB internal - no microSD yet

johnfromncl
Posts: 41
Joined: 29 Jul 2019, 08:46
Location: Whitley Bay, England

Re: Quick view of drawing area as values (grayscale, b+w)

Post by johnfromncl » 26 Sep 2021, 14:19

Hi all and thanks for your suggestions. This is where all this is up to

1) What I'm aiming for is a click to see this greyscale values effect
FX Stack effect.png
FX Stack effect.png (35.51 KiB) Viewed 2217 times
My solution for now is to have the FX stack set up for this and to toggle the effect stack on and off - which is not perfect (since the effect stack is also used for other things) - but is fine if there aren't alternatives that can be got working.

2) Slowtiger's suggestion currently gives something different to the above. Namely:
Slowtiger effect.png
Slowtiger effect.png (26.21 KiB) Viewed 2217 times
3) Sven's suggestion - which I haven't got working on my mac due to not being sure where to export that .bin file (I've experimented without success) and then how to then point to it - is very nice in that (as he points out) it could be extended beyond just the black and white converter effect to be any stack effect being able to be toggled on and off. Really that is a major potential enhancement to the use of TVPaint in my mind - once set up in terms of bins and buttons - having the viewing of a range of commonly-used stack effects each a mere button-click away.

Any information on how to get Sven's solution working on a mac would be gratefully received, mainly because of this (in my mind) huge potential, but also for sorting my immediate black and white convertor accessibility issue without having to alter the stack (sometimes) before viewing it.

Any ideas on how I can get 3 above working?
iMac (Retina 5K, 27-inch, 2020). 3.8 Ghz 8-core Intel Core i7, 128GB 2667 MHz DDR4. MacOS Catalina 10.15.7.
TVPaint Animation 11 Pro (11.5.2-64 bits).
Wacom Cintiq pro 24". Driver using 6.3.43-3 (avoiding 6.3.44-1)
John from Newcastle, johnfromncl Updated 2021-09-24

User avatar
NathanOtano
Posts: 1080
Joined: 01 Apr 2014, 07:07
Location: Biarritz, France
Contact:

Re: Quick view of drawing area as values (grayscale, b+w)

Post by NathanOtano » 26 Sep 2021, 14:43

Yop :) sorry i don’t at all have experience working on mac

For your purpose i’d just use a button to convert in grey scale as you want and then use undo, which is close to your use of fx stack and I think is the optimal version (you can even use a shortcut to toggle fx stack preview on and off if it exists?

I remember a toggle to see momentarily only some colors in the sketch panel, maybe you can try to see how it works? It’s a little eye

You may be able to script with george a color modification with tv_pixelmatrix I think. Sven’s option is also nice

If it works the way you alteady use it I would not bother scripting something else ^^
Creator of Disnosc, providing storyboard, animation and design for 2D realistic pictural animation: https://www.disnosc.fr/ - nathanotano@disnosc.fr
Highly interested in animation workflows, I'm open to scripting new TVP functions for individuals and studios. Please don't hesitate to contact me!

User avatar
NathanOtano
Posts: 1080
Joined: 01 Apr 2014, 07:07
Location: Biarritz, France
Contact:

Re: Quick view of drawing area as values (grayscale, b+w)

Post by NathanOtano » 26 Sep 2021, 14:46

can you show us a path on your mac? maybe there is some spaces and accents that prevents sven’s script from working.
Maybe try to export your bin on your desktop to see if it works?
Creator of Disnosc, providing storyboard, animation and design for 2D realistic pictural animation: https://www.disnosc.fr/ - nathanotano@disnosc.fr
Highly interested in animation workflows, I'm open to scripting new TVP functions for individuals and studios. Please don't hesitate to contact me!

johnfromncl
Posts: 41
Joined: 29 Jul 2019, 08:46
Location: Whitley Bay, England

Re: Quick view of drawing area as values (grayscale, b+w)

Post by johnfromncl » 26 Sep 2021, 15:00

My path is /Users/jf/Library/tvp animation 11 pro/default/george/Color2Gray.bin. There are no .bin files in that folder, other than the Color2Gray which I put there by exporting to there.

(I'm aware that on my computer there is also /Users/jf/tvp animation 11 pro, but that does not have a george folder in it, so I haven't tried using it.) Really, I have no clue about TVPaint folders...

Another thing, I notice that Sven uses a backwards slash (the world of PC's), while my address is a forward slash (the world of macs), but I imagine that TVPaint handles that somehow. I experimented changing that slash, but it did not sort or change the error message I've been getting.

I'm now wondering if I need to figure out how to specify a full path address instead of what I image to be a relative one that Sven supplied...
iMac (Retina 5K, 27-inch, 2020). 3.8 Ghz 8-core Intel Core i7, 128GB 2667 MHz DDR4. MacOS Catalina 10.15.7.
TVPaint Animation 11 Pro (11.5.2-64 bits).
Wacom Cintiq pro 24". Driver using 6.3.43-3 (avoiding 6.3.44-1)
John from Newcastle, johnfromncl Updated 2021-09-24

johnfromncl
Posts: 41
Joined: 29 Jul 2019, 08:46
Location: Whitley Bay, England

Re: Quick view of drawing area as values (grayscale, b+w)

Post by johnfromncl » 26 Sep 2021, 15:13

I've just tried an absolute address by making Sven's first line
tv_StackExecute "/Users/jf/Library/tvp animation 11 pro/default/george/Color2Gray.bin"
But I still get the "There is no FX in Stack !" message on clicking my button.
Ditto when creating my .bin file on my desktop and pointing to that.
iMac (Retina 5K, 27-inch, 2020). 3.8 Ghz 8-core Intel Core i7, 128GB 2667 MHz DDR4. MacOS Catalina 10.15.7.
TVPaint Animation 11 Pro (11.5.2-64 bits).
Wacom Cintiq pro 24". Driver using 6.3.43-3 (avoiding 6.3.44-1)
John from Newcastle, johnfromncl Updated 2021-09-24

Svengali
Posts: 1459
Joined: 28 Dec 2006, 10:08
Contact:

Re: Quick view of drawing area as values (grayscale, b+w)

Post by Svengali » 26 Sep 2021, 15:59

Hi John,

Go back and look at my original post where I just modified the embedded GEORGE script. Notice that your path is now hardwired so it could be assigned to a variable so that the entire path could then be enclosed in single-double-single quote sets (' " ').
This is necessary because your path includes spaces. Nathan's post reminded me that GEORGE requires special handling with paths that include spaces.

sven

EDIT: You might simplify things for yourself if instead of putting the bin file in the GEORGE subfolder, you instead create a desktop folder named FX where you can store a collection of various FX .bin files that are called by the tv_StackExicute command. Doing so would both simplify the path AND make it easier to add special FX .bin files you want to preview.

Also, you can create another button with an embedded script which will tell you, for sure, the path to your GEORGE subfolder.

Code: Select all

tv_GetPath GEORGE
tv_warn result
Desktop: tvp Pro 11.0.10-64bit, Win8.1 - 24GB ram -2TB HHD - 256GB SSD - Wacom Cintiq 16, driver 6.3.36-1
Android Tablet: rel. 11, Samsung Galaxy Note10.1 - 32GB internal - microSD 32GB
Android Tablet: rel. 11.5, Samsung Galaxy Tab S7plus - 128GB internal - no microSD yet

User avatar
NathanOtano
Posts: 1080
Joined: 01 Apr 2014, 07:07
Location: Biarritz, France
Contact:

Re: Quick view of drawing area as values (grayscale, b+w)

Post by NathanOtano » 27 Sep 2021, 00:42

There is some response about how to handle mac vs windows slashs and other os related stuff is Madsjuul george library on the wiki i think maybe?
Creator of Disnosc, providing storyboard, animation and design for 2D realistic pictural animation: https://www.disnosc.fr/ - nathanotano@disnosc.fr
Highly interested in animation workflows, I'm open to scripting new TVP functions for individuals and studios. Please don't hesitate to contact me!

User avatar
D.T. Nethery
Posts: 3109
Joined: 27 Sep 2006, 19:19

Re: Quick view of drawing area as values (grayscale, b+w)

Post by D.T. Nethery » 29 Sep 2021, 15:29

NathanOtano wrote:
26 Sep 2021, 14:43
=
For your purpose i’d just use a button to convert in grey scale as you want and then use undo, which is close to your use of fx stack and I think is the optimal version (you can even use a shortcut to toggle fx stack preview on and off if it exists?

I remember a toggle to see momentarily only some colors in the sketch panel , maybe you can try to see how it works? It’s a little eye

The little eye button is in the Sketch Panel. It will temporarily hide red, green, or blue pixels and show only black pixels. It is a keyboard shortcut called "Black Preview".
I don't know how it could be tweaked to convert color to greyscale , but that button might contain a clue ? I'm only chiming in here to mention the location of the little eye button, I don’t have any idea how to adapt it or show greyscale only.
QuickLook_Eye_Button_Sketch_Panel.jpg

.

Animator, TVPaint Beta-Tester, Animation Educator and Consultant.
MAC OS 10.14.6 , Macbook Pro Retina 15-inch, Late 2013,
2.3 GHz Intel Core i7, 16 GB Memory , TVPaint PRO 11.5.2 - 64bit ,
Wacom Cintiq 21 UX ,Wacom Intuos Pro 5 , Wacom driver version 6.3.39-1

User avatar
NathanOtano
Posts: 1080
Joined: 01 Apr 2014, 07:07
Location: Biarritz, France
Contact:

Re: Quick view of drawing area as values (grayscale, b+w)

Post by NathanOtano » 30 Sep 2021, 14:16

yeah i feel this is a nice behaviour
I also think an external solution switch the global screen to grey scale with a shortcut would just be much easier to find ^^ https://9to5mac.com/2019/05/27/how-to-u ... -your-mac/
Creator of Disnosc, providing storyboard, animation and design for 2D realistic pictural animation: https://www.disnosc.fr/ - nathanotano@disnosc.fr
Highly interested in animation workflows, I'm open to scripting new TVP functions for individuals and studios. Please don't hesitate to contact me!

Post Reply