Bug 369882

Summary: Brush property Color: Mix doesnt work right with the default colorspace in 16 Bits
Product: [Applications] krita Reporter: arturg <var.spool.mail700>
Component: Color modelsAssignee: Krita Bugs <krita-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: griffinvalley
Priority: NOR    
Version First Reported In: git master (please specify the git hash!)   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description arturg 2016-10-04 16:28:45 UTC
Reproducible: Always

Steps to Reproduce:
create a Document  with Color space
Model: RGB
Depth: 16 Bits (others work)
Profile: sRGB-elle-v2-g10.icc (Default) (others work with 16 Bits havent tested all)

set brush property Color: Mix pen settings active and select any sensor

set Forground color: red (can be any other color)
set Background color: blue (can be any other color)

draw a line.

Actual Results:  
mixes forground color to black

Expected Results:  
should mix forground color to background color
Comment 1 wolthera 2016-10-04 17:01:00 UTC
Yes, this is quite surreal, it only happens with that profile+bitdepth combination, which might mean there's a wonky check somewhere...
Comment 2 Nicholas LaPointe 2016-10-08 09:32:38 UTC
Git commit 2503ee390e22fef5b47a82b9e0d5dac536cca9c5 by Nicholas LaPointe.
Committed on 08/10/2016 at 09:25.
Pushed by nicholasl into branch 'master'.

Fix bug 369882 ("Brush property Color: Mix doesnt work right with the default colorspace in 16 Bits")

m_cachedBackGroundColor, which is used for mixing, is only set to the actual background color when m_color.colorSpace() != m_foreGroundColor.colorSpace(). In the case of the bug, the colorspaces are equal.
Differential Revision: https://phabricator.kde.org/D2947

M  +1    -0    plugins/paintops/libpaintop/kis_color_source.cpp

http://commits.kde.org/krita/2503ee390e22fef5b47a82b9e0d5dac536cca9c5