This is effectively SDL_SetClipRect for SDL 1.3’s renderers.
I find myself desiring this type of functionality frequently, and since
I’m writing sdlgui it has become a bit more difficult to ignore.
Attached is a patch implementing this for Direct3D9, OpenGL,
OpenGLES(1/2), DirectFB, and Software renderers. I have no idea whether
or not NDS’s gl2D supports GL_SCISSOR_TEST/glSetScissor, so although I
have made the appropriate function (NDS_RenderSetScissor), the
implementation is commented out until someone who knows for certain gets
to it.
Enjoy!
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed…
Name: RenderSetScissor.diff
URL: http://lists.libsdl.org/pipermail/sdl-libsdl.org/attachments/20110507/43688afa/attachment.asc