We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexSuggestions & BugsSoftware Bugs › OpenGL Exported App Crashes
Page Index Toggle Pages: 1
OpenGL Exported App Crashes (Read 714 times)
OpenGL Exported App Crashes
May 4th, 2006, 8:59pm
 
I have an OpenGL app that is supposed to run for days/weeks. When I export the app (in windows) and run it, it crashes anywhere between 10 minutes and 6 hours (but its inevitable). It doesn't look like a memory problem because when I track memory, GC seems to do a full sweep every two minutes and return me to the same amount of free memory, and when it finally crashes, there is much memory available.

After it crashes, I usually have to reboot in order to run the app again.

The interesting thing is that when I simply click 'play' and run it through Processing, it lasts forever. (side note: Present Sketch doesn't work for me as it only gives me a grey background)

Note 1: I noted the bug with instancing PImages but I only use beginShape() and endShape() and text() for all my drawing needs.

Note 2: This also happened back in 111 when I used the executable .jar files.
Re: OpenGL Exported App Crashes
Reply #1 - May 5th, 2006, 12:05am
 
I think the first step to finding the problem is rooting the general cause.  It could be Processing, processing's opengl wrapper, Jogl, OpenGL, your video card drivers, the card itself, or something else altogether.

First try running it with the P3D rendering engine and see if it crashes.  If it does, the problem is in processing, and you can disregard the rest.

If it doesn't, then try finding another jogl application (maybe a demo from their website).  Run it for the same amount of time and see if it crashes.

If that doesn't crash, then the problem is in Processing's opengl implementation and you can disregard the rest.

If it crashes, then the problem has nothing to do with processing and you should see if you can find a non-jogl opengl app and run it for a similar amount of time (maybe something with GLUT).

If that doesn't crash then the problem is in JOGL, and basically all you can do is complain to them (probably try the latest cvs/whatever cutting edge version of jogl).

If that does crash, then something is wrong with your opengl setup, you can try upgrading drivers, trying on another computer, or whatever.

Basically follow this kind of reasoning and you will get a better "big picture" of the cause of the problem.

Marcello
Re: OpenGL Exported App Crashes
Reply #2 - May 5th, 2006, 1:46am
 
I'm already slowly tracing along that path, but since each crash takes hours to produce I can only do a few test runs a day. My posting here is to see if anyone has also run into this problem and may have insights to share.
Re: OpenGL Exported App Crashes
Reply #3 - May 5th, 2006, 2:37am
 
Try running multiple copies simultaneously and maybe it'll crash sooner?
Re: OpenGL Exported App Crashes
Reply #4 - May 5th, 2006, 2:40pm
 
that sounds to me like you have a version of java installed on your machine, and that one causes the crashing, but when run from inside the p5 environment, the included version of java doesn't cause the crash.

are you using the version of the p5 download that includes java? if so, that's java 1.4.2_08 (or 09? or 10? hrm..) and you might have 1.5 installed on your machine, which is what's used when not running inside the p5 environment.

if that's the case, you might try copying the 'java' folder from your processing download to the same folder as your exported exe file, and see if that fixes it.
Re: OpenGL Exported App Crashes
Reply #5 - May 5th, 2006, 8:24pm
 
Ahh that sounds rather plausible, since I do have Java 1.5 installed. "Present Sketch" also crashes however ... does that use the system's Java or P5's Java? I'll report back when I have more info...
Re: OpenGL Exported App Crashes
Reply #6 - May 5th, 2006, 8:40pm
 
Nevermind ... it seems now that this thing is my fault. Thanks for all the advice though as they were good for learning.

The one instance where I run the program from Processing finally crashed after 3 days, and it was because of a RuntimeException invoked during a proXML loadElementFrom() call. Maybe the server cannot be accessed at the time, but basically I failed to catch that exception.
Page Index Toggle Pages: 1