[OpenGL Thread Issue?] Exception in Camera.doFrustumChange


I have an applet which crashes from time to time with

an exception in Camera.doFrustumChange.


at com.jme.renderer.lwjgl.LWJGLCamera.doFrustumChange(Unknown Source)

at com.jme.renderer.lwjgl.LWJGLCamera.apply(Unknown Source)

at com.jme.renderer.lwjgl.LWJGLRenderer.reinit(Unknown Source)

at de.macrocom.planer3d.jme.BaseAppletCanvasImpl.resize(BaseAppletCanvasImpl.java:257)

at de.macrocom.planer3d.jme.BaseAppletCanvasImpl.doRender


I found a link (SimpleGame to StandardGame by darkfrog)


which resembles the behaviour I have in my applet. The author says that I have to wait for the

OpenGL-Thread when I’m initialising the camera


He did so by doing that:

[java]Future<Camera> future = GameTaskQueueManager.getManager().update(new Callable<Camera>() {

public Camera call() throws Exception {

DisplaySystem display = DisplaySystem.getDisplaySystem();

int width = display.getWidth();

int height = display.getHeight();

Camera camera = display.getRenderer().createCamera(width, height);

camera.setFrustumPerspective(45.0f, (float)width / (float)height, 1, 1000);

return camera;



Camera myCamera = future.get();


But I’m not implementing a SimpleGame or a StandardGame, so there is no

, at least it returns
northing in my case.
I'm extending the
, because I
use the canvas in my applet.

If I'm on the right path here to solve my crashes with my camera:
What is the counterpart of
if I use JMECanvasImplementor (no SimpleGame/StandardGame)?

If I'm wrong: has anybody an idea how to fix random crashes when creating the camera?
Where could I look?

I'm using LWJGL 1.x with JME 1.0. Sorry, I can't update.


PS: Is there no preview before posting sth?