RGB values wrong calculated/displayed (ignoring Color Management) #71586

Closed
opened 2019-11-14 21:40:24 +01:00 by Michael Klein · 10 comments

System Information
Operating system: Windows-10-10.0.18362 64 Bits
Graphics card: GeForce GTX 1060/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 441.20

Blender Version
Broken: version: 2.81 (sub 16), branch: master, commit date: 2019-11-13 16:25, hash: 9bd0d8b550
Worked: (optional)

Short description of error
The RGB values will be displayed wrong. HSV and HEX are correct. The resulting color is correct.
The wrong decimal numbers seem to be a result by not considering the Color Management.

Exact steps for others to reproduce the error

  • Add RGB-node in compositor
  • Use Color example: 678F8F
  • Results

BLENDER

R: 0.136
G: 0.275
B: 0.275

RGB is wrong.

H: 0.500 (180°)
S: 0.280
V: 0.561

HSV is correct.
Output color on screen is correct.

Correct result in Maya:
R: 0.404
G: 0.561
B: 0.561

Correc result in Photoshop:
H: 180°
S: 28
B: 56

R: 103
G: 143
B: 143

In the attached picture you'll from left to right:
Blender Colors - Maya Colors (Color Management ON) - Maya Colors (Color Management OFF)

191114_Blender_281_RGB_Wrong.jpg

**System Information** Operating system: Windows-10-10.0.18362 64 Bits Graphics card: GeForce GTX 1060/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 441.20 **Blender Version** Broken: version: 2.81 (sub 16), branch: master, commit date: 2019-11-13 16:25, hash: `9bd0d8b550` Worked: (optional) **Short description of error** The RGB values will be displayed wrong. HSV and HEX are correct. The resulting color is correct. The wrong decimal numbers seem to be a result by not considering the Color Management. **Exact steps for others to reproduce the error** - Add RGB-node in compositor - Use Color example: 678F8F - Results BLENDER R: 0.136 G: 0.275 B: 0.275 RGB is wrong. H: 0.500 (180°) S: 0.280 V: 0.561 HSV is correct. Output color on screen is correct. Correct result in Maya: R: 0.404 G: 0.561 B: 0.561 Correc result in Photoshop: H: 180° S: 28 B: 56 R: 103 G: 143 B: 143 In the attached picture you'll from left to right: Blender Colors - Maya Colors (Color Management ON) - Maya Colors (Color Management OFF) ![191114_Blender_281_RGB_Wrong.jpg](https://archive.blender.org/developer/F8080198/191114_Blender_281_RGB_Wrong.jpg)
Author

Added subscriber: @Renderbicks

Added subscriber: @Renderbicks
Michael Klein changed title from RGB values wrong calculated (ignoring Color Management) to RGB values wrong calculated/displayed (ignoring Color Management) 2019-11-14 21:43:30 +01:00

Added subscriber: @SteffenD

Added subscriber: @SteffenD

Added subscriber: @bent

Added subscriber: @bent

Added subscribers: @brecht, @mano-wii

Added subscribers: @brecht, @mano-wii

It seems that there really is an inconsistency between the other applications and Blender.
I used this site to check the values: https://www.rgbtohex.net/hextorgb/

Looking at the code, I found that the rgb value changes in this line:
https://developer.blender.org/diffusion/B/browse/master/source/blender/editors/interface/interface_region_color_picker.c$307

@brecht, you have worked in this area before (a7b3d580), do you know why this happens?

It seems that there really is an inconsistency between the other applications and Blender. I used this site to check the values: https://www.rgbtohex.net/hextorgb/ Looking at the code, I found that the rgb value changes in this line: https://developer.blender.org/diffusion/B/browse/master/source/blender/editors/interface/interface_region_color_picker.c$307 @brecht, you have worked in this area before (a7b3d580), do you know why this happens?

Changed status from 'Open' to: 'Archived'

Changed status from 'Open' to: 'Archived'
Brecht Van Lommel self-assigned this 2019-11-20 23:34:56 +01:00

By design, hex and HSV are sRGB, and RGB is scene linear.
https://docs.blender.org/manual/en/dev/interface/controls/templates/color_picker.html

By design, hex and HSV are sRGB, and RGB is scene linear. https://docs.blender.org/manual/en/dev/interface/controls/templates/color_picker.html
Author

In #71586#813990, @brecht wrote:
By design, hex and HSV are sRGB, and RGB is scene linear.
https://docs.blender.org/manual/en/dev/interface/controls/templates/color_picker.html

I assume RGB should also be sRGB and maybe adding a button to turn linear on/off. Otherwise it's totally confusing because the general RGB sliders of all programs are all using sRGB values. It doesn't make sense that V 0.5 is not RGB 0.5 0.5 0.5.

> In #71586#813990, @brecht wrote: > By design, hex and HSV are sRGB, and RGB is scene linear. > https://docs.blender.org/manual/en/dev/interface/controls/templates/color_picker.html I assume RGB should also be sRGB and maybe adding a button to turn linear on/off. Otherwise it's totally confusing because the general RGB sliders of all programs are all using sRGB values. It doesn't make sense that V 0.5 is not RGB 0.5 0.5 0.5.
Author

I found out that Maya is using linear for RGB and HSV. Maya just shows it different. Attached you see the screenshot of the sliders with linear Color Management on and off. In Blender you'll see it at the vertical greyscale bar.

191121_Maya_Linear_RGB.jpg

I found out that Maya is using linear for RGB and HSV. Maya just shows it different. Attached you see the screenshot of the sliders with linear Color Management on and off. In Blender you'll see it at the vertical greyscale bar. ![191121_Maya_Linear_RGB.jpg](https://archive.blender.org/developer/F8151763/191121_Maya_Linear_RGB.jpg)
Author

To clarify:
Maya is generally set to linear for RGB and HSV. Maya is not supporting HEX.

I can't copy RGB/HSV values from PSD to Maya. I can preview the PSD sRGB color when I turn Color Management off but I still have the linear result. A workaround is to split the screen and use a color picker in Maya and pick the PSD color.

But I can copy HEX from PSD to Blender. The linear RGB numbers can be copied correctly to Maya.

So the Blender method seems to be good/better. Color Management is always confusing.

To clarify: Maya is generally set to linear for RGB and HSV. Maya is not supporting HEX. I can't copy RGB/HSV values from PSD to Maya. I can preview the PSD sRGB color when I turn Color Management off but I still have the linear result. A workaround is to split the screen and use a color picker in Maya and pick the PSD color. But I can copy HEX from PSD to Blender. The linear RGB numbers can be copied correctly to Maya. So the Blender method seems to be good/better. Color Management is always confusing.
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
5 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#71586
No description provided.