DrawImage Clip

BlitzMax Forums/BlitzMax Beginners Area/DrawImage Clip

GregBUG(Posted 2007) [#1]
just a quick quesion:

when i do a drawimage off-screen bmax will draw the image or not ? (clip)
...and if i use a bitmap of 640x480 in video memory is clipped in small pieces ? (ex: in 20x15 blocks ?) or not ?

thanks.


ImaginaryHuman(Posted 2007) [#2]
The graphics card should clip it as it has nowhere to draw to.

If your graphics card supports large enough textures it will be a single 1024x1024 image, and yes some space will be wasted.

It would never be clipped down below 64x64 as that is the minimum allowed texture size in OpenGL.


Yan(Posted 2007) [#3]
and if i use a bitmap of 640x480 in video memory is clipped in small pieces ? (ex: in 20x15 blocks ?) or not ?
Here's a simple overview of image creation in Max2D...http://www.blitzbasic.com/Community/posts.php?topic=65143#727728


It would never be clipped down below 64x64 as that is the minimum allowed texture size in OpenGL.
Hmmm...http://www.blitzbasic.com/Community/posts.php?topic=65143#727896


H&K(Posted 2007) [#4]
It would never be clipped down below 64x64 as that is the minimum allowed texture size in OpenGL.
Hummmm. Are you sure.

Im sure I remember hacking some textures from an Opengl Game and they were smaller. Mind you I seem to remember that they were 56x56, which doesnt seem right.


GregBUG(Posted 2007) [#5]
thanks.

but is better to clip an image to 64x64 blocks or not?

the overhead to redraw the clipped image is big or is more efficient to let the image as is (640x480)?


Grey Alien(Posted 2007) [#6]
I wouldn't worry about it. Let the video card do it's stuff, it'll be well optimised.


GregBUG(Posted 2007) [#7]
ok. thanks.