Clipping Ortho Quad

I'm trying to clip and ortho Quad but I can seem to find a good way of doing it with in the engine. I could extend the Quad class and then override preDraw and postDraw to call GL11.glScissor to set/enable and restore/disable the scissor state but  I would like to avoid making lwjgl specific calls.  The same code wouldn't work with the jogl renderer.  I also would like to be able to set the scissor state at a parent node instead of the all the child geomety leaf nodes.



I'm relatively new to JME architecture but looking through te source there doesn't seem to be any way to manipulate the scissor state from with in the engine.  I looked though the BGUI source and they are making direct lwjgl calls to solve the problem.



I'm I missing something obvious?



Thanks


Garrland said:

I'm trying to clip and ortho Quad but I can seem to find a good way of doing it with in the engine. I could extend the Quad class and then override preDraw and postDraw to call GL11.glScissor to set/enable and restore/disable the scissor state but  I would like to avoid making lwjgl specific calls.  The same code wouldn't work with the jogl renderer.  I also would like to be able to set the scissor state at a parent node instead of the all the child geomety leaf nodes.

I'm relatively new to JME architecture but looking through te source there doesn't seem to be any way to manipulate the scissor state from with in the engine.  I looked though the BGUI source and they are making direct lwjgl calls to solve the problem.

I'm I missing something obvious?

Thanks




I think I've solved the problem. I hope I didn't add a feature that already existed. As I've said, i'm new to JME but I couldn't see how you could manipulate the scissor state in the engine's  2.0.1 source.  I  created a new Scissor render state. I've got it working with lwjgl but haven't created the jogl equivalent yet.    

someone else once created a scissorstate, but it didnt work correctly.



http://www.jmonkeyengine.com/forum/index.php?topic=11140.msg84161#msg84161