DrawImageInsideRect?

BlitzMax Forums/BlitzMax Beginners Area/DrawImageInsideRect?

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.

Here you go
Function DrawImageRect2(img:TImage, x#, y#, rx#, ry#, rw#, rh#)
	SetViewport x, y, rw, rh
	DrawImage img, x - rx, x - ry
	
	SetViewport 0, 0, GFX_WIDTH, GFX_HEIGHT
End Function