Display Image in GUI Window?

BlitzMax Forums/BlitzMax Beginners Area/Display Image in GUI Window?

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

You need to make a canvas then you can draw on it using
"SetGraphics CanvasGraphics(Canvas)." I'm not real good at
explaining stuff so I'll let the code do the explaining.


Global Square = LoadImage("Square.gif")
Global EditCanvas:TGadget = CreateCanvas(0,0,640,480,Window)

Function DrawCanvas()
SetGraphics CanvasGraphics(Canvas)
Cls
DrawImage Square,0,0
Flip
End Function


Hope this helps.

Oh, also this code isn't complete, it will not work if you
try and run it. You have to create a window first and do a
few other things, but I think you know how to do that stuff.