Skip to main content

Java 3D running with Java 7 on Windows

Please note these forums are being decommissioned and use the new and improved forums at
2 replies [Last post]
Joined: 2008-09-18


I have implemented a Java 3D scene graph which can be opened in one application run more than once with new data therefore I create new instances. I am using seperate Canvas3D intances. Recently, I switched to JDK 7 instead of 1.6 and since then I get random errors which force the whole application to crash. I found a forum enty which also indicates that Java 7 causes problems with J3D (

In an old forum entry from 2007 and I found a solution to stop the whole application to crash. (

But I need to fix the problem because I need more than one instance of my scene graph. Currently I can only open one scene graph because with the second graph the following error ocurres.

CONTEXT_CREATION_ERROR: Renderer: Error creating Canvas3D graphics context
graphicsDevice = Win32GraphicsDevice[screen=0]
canvas =[canvas1,0,0,899x770,invalid]
Java 3D ERROR : Canvas3D_createNewContext: Failed in SetPixelFormat - Das Pixelformat ist ung?ltig.
java.lang.IllegalStateException: Canvas3D: Non-recoverable graphics configuration error
at com.sun.j3d.utils.universe.ViewInfo$CanvasInfo.getCanvasInfo(
at com.sun.j3d.utils.universe.ViewInfo$CanvasInfo.access$8000(
at com.sun.j3d.utils.universe.ViewInfo.updateCache(
at com.sun.j3d.utils.universe.ViewInfo.getPhysicalWidth(

Has anyone similar experience with Java 1.7? Does anyone know a work-a-round for this issue?

Thanks for your help,

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Joined: 2008-09-18


I found a solution for my problem. I was using a list of System properties for Java 3d and when I removed them my applications was running fine even with JKD 7.

This is my list of properties which I had to removed:

    System.setProperty("j3d.forceReleaseView", "true"); 
    System.setProperty("sun.java2d.d3d", "false");
    System.setProperty("sun.java2d.ddoffscreen", "false");
    System.setProperty("sun.java2d.noddraw", "true");
    System.setProperty("j3d.debug", "true");
    System.setProperty("j3d.sharedctx", "false");
    System.setProperty("j3d.cacheAutoComputeBounds", "true");
    System.setProperty("j3d.g2ddrawpixel", "true");
    System.setProperty("j3d.optimizeForSpace", "false");
    System.setProperty("j3d.threadLimit", "2");
    System.setProperty("j3d.usePbuffer", "false");

I am also running Java 3D embedded in a SWT application.

Joined: 2012-02-19

I also had problems after switching from Java 1.6 to 1.7 on Windows (Linux seems to be ok so far). The Canvas3D (only one for me) sometimes shows nothing - especially directly after start-up. Furthermore the application doesn't quit normally. In my case using a SWT_AWT frame to embed the canvas in a SWT-based application might introduce further complications. My solution so far was to switch back to 1.6 - so I'm sorry I do not have a solution for you...