setsize() method with GLPbuffer generates 'Not yet implemented' exception' ?

The full exception is ‘java.media.opengl.GLException:Not yet implemented’.
I get this exception with version 1.0 and 1.1 (April 22, 07)

A little explanation of our application follows:

My application is not the ‘usual’ use of a pbuffer. An AJAX web app is used to view a static model over the web.
A GLPbuffer is used to perform rendering and take screenshots of the rendered image.

The state of the render is changed (view position, view heading, lighting, etc.). Then the model is rendered using the
GLPbuffer display() method. Usually a screenshot is also taken when the model is rendered.

Note that there is no actual display window on the renderer server, only a GLPBuffer.

Everything works fine except changing the size of the pbuffer.

The application currently allows the user to change the size of the rendered image (for example from 400x400 to 600x600) which does not work because of the exception.

?Will setSize() with GLPbuffer be implemented?

?Is there some work around?

Best regards

Reply to myself:

The work around I implemented is to:

destroy the current pbuffer (I hope GLPbuffer.destroy() works), and create a new pbuffer with the new size,
and create a new GLEventListener for the pbuffer with current renderer state.

I saw an old message (2003) that said there was a memory leak when a GLPbuffer is destroyed.
Is that still true? I hope not.

My web server app will be creating and destoying GLPbuffers many times without restarting.

You can look at TileRenderer class. It’s a great tool for rendering offscreen images with variable size without resizing and destroying PBuffer.

This is what GLPbuffer.setSize() would have to do internally anyway, so that’s the only possible solution.

There are no known memory leaks on the JOGL side with pbuffers, though they have never been implemented 100% reliably in any of the vendors’ OpenGL drivers. In particular creation and destruction of many pbuffers tends to fail eventually.

latek’s advice of using the TileRenderer is good. See this other thread.

Thanks for the good information.

The work around seems to be working fine, for now. I needed the functionality for something else anyway.

I think it may be easier for me to reset my application’s state, than for a GLPbuffer.setSize() method to try to reset state in general.

One suggestion. The documentation should be clear when an interface method is not supported. Now it says that ‘some’ implementations
don’t support setSize(). Also, the exception saying ‘Not yet implemented’ leads one to believe that it will be implemented, when it probably won’t be.

No big deal. I haven’t run into any real problems with jogl yet.