Fix #104554: 2d paint does not paint with linear color on 32bit images #112631

Open
Philipp Oeser wants to merge 2 commits from lichtwerk/blender:104554 into main

When changing the target branch, be careful to rebase the branch in your fork to match. See documentation.

2 Commits

Author SHA1 Message Date
Philipp Oeser d52c9208f4 only convert to linear if it hasnt been done before
colorspaces other than Non-Color would have converted to linear in
paint_brush_color_get() already.
2023-09-20 18:04:27 +02:00
Philipp Oeser 2bba33b62d Fix #104554: 2d paint does not paint with linear color on 32bit images
When painting in the Image Editor on float images, the brush color was
not converted from sRGB to linear, leading to differences painting with
the same brush in the 3DView vs. the Image Editor.

Now corrected by piping the brush color through
srgb_to_linearrgb_v3_v3() when painting on 32bit images.

Should probably go into LTS as well.
2023-09-20 16:57:37 +02:00