[Gambas-user] Using an Image in a PictureBox or help with my issue

Robert Moss the.at.robert at ...626...
Sun Nov 23 09:58:50 CET 2008


I need to use an Image because i need to be able to get pixel data (ie read
the color values in an image) via Image[x,y].
I would also like this image to be visible on screen, but the only box i've
found is PictureBox, which uses a picture, and it will not load an image.
(and pictures dont do pic[x,y])

So I'd like to do:
'PictureBox on form
Dim i as Image

i = Image.Load("Myfile.jpg")

PicBox1.Picture = i  'this is where error comes obviously as it wants a
picture, but i need to use images ^_^

Message(str(Image[x,y]))

Thanks so much

Note: If there is an easy way to go from Dec to RGB (i assume return value
is DEC) that would be cool, but thats not my issue



More information about the User mailing list