Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: HSL Color Standard  (Read 22128 times)

0 Members and 1 Guest are viewing this topic.

masskiller

  • Sr. Member
  • ****
  • Posts: 284
  • Pointers to Functions rock!
    • MSN Messenger - kyogre_jb@hotmail.com
    • View Profile
    • Email
HSL Color Standard
« on: October 07, 2012, 06:15:42 am »
I'd like to propose to add the HSL (Hue, Saturation, Luminance) Coloring to SFML.

I have been investigating HSL Coloring system for a bit, while it's true that it's nowhere near as useful as RGBA is, however it allows easy color transformations such as colorizing an image with a given color in an easy way.

Here's an example: http://www.tannerhelland.com/3552/colorize-image-vb6/

This cannot be done in an easy way with RGB and I think that it would give the library another powerful tool if implemented. I don't think that HSL is good for being able to be used the same way as RGB, yet still to be able to colorize and manipulate colors in that way and give the user that freedom is what gave me the idea to suggest this into SFML.

So what do you think about this? Is it a good idea or not practical at all? I am implementing it myself for my game, but I think it'd be nice to see this in a future version of SFML.
Programmer, Artist, Composer and Storyline/Script Writer of "Origin of Magic". If all goes well this could turn into a commercial project!

Finally back into the programming world!

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: HSL Color Standard
« Reply #1 on: October 07, 2012, 09:50:07 am »
This is something that doesn't require modifications to SFML, it can (and must) be written on top of sf::Color. So I don't see good reasons for integrating it directly.

But you can share your code on the wiki ;)
Laurent Gomila - SFML developer

Nexus

  • SFML Team
  • Hero Member
  • *****
  • Posts: 6287
  • Thor Developer
    • View Profile
    • Bromeon
Re: HSL Color Standard
« Reply #2 on: October 07, 2012, 10:57:21 am »
I have already thought about adding a HSV or HSL color class to Thor. But don't expect it too soon, I'm still stuck with other design issues (particles/animations) :)
Zloxx II: action platformer
Thor Library: particle systems, animations, dot products, ...
SFML Game Development:

masskiller

  • Sr. Member
  • ****
  • Posts: 284
  • Pointers to Functions rock!
    • MSN Messenger - kyogre_jb@hotmail.com
    • View Profile
    • Email
Re: HSL Color Standard
« Reply #3 on: October 09, 2012, 12:16:49 am »
Quote
But you can share your code on the wiki ;)

I'm nearly done with it, as soon as I am done implementing what's left and documenting it I'll share it.
Programmer, Artist, Composer and Storyline/Script Writer of "Origin of Magic". If all goes well this could turn into a commercial project!

Finally back into the programming world!

quarks

  • Newbie
  • *
  • Posts: 10
    • View Profile
Re: HSL Color Standard
« Reply #4 on: October 17, 2012, 11:23:09 pm »
I don't see any license inormation for this piece of code:
https://github.com/SFML/SFML/wiki/SourceHSLColor

Maybe the author is still arround ?

In case so, may I suggest you to add the same license header than SFML ?

Otherwise the only things we can do is either to read it only, or stealing it in the copyright violation way.

Thanks for your understanding
« Last Edit: October 18, 2012, 12:34:27 am by quarks »

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11034
    • View Profile
    • development blog
    • Email
Re: HSL Color Standard
« Reply #5 on: October 17, 2012, 11:45:47 pm »
Well mostly don't include any license... I guess Laurent will introduce a rule that if not otherwise specified the code provided in the wiki will be in the public domain. I'd also say that's mostly what the authors think of, otherwise they wouldn't publicise code there. ;)

If you look at the page history then you see that the original author is maskedkiller01 which sounds suspicously similar to masskiller...
And there was an edit just a few minutes ago by blue-prawn, that's either quarks or this user. ;)
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

quarks

  • Newbie
  • *
  • Posts: 10
    • View Profile
Re: HSL Color Standard
« Reply #6 on: October 18, 2012, 12:32:39 am »
If you look at the page history then you see that the original author is maskedkiller01 which sounds suspicously similar to masskiller...

Obviously :)

And there was an edit just a few minutes ago by blue-prawn, that's either quarks or this user. ;)

And ?

OK, there is this page too: https://github.com/SFML/SFML/wiki/Tutorial:-Manage-dynamic-key-binding
from "eXpl0it3r" which is probably the same than on the forum "eXpl0it3r", also edited by "blue-prawn" 6 minutes ago

So may I assume that the code that you provide on the wiki is public domain?

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11034
    • View Profile
    • development blog
    • Email
Re: HSL Color Standard
« Reply #7 on: October 18, 2012, 12:45:12 am »
So may I assume that the code that you provide on the wiki is public domain?
This isn't my code... I'm not sure how GitHub handles these pages but for some reason it doesn't show the first change... So maybe one can't go after the history. :-\
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

quarks

  • Newbie
  • *
  • Posts: 10
    • View Profile
Re: HSL Color Standard
« Reply #8 on: October 18, 2012, 12:51:17 am »
This isn't my code... I'm not sure how GitHub handles these pages but for some reason it doesn't show the first change... So maybe one can't go after the history. :-\

Great!
this is very handy to contact the original authors, to ask them about licensing issues.

On the old wiki, I found this:
http://www.sfml-dev.org/wiki/en/sources/pausableclock

I was able to ask the author if he accepts to switch from cc-by-sa to the same license than SFML.
He accepted.

IMO we should fix the licensing issue on the wiki before there are too many things.

Also I noticed later that the code from "PausableClock" seems to be the same than here:
https://github.com/Bromeon/Thor/blob/master/src/StopWatch.cpp

but the name of the author is different !??

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11034
    • View Profile
    • development blog
    • Email
Re: HSL Color Standard
« Reply #9 on: October 18, 2012, 01:05:31 am »
IMO we should fix the licensing issue on the wiki before there are too many things.
Yeah... Laurent? ;D

Also I noticed later that the code from "PausableClock" seems to be the same than here:
https://github.com/Bromeon/Thor/blob/master/src/StopWatch.cpp

but the name of the author is different !??
I've no idea how you'd think that this is the same code... ???
Make a diff and you won't find any matches.
And for the idea, you can't copyright that...

But all that beside the one author is Hirua and the other is Nexus and I think they know each other from the forum well enough to not fighter over such code ideas. Both are contributing extensively to SFML so worry not... ;)

Ah, and Thor as the same license than SFML, so you can do with that code whatever you want. :D
« Last Edit: October 18, 2012, 01:07:52 am by eXpl0it3r »
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

quarks

  • Newbie
  • *
  • Posts: 10
    • View Profile
Re: HSL Color Standard
« Reply #10 on: October 18, 2012, 01:19:57 am »
I've no idea how you'd think that this is the same code... ???
Make a diff and you won't find any matches.

This is the same code, only the variable and class names are different.
The implementation is exactly the same, while one could implement this in different ways.
So please...


But all that beside the one author is Hirua and the other is Nexus and I think they know each other from the forum well enough to not fighter over such code ideas. Both are contributing extensively to SFML so worry not... ;)

Of course noone will raise a trial for 10 lines of code.
When I read this, I was just surprised to see the same code without cite the original author.


FRex

  • Hero Member
  • *****
  • Posts: 1848
  • Back to C++ gamedev with SFML in May 2023
    • View Profile
    • Email
Re: HSL Color Standard
« Reply #11 on: October 18, 2012, 02:06:03 am »
Chances are that if you told us the interface and functionality these two have, we would write similar code without knowing the original code. There's only so many ways to implement things.
Quote
And for the idea, you can't copyright that...
I like to point out how much I hate Apple in moments like that. ;D
Back to C++ gamedev with SFML in May 2023

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: HSL Color Standard
« Reply #12 on: October 18, 2012, 08:07:02 am »
Quote
Yeah... Laurent?
I don't have the time to manage the wiki. There are so many things to do on it (fix the titles/page names, change the rules, add the default license, review the recent modifications and additions, ...).

It would be great if someone could manage this wiki ;D
Laurent Gomila - SFML developer

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11034
    • View Profile
    • development blog
    • Email
Re: HSL Color Standard
« Reply #13 on: October 18, 2012, 08:18:37 am »
It would be great if someone could manage this wiki ;D
I guess I could do some stuff... ;)
I'm unsure though, if it makes sense to change all the titles, because it will probably break every link on the forum to a specific topic, then again that's just a small problem and the bigger win would be a nice title naming scheme... ;)
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: HSL Color Standard
« Reply #14 on: October 18, 2012, 08:20:21 am »
Yeah, I don't know exactly how to handle existing URLs. But since github change the way they work, something must be done. At least update the rules.
Laurent Gomila - SFML developer

 

anything