Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Java Help > Re: How many fl...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 8 of 12 Topic 15906 of 16566
Post > Topic >>

Re: How many float values in range 0f - 1f inclusive?

by "Jeff Higgins" <oohiggins@[EMAIL PROTECTED] > Mar 24, 2008 at 08:13 AM

John B. Matthews wrote:
[...]
>
> Would a custom color chooser provide a better abstraction?

Well, that was inspirational!  While playing around with the
ColorChooserDemo, and in particular the Hue pane, I began to
wonder how do they possibly expect to get the 255*255*255 RGB
colors with only 360*100*100 when it dawned upon me that the
*hue angle* is cyclic so that there are really 360*6*100*100
HSB values represented in that control!  My apparent numerical/
conversion problems were all the result of my misunderstanding
the parameters to Color.getHSB(hsb), I was attempting to
represent the hue parameter as a percentage rather than a hue
angle.  Now, armed with that revelation I can simply put a
mapping in between the java.awt.Color conversion methods and
my display and now HSB .5,.5,.5 should equal 128,128,128 RGB. :-)

Thanks,
JH

>
>
> John
 




 12 Posts in Topic:
How many float values in range 0f - 1f inclusive?
"Jeff Higgins"   2008-03-22 11:26:54 
Re: How many float values in range 0f - 1f inclusive?
Patricia Shanahan <pat  2008-03-22 09:31:16 
Re: How many float values in range 0f - 1f inclusive?
Alex.From.Ohio.Java@[EMAI  2008-03-22 11:27:56 
Re: How many float values in range 0f - 1f inclusive?
Patricia Shanahan <pat  2008-03-22 11:55:48 
Re: How many float values in range 0f - 1f inclusive?
Lew <lew@[EMAIL PROTEC  2008-03-22 16:34:19 
Re: How many float values in range 0f - 1f inclusive?
"Jeff Higgins"   2008-03-22 19:23:55 
Re: How many float values in range 0f - 1f inclusive?
"John B. Matthews&qu  2008-03-22 22:15:26 
Re: How many float values in range 0f - 1f inclusive?
"Jeff Higgins"   2008-03-24 08:13:54 
Re: How many float values in range 0f - 1f inclusive?
Alex Kizub <akizub@[EM  2008-03-23 06:09:11 
Re: How many float values in range 0f - 1f inclusive?
Patricia Shanahan <pat  2008-03-23 06:53:32 
Re: How many float values in range 0f - 1f inclusive?
Alex.From.Ohio.Java@[EMAI  2008-03-23 07:35:31 
Re: How many float values in range 0f - 1f inclusive?
Patricia Shanahan <pat  2008-03-23 08:04:24 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Sat Nov 22 16:29:02 CST 2008.