> 2010/1/17 kevinfishburne <[email protected]>:
> > When retrieving the value of a pixel at x,y from the picture in a
> > picturebox control it outputs a single value. How does this value
> > represent the pixel's value, and can it be easily converted to an RGB
> > value?
> 
> Red = Value Mod 256
> Green = Int(Value / 256) Mod 256
> Blue = Int(Value / 256 / 256) Mod 256
> 

Or you can use the [] operator on the Color class.

Color[MyColor].Red
Color[MyColor].Green
Color[MyColor].Blue
...

See the Color class documentation for all properties you can use on 
Color[...].

Regards,

-- 
Benoît Minisini

------------------------------------------------------------------------------
Throughout its 18-year history, RSA Conference consistently attracts the
world's best and brightest in the field, creating opportunities for Conference
attendees to learn about information security's most important issues through
interactions with peers, luminaries and emerging and established companies.
http://p.sf.net/sfu/rsaconf-dev2dev
_______________________________________________
Gambas-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/gambas-user

Reply via email to