Who uses Graphics.setcolorHSV
?
#437
Replies: 5 comments
-
Posted at 2015-07-24 by DrAzzy I like that idea - is the current method a feature of a standard graphics api you're trying to make it look like? Does anyone use hsv, for that matter? |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-07-24 by @gfwilliams No, it was a pull request from someone who thought it'd be handy - I've never seen any API that looks like that ;) I often use HSV when driving RGB LEDs, but unless you're driving an LED matrix using the Graphics lib, the current solution is less than ideal! |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-07-25 by Loop I use it, but i believe the api would change for the better with your planned changes, so no probs. Only thing, I believe that either I don't understand something, or there are two problems with the current code/docs
|
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-07-27 by DrAzzy So it sounds like not only is SetColorHSV() kinda odd, it also doesn't work as advertised! |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-07-27 by @gfwilliams Thanks - I'll take a look at that when I do it. Bug here: espruino/Espruino#554 Thanks for saying about the 361 thing. It's probably some |
Beta Was this translation helpful? Give feedback.
-
Posted at 2015-07-24 by @gfwilliams
So... who actually uses
Graphics.setcolorHSV
?It feels like a bit of a waste of time to me... I'd really like to remove it and add
E.HSBtoRGB
instead, that does the hue conversion without relying on graphics. You could then doGraphics.setColor(E.HSBtoRGB(h,s,b))
instead, but if you were trying to do something like cycle hue on some LEDs, you could just use it directly.Beta Was this translation helpful? Give feedback.
All reactions