Bug 441139 - KPL palettes with Lab swatches aren't loaded correctly
Summary: KPL palettes with Lab swatches aren't loaded correctly
Status: RESOLVED FIXED
Alias: None
Product: krita
Classification: Applications
Component: * Unknown (show other bugs)
Version: nightly build (please specify the git hash!)
Platform: macOS (DMG) macOS
: NOR normal
Target Milestone: ---
Assignee: wolthera
URL:
Keywords: regression, release_blocker
Depends on:
Blocks:
 
Reported: 2021-08-18 20:24 UTC by Dustin Wilson
Modified: 2021-09-06 12:25 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
KPL palette file with Lab swatches (3.07 KB, application/zip)
2021-08-18 20:24 UTC, Dustin Wilson
Details
Screenshot of the loaded palette (37.57 KB, image/png)
2021-08-18 20:25 UTC, Dustin Wilson
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Dustin Wilson 2021-08-18 20:24:05 UTC
Created attachment 140821 [details]
KPL palette file with Lab swatches

SUMMARY
KPL palettes which contain swatches which use Lab values aren't loaded correctly in Krita 5 Beta 1.

STEPS TO REPRODUCE
1. Load attached KPL palette in Krita 5 Beta 1

OBSERVED RESULT
All colors loaded into Krita are black

EXPECTED RESULT
Should be the colors I specified in the KPL file

SOFTWARE/OS VERSIONS
macOS: 10.14.6

ADDITIONAL INFORMATION
Comment 1 Dustin Wilson 2021-08-18 20:25:37 UTC
Created attachment 140822 [details]
Screenshot of the loaded palette
Comment 2 wolthera 2021-08-18 20:34:42 UTC
I can reproduce, probably caused by my endless fudging of the KoColor xml definition back in march.
Comment 3 wolthera 2021-09-06 12:24:13 UTC
Git commit 0ea48ccc440a3b5386cf86cb55bb477abb0a5c5c by Wolthera van Hövell tot Westerflier.
Committed on 06/09/2021 at 12:24.
Pushed by woltherav into branch 'krita/5.0'.

Fix loading of LAB KPL swatches.

Not only was the wrong element being read, but also the formula was wrong.
I should create a unittest for this when I am going to refactor the palettes again.

M  +11   -9    libs/pigment/resources/KoColorSet.cpp

https://invent.kde.org/graphics/krita/commit/0ea48ccc440a3b5386cf86cb55bb477abb0a5c5c
Comment 4 wolthera 2021-09-06 12:25:44 UTC
Git commit 434b1d5aff5c3b6137b269db30d094456d2ac490 by Wolthera van Hövell, on behalf of Wolthera van Hövell tot Westerflier.
Committed on 06/09/2021 at 12:25.
Pushed by woltherav into branch 'master'.

Fix loading of LAB KPL swatches.

Not only was the wrong element being read, but also the formula was wrong.
I should create a unittest for this when I am going to refactor the palettes again.


(cherry picked from commit 0ea48ccc440a3b5386cf86cb55bb477abb0a5c5c)

M  +11   -9    libs/pigment/resources/KoColorSet.cpp

https://invent.kde.org/graphics/krita/commit/434b1d5aff5c3b6137b269db30d094456d2ac490