New OpenGL panel in SDK fixing many issues – please test

After launching application, you mean running the project in jMP, right?


Yes, thats right.

@Momoko_Fan: I still got issues with resizing when post effects are enabled. It looks like its displaying some old frame buffer after I changed the size.

The OpenGL issues still persists (with all the current updates, under Ubuntu 11.04). I find that when you preview any of the models (e.g. blender, j3o or obj), the IDE runs out of heap memory and freezes. It seems as if, on a first few occasions the models did show up (both obj and j3o), however, once the IDE crashed it would freeze every time it launched - perhaps this is something to do with Java cache?



At that point, trouble started because the IDE remembered the last opened window and it would freeze with the same error every time it opened. Of course as the OpenGL window has nothing to do with the welcome screen, the error would return haunting me, until I removed the problem causing project, received an empty OpenGL window and tried to close it before the IDE freezes again. After a couple of attempts, finally all went back to normal.

So after a while it starts working? I don’t really understand. Also if you increase heap memory for the IDE does it work? If the error still appears, can we get the stack trace?

No, just the opposite, after a while it stops working! However, once it is out it takes considerable effort to get rid of the OpenGL window associated with the model preview as the IDE remembers it being open (and it is not a welcome screen that could be easily switched off with the settings). I have my heap set at 1024m, which has been just fine even for large models. The new OpenGL interface must be leaking memory somewhere (and very rapidly) ? Also as it happens gradually, I wonder if this is anything to do with the IDE or more likely like a Java problem? I’ll try getting the stack trace tonight…

Hm, it does generate a lot of framebuffers when they get resized … I wonder if those are actually getting collected by the garbage collector. It sounds similar to that issue where ByteBuffers aren’t getting collected due to the garbage collector thinking they aren’t taking that much memory.

I did an update in my jmp after saw this post and now it can’t work anymore(but I did a backup before, so I’m able to revert it ;)). After the splash screen It opens and then it crashes imediatelly. I’m running on Ubuntu Studio 11.04 and I’m using the Mesa Driver for nvidia optimus gt 540m. I checked the log files and all they are empties xD.

Hm, can you start from command line to get at least some of the output?

Ok. See bellow.



[java]

root@glauco-rf411:/usr/local# sudo /bin/sh “/usr/local/jmonkeyplatform/bin/jmonkeyplatform”

/usr/local/jmonkeyplatform/bin/…/platform/lib/nbexec: linha 548: 7868 Falha de segmentação “/usr/lib/jvm/java-6-sun/bin/java” -Djdk.home="/usr/lib/jvm/java-6-sun" -classpath “/usr/local/jmonkeyplatform/platform/lib/boot.jar:/usr/local/jmonkeyplatform/platform/lib/org-openide-modules.jar:/usr/local/jmonkeyplatform/platform/lib/org-openide-util.jar:/usr/local/jmonkeyplatform/platform/lib/org-openide-util-lookup.jar:/usr/lib/jvm/java-6-sun/lib/dt.jar:/usr/lib/jvm/java-6-sun/lib/tools.jar” -Dnetbeans.dirs="/usr/local/jmonkeyplatform/bin/…/jmonkeyplatform:/usr/local/jmonkeyplatform/bin/…/extra:/usr/local/jmonkeyplatform/bin/…/harness:/usr/local/jmonkeyplatform/bin/…/ide:/usr/local/jmonkeyplatform/bin/…/java:" -Dnetbeans.home="/usr/local/jmonkeyplatform/platform" ‘-Xms24m’ ‘-Xmx512m’ ‘-XX:PermSize=256m’ -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath="/home/glauco/.jmonkeyplatform/dev/var/log/heapdump.hprof" org.netbeans.Main --userdir “/home/glauco/.jmonkeyplatform/dev” “–branding” “jmonkeyplatform” 0<&0

root@glauco-rf411:/usr/local#

[/java]

It’s about “Segmentation Fault”.

Edit: There’s Something wrong with the virtual machine.

Thanks, segmentation error sounds bad tho :confused:

Hmm. Tested again and the output changed(I tested again because for the last time there were two jmp instances running). See bellow:



[java]

root@glauco-rf411:~# sudo /bin/sh "/usr/local/jmonkeyplatform/bin/jmonkeyplatform"

#

A fatal error has been detected by the Java Runtime Environment:

#

SIGSEGV (0xb) at pc=0xb7091f5f, pid=31199, tid=2195131248

#

JRE version: 6.0_26-b03

Java VM: Java HotSpot™ Server VM (20.1-b02 mixed mode linux-x86 )

Problematic frame:

V [libjvm.so+0x63ff5f] PhaseChaitin::Split(unsigned)+0x292f

#

An error report file with more information is saved as:

/home/glauco/hs_err_pid31199.log

#

If you would like to submit a bug report, please visit:

http://java.sun.com/webapps/bugreport/crash.jsp

#

/usr/local/jmonkeyplatform/bin/…/platform/lib/nbexec: linha 548: 31199 Abortado “/usr/lib/jvm/java-6-sun/bin/java” -Djdk.home="/usr/lib/jvm/java-6-sun" -classpath “/usr/local/jmonkeyplatform/platform/lib/boot.jar:/usr/local/jmonkeyplatform/platform/lib/org-openide-modules.jar:/usr/local/jmonkeyplatform/platform/lib/org-openide-util.jar:/usr/local/jmonkeyplatform/platform/lib/org-openide-util-lookup.jar:/usr/lib/jvm/java-6-sun/lib/dt.jar:/usr/lib/jvm/java-6-sun/lib/tools.jar” -Dnetbeans.dirs="/usr/local/jmonkeyplatform/bin/…/jmonkeyplatform:/usr/local/jmonkeyplatform/bin/…/extra:/usr/local/jmonkeyplatform/bin/…/harness:/usr/local/jmonkeyplatform/bin/…/ide:/usr/local/jmonkeyplatform/bin/…/java:" -Dnetbeans.home="/usr/local/jmonkeyplatform/platform" ‘-Xms24m’ ‘-Xmx512m’ ‘-XX:PermSize=256m’ -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath="/home/glauco/.jmonkeyplatform/dev/var/log/heapdump.hprof" org.netbeans.Main --userdir “/home/glauco/.jmonkeyplatform/dev” “–branding” “jmonkeyplatform” 0<&0

root@glauco-rf411:~#

[/java]

1 Like

Hey guys, for all who have problems but don’t have immediate crashes like @glaucomardano I now added an options panel to enable the “old” OpenGL window. Should be in the build tomorrow.



http://code.google.com/p/jmonkeyengine/source/detail?r=8369

If you SDK creates immediately, add or change a file in your settings directory under “config/Preferences/com/jme3/gde/core.properties” and add the line “use_lwjgl_canvas=true”

normen said:
Hey guys, for all who have problems but don't have immediate crashes like @glaucomardano I now added an options panel to enable the "old" OpenGL window.


Just curious, JME does disable the hardware accelerated pipeline of Swing when mixing with LWJGL? In the past this has known to cause problems on weak drivers.

Using something like the following VM Parameters:

"-Dsun.java2d.noddraw=true -Dsun.awt.noerasebackground=true -Dsun.java2d.d3d=false -Dsun.java2d.opengl=false -Dsun.java2d.pmoffscreen=false"
1 Like

@normen: Nice, good job! That feature just will be available tonight ok? Also, I managed to make my jmp work, sometimes it doesn’t crash immediately, but after some seconds, so I had to be fast to close the OpenGL window :D. Now I’m able to enable the old OpenGL window after the next nightly. I’m going to use another nightly while the night doesn’t come xD.

@faust: It does not do that by default, you mean it should disable the acceleration?

@all: If you want to try this, the VM parameters faust posted can be added in the etc/jmonkeyplatform.conf file.

normen said:
...Should be in the build tomorrow.


Hmm, I didn't see that before :).

@norman, yes, there is little need for the swing gui to be using its own opengl hardware pipeline/renderer which may conflict/slowdown the LWJGL opengl renderer.

faust said:
@norman, yes, there is little need for the swing gui to be using its own opengl hardware pipeline/renderer which may conflict/slowdown the LWJGL opengl renderer.

Alright, I added that but I can't test it since I have no problems and it cannot be applied via an update as its a command line switch, so everybody having issues should try and enter this in etc/jmonkeyplatform.conf Beta will come with these switches by default.

Just a little bit more tests. I’ve noticed the output errors occurs randomly. I’ve posted bellow all output errors I’ve faced with. A strange thing is that if I remove the “jMonkeyProject” folder temporarily, the SDK works fine, but as the projects folder doesn’t exists anymore I can’t open my projects xD. If I create a new projets folder the SDK crashes again.



ERROR 1 : mesa_convert_colors



#

A fatal error has been detected by the Java Runtime Environment:

#

SIGSEGV (0xb) at pc=0x7d780a68, pid=6364, tid=2154220400

#

JRE version: 6.0_26-b03

Java VM: Java HotSpot™ Server VM (20.1-b02 mixed mode linux-x86 )

Problematic frame:

C [libdricore.so+0x73a68] _mesa_convert_colors+0xb8

#

An error report file with more information is saved as:

/usr/local/hs_err_pid6364.log

[thread -2100348048 also had an error]

[Too many errors, abort]

/usr/local/jmonkeyplatform/bin/…/platform/lib/nbexec: linha 548: 6364 Abortado “/usr/lib/jvm/java-6-sun/bin/java” -Djdk.home="/usr/lib/jvm/java-6-sun" -classpath “/usr/local/jmonkeyplatform/platform/lib/boot.jar:/usr/local/jmonkeyplatform/platform/lib/org-openide-modules.jar:/usr/local/jmonkeyplatform/platform/lib/org-openide-util.jar:/usr/local/jmonkeyplatform/platform/lib/org-openide-util-lookup.jar:/usr/lib/jvm/java-6-sun/lib/dt.jar:/usr/lib/jvm/java-6-sun/lib/tools.jar” -Dnetbeans.dirs="/usr/local/jmonkeyplatform/bin/…/jmonkeyplatform:/usr/local/jmonkeyplatform/bin/…/extra:/usr/local/jmonkeyplatform/bin/…/harness:/usr/local/jmonkeyplatform/bin/…/ide:/usr/local/jmonkeyplatform/bin/…/java:" -Dnetbeans.home="/usr/local/jmonkeyplatform/platform" ‘-Xms24m’ ‘-Xmx512m’ ‘-XX:PermSize=256m’ -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath="/home/glauco/.jmonkeyplatform/dev/var/log/heapdump.hprof" org.netbeans.Main --userdir “/home/glauco/.jmonkeyplatform/dev” “–branding” “jmonkeyplatform” 0<&0

root@glauco-rf411:/usr/local#





ERROR 2: Node::rematerialize()


A fatal error has been detected by the Java Runtime Environment:

#

SIGSEGV (0xb) at pc=0xb6f51654, pid=14700, tid=2195520368

#

JRE version: 6.0_26-b03

Java VM: Java HotSpot™ Server VM (20.1-b02 mixed mode linux-x86 )

Problematic frame:

V [libjvm.so+0x5c9654] Node::rematerialize() const+0x14

#

An error report file with more information is saved as:

/usr/local/hs_err_pid14700.log

#

If you would like to submit a bug report, please visit:

http://java.sun.com/webapps/bugreport/crash.jsp

#

/usr/local/jmonkeyplatform/bin/…/platform/lib/nbexec: linha 548: 14700 Abortado “/usr/lib/jvm/java-6-sun/bin/java” -Djdk.home="/usr/lib/jvm/java-6-sun" -classpath “/usr/local/jmonkeyplatform/platform/lib/boot.jar:/usr/local/jmonkeyplatform/platform/lib/org-openide-modules.jar:/usr/local/jmonkeyplatform/platform/lib/org-openide-util.jar:/usr/local/jmonkeyplatform/platform/lib/org-openide-util-lookup.jar:/usr/lib/jvm/java-6-sun/lib/dt.jar:/usr/lib/jvm/java-6-sun/lib/tools.jar” -Dnetbeans.dirs="/usr/local/jmonkeyplatform/bin/…/jmonkeyplatform:/usr/local/jmonkeyplatform/bin/…/extra:/usr/local/jmonkeyplatform/bin/…/harness:/usr/local/jmonkeyplatform/bin/…/ide:/usr/local/jmonkeyplatform/bin/…/java:" -Dnetbeans.home="/usr/local/jmonkeyplatform/platform" ‘-Xms24m’ ‘-Xmx512m’ ‘-XX:PermSize=256m’ -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath="/home/glauco/.jmonkeyplatform/dev/var/log/heapdump.hprof" org.netbeans.Main --userdir “/home/glauco/.jmonkeyplatform/dev” “–branding” “jmonkeyplatform” 0<&0

root@glauco-rf411:/usr/local#





ERROR 4: SEGMENTATION FAULT



root@glauco-rf411:/usr/local# sudo /bin/sh “/usr/local/jmonkeyplatform/bin/jmonkeyplatform”

/usr/local/jmonkeyplatform/bin/…/platform/lib/nbexec: linha 548: 18746 Falha de segmentação “/usr/lib/jvm/java-6-sun/bin/java” -Djdk.home="/usr/lib/jvm/java-6-sun" -classpath “/usr/local/jmonkeyplatform/platform/lib/boot.jar:/usr/local/jmonkeyplatform/platform/lib/org-openide-modules.jar:/usr/local/jmonkeyplatform/platform/lib/org-openide-util.jar:/usr/local/jmonkeyplatform/platform/lib/org-openide-util-lookup.jar:/usr/lib/jvm/java-6-sun/lib/dt.jar:/usr/lib/jvm/java-6-sun/lib/tools.jar” -Dnetbeans.dirs="/usr/local/jmonkeyplatform/bin/…/jmonkeyplatform:/usr/local/jmonkeyplatform/bin/…/extra:/usr/local/jmonkeyplatform/bin/…/harness:/usr/local/jmonkeyplatform/bin/…/ide:/usr/local/jmonkeyplatform/bin/…/java:" -Dnetbeans.home="/usr/local/jmonkeyplatform/platform" ‘-Xms24m’ ‘-Xmx512m’ ‘-XX:PermSize=256m’ -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath="/home/glauco/.jmonkeyplatform/dev/var/log/heapdump.hprof" org.netbeans.Main --userdir “/home/glauco/.jmonkeyplatform/dev” “–branding” “jmonkeyplatform” 0<&0

root@glauco-rf411:/usr/local#





ERROR 5: NodeHash::hash_find_insert(Node*)+0x7a


A fatal error has been detected by the Java Runtime Environment:

#

SIGSEGV (0xb) at pc=0xb70a421a, pid=17636, tid=2194668400

#

JRE version: 6.0_26-b03

Java VM: Java HotSpot™ Server VM (20.1-b02 mixed mode linux-x86 )

Problematic frame:

V [libjvm.so+0x61721a] NodeHash::hash_find_insert(Node*)+0x7a

#

An error report file with more information is saved as:

/usr/local/hs_err_pid17636.log

#

If you would like to submit a bug report, please visit:

http://java.sun.com/webapps/bugreport/crash.jsp

#

/usr/local/jmonkeyplatform/bin/…/platform/lib/nbexec: linha 548: 17636 Abortado “/usr/lib/jvm/java-6-sun/bin/java” -Djdk.home="/usr/lib/jvm/java-6-sun" -classpath “/usr/local/jmonkeyplatform/platform/lib/boot.jar:/usr/local/jmonkeyplatform/platform/lib/org-openide-modules.jar:/usr/local/jmonkeyplatform/platform/lib/org-openide-util.jar:/usr/local/jmonkeyplatform/platform/lib/org-openide-util-lookup.jar:/usr/lib/jvm/java-6-sun/lib/dt.jar:/usr/lib/jvm/java-6-sun/lib/tools.jar” -Dnetbeans.dirs="/usr/local/jmonkeyplatform/bin/…/jmonkeyplatform:/usr/local/jmonkeyplatform/bin/…/extra:/usr/local/jmonkeyplatform/bin/…/harness:/usr/local/jmonkeyplatform/bin/…/ide:/usr/local/jmonkeyplatform/bin/…/java:" -Dnetbeans.home="/usr/local/jmonkeyplatform/platform" ‘-Xms24m’ ‘-Xmx512m’ ‘-XX:PermSize=256m’ -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath="/home/glauco/.jmonkeyplatform/dev/var/log/heapdump.hprof" org.netbeans.Main --userdir “/home/glauco/.jmonkeyplatform/dev” “–branding” “jmonkeyplatform” 0<&0

root@glauco-rf411:/usr/local#