Page 1 of 1

Color Adjust bug ?

Posted: 22 Dec 2017, 14:18
by D.T. Nethery
Possible bug in the FX Stack > Color Adjust .

I am working on a project with an Art Director who works in Photoshop. If a color change must be made he tells me the steps he took in Photoshop to change the color using PS's Image > Adjustments > Hue/Saturation and gives me the resulting RGB values of the color . But when I use these equivalent settings to adjust the color in TVPaint I get a result that is almost, but not quite the same as the results in Photoshop. However, I think RGB values should be universal, there should not be slight variations from one program to another . I don't know if the problem is in Photoshop or the problem is in TVPaint , but I hope someone from TVPaint Development team can test this and confirm that this is an issue and whether it can be fixed.

For example , let's say we have a color that has RGB values of R = 183 , G = 235 , B = 255. It has the exact same starting RGB values in TVPaint and in Photoshop . In Photoshop if the color is changed by using Image > Adjustments > Hue/Saturation with settings of Hue = +77 , Saturation= +100 , Lightness = -5 , the result is a color with RGB values of R =214 , G =162 , B = 255.
In TVPaint the same color starts as R = 183 , G = 235 , B = 255 , then I change the color using FX Stack > Color > Color Adjust with Angle (Hue) = 77 , Saturation = 100 , Brightness = -5 and the resulting color change looks the same at a glance , but if I sample it with the eyedropper I see that the RGB values are slightly different, in TVPaint the result is R = 211, G = 159 , B = 254 . But WHY should that be ? It's frustrating that it is almost, but not quite the exact same result .

See the screen shots attached. (click on images to enlarge)
Photoshop-Hue_Saturation_Lightness.jpg
TVPaint_Hue_Saturation_Brightness.jpg
.

This is in TVPaint Pro 11.0.8 64bit , on Mac OS 10.11.6 . Photoshop CC 2018 .

Re: Color Adjust bug ?

Posted: 22 Dec 2017, 14:28
by slowtiger
First guess: check if PS is set to sRGB which is the colour space TVP is working in.

Re: Color Adjust bug ?

Posted: 22 Dec 2017, 14:29
by D.T. Nethery
slowtiger wrote: 22 Dec 2017, 14:28 First guess: check if PS is set to sRGB which is the colour space TVP is working in.
I checked my own Photoshop Color Settings and my color space is set to sRGB IEC611966-2.1 . However, changing the color in TVPaint using Color Adjust results in a color that is almost , but not quite the same RGB values . I also tried setting Photoshop to Epson Scanner sRGB profile which was one of the other sRGB options in Color Settings , but had the same results . A color which reads as R = 214 , G = 162 , B = 255 in Photoshop comes out as R = 211 , G = 159 , B =254 in TVPaint when using Color Adjust with equivalent settings to Photoshop ( Hue/Angle) = 77 , Saturation = 100 , Brightness = -5 ).

I think it is a bug in TVPaint's Color Adjust FX . Because if I make a color swatch in Photoshop with the values R = 214 , G = 162 , B = 255 and export it as PNG , then import it to TVPaint , it shows up in TVPaint Color Picker as R = 214 , G = 162 , B = 255 . The inconsistent results come from applying the Color Adjust FX to a color, using adjustments of Hue/Angle , Saturation , and Brightness that are same as Photoshops Hue, Saturation, Lightness . Those settings in TVPaint don't give the same result as Photoshop , off by just a few values.

Re: Color Adjust bug ?

Posted: 27 Dec 2017, 06:02
by D.T. Nethery
Bump.

Can this be fixed ? (see my first post above)

Re: Color Adjust bug ?

Posted: 27 Dec 2017, 06:04
by Elodie
Be patient David, you posted on Christmas' week-end and 26th is a holiday too in Alsace-Moselle :)

I'm on the bus, I will have a look at it asap.

Re: Color Adjust bug ?

Posted: 03 Jan 2018, 09:36
by Eric Scholl
Hi David and happy new year,

There can be multiple reasons why Photoshop values differs from TVpaint values.
TVPaint uses 8 bits conversions, maybe Photoshop uses floating point conversions in his algorithms even if you're working in 8 bits. But I don't think this would lead to this kind of gap between Photoshop and TVPaint values.

But,
I have recently discovered that Photoshop has a specific way to compute Hue, Saturation, Luminosity.
TVPaint uses the classical conversion from RGB to HSL, but Photoshop uses a specific weighted conversion from RGB to HSL.
I think this is the reason why you get a huge gap between Photoshop and TVPaint value. Photoshop values and TVPaint values does not represent exactly the same thing, even if the names are the same.

These kind of problem are impossible to avoid with any combination of softwares, it's not TVPaint/Photoshop specific.
Each software has his own way to compute values, and if you can't get the sources of the software and if it's not given by the company developing the software, you can't reproduce exactly the same computation.
Sometimes it only differs from 1 or 2 points, but if the computations are really different, like in this case, you will see clearly the gap between the values.

Some solutions here :
- Your Art Director can use TVPaint to define colors
- Your Art Director can give you a color sheet as an image(PNG) you can import in TVPaint to keep RGB values
- You animate on photoshop...(just kidding)

Re: Color Adjust bug ?

Posted: 03 Jan 2018, 18:27
by D.T. Nethery
Eric Scholl wrote: 03 Jan 2018, 09:36 Hi David and happy new year,

There can be multiple reasons why Photoshop values differs from TVpaint values.
TVPaint uses 8 bits conversions, maybe Photoshop uses floating point conversions in his algorithms even if you're working in 8 bits. But I don't think this would lead to this kind of gap between Photoshop and TVPaint values.

But,
I have recently discovered that Photoshop has a specific way to compute Hue, Saturation, Luminosity.
TVPaint uses the classical conversion from RGB to HSL, but Photoshop uses a specific weighted conversion from RGB to HSL.
I think this is the reason why you get a huge gap between Photoshop and TVPaint value. Photoshop values and TVPaint values does not represent exactly the same thing, even if the names are the same.

These kind of problem are impossible to avoid with any combination of softwares, it's not TVPaint/Photoshop specific.
Each software has his own way to compute values, and if you can't get the sources of the software and if it's not given by the company developing the software, you can't reproduce exactly the same computation.
Sometimes it only differs from 1 or 2 points, but if the computations are really different, like in this case, you will see clearly the gap between the values.

Some solutions here :
- Your Art Director can use TVPaint to define colors
- Your Art Director can give you a color sheet as an image(PNG) you can import in TVPaint to keep RGB values
- You animate on photoshop...(just kidding)

Thank you , Eric. This is a very helpful answer. Now I know I'm not crazy or doing something wrong ! It really is different.

Although #1 would be my preferred solution, your solution #2) "Art Director can give you a color sheet as an image(PNG) you can import in TVPaint to keep RGB values" is the solution I have been using. I have found that transferring PNG images back and forth from Photoshop to TVPaint maintain the same RGB values accurately . That is what made me think maybe the Color Adjust FX had a bug in how it is calculating the percentage of change to Hue , Saturation, Brightness , because when I ran tests by making a color swatch palette in TVPaint and exporting it as a PNG and open it in Photoshop each swatch retains the exact same RGB values as in TVPaint ... and vice versa if I make a color swatch palette in Photoshop and save it as a PNG , and import it to TVPaint it retains the exact same RGB values, so it made me think that both Photoshop and TVPaint must understand the RGB values the same , which is why it puzzled me so much that I get the variations when applying a color change using the Color Adjust FX . It is just one of those oddities I will have to deal with .

I haven't done it yet, but have been meaning to make some more extensive tests to see if I can pin down a precise number to offset the numbers for Hue, Saturation, Brightness in TVPaint to match to the numbers in Photoshop ... what I mean is , if I could determine that TVPaint is consistently ____ (number) off from the same Color adjustments made in Photoshop , conversion becomes a relatively easy matter to convert it. But I haven't had time yet to make extensive tests to determine if it's always ____ (number) or if it varies. In the example I gave above the R value is off by three , the G value is off by three , but then B value is only off by one , so I think it's unlikely to be something so simple .

Earlier I had the same issue with Photoshop values for Gaussian Blur being different from TVPaint values for Gaussian Blur (to apply the equivalent amount of Blur to a series of animated frames in TVPaint as had been indicated in the art director's Photoshop image) . But that turned out to be a simple conversion of x3 -- Photoshop Gaussian Blur 1 = TVPaint Gaussian Blur 3 , Photoshop Gaussian Blur 5 = TVPaint Gaussian Blur 15 , Photoshop Gaussian Blur 10 = TVPaint Gaussian Blur 30 , etc. If it's a consistent number like that for Color Adjust I could always make the conversion by adding (or subtracting) the number of variance , but I'm not sure if it's the same with Color Adjust as with Gaussian Blur.