Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update palette to 0.6 #117

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

update palette to 0.6 #117

wants to merge 1 commit into from

Conversation

subpop
Copy link
Contributor

@subpop subpop commented Dec 23, 2021

Updates palette to 0.6 in the dependency list in Cargo.toml and ports
colors.rs to the 0.6 conversion changes.

Fixes: #115

Updates palette to 0.6 in the dependency list in Cargo.toml and ports
colors.rs to the 0.6 conversion changes.

Signed-off-by: Link Dupont <[email protected]>
@ids1024
Copy link
Member

ids1024 commented Dec 27, 2021

This seems to result in the same hue and saturation numbers displaying a somewhat different color than before.

I'm not entirely sure if that's purely an issue with this PR, or if the code is already kind of wrong in how it handles sRGB vs linear RGB. Or I guess palette was also doing things wrong from this quite in the 0.6 release notes:

They were previously only linear, due to an incorrect assumption, resulting in some situations where they could not give the same result as in other graphics software.

Dealing with linear and non-linear RGB seems to be surprisingly hard to get right and something software often messes up...

@subpop
Copy link
Contributor Author

subpop commented Jan 10, 2022

Yea, palette definitely change the way it handles linear RGB. I opened a discussion on the palette discussions while I was trying to figure out how to port this to palette 0.6. Converting to linear is now an explicit additional method call. I am not deeply familiar with how these color encodings work. From my somewhat limited use of the LED coloring on my launch_1, the colors look "the same".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Fails to build from source with palette 0.6
2 participants