odd error

Hi All,

I just cobbled up a very simple jogl app which renders a frame then throws an exception:

Exception in thread “Thread-3” java.lang.NullPointerException
at net.java.games.jogl.Animator$1.run(Animator.java:112)
at java.lang.Thread.run(Thread.java:595)

Any idea what might cause a break there? I’ve seen where the thread code breaks - the runnable target is null - but not knowing what Animator does, I’m not sure why this might happen.

I’m sure it’s my fault :o) Any ideas?

Forget it :slight_smile: I found the problem - the canvas was null (I’d shadowed the class-wide canvas with a local variable of the same name - doh! So I was able to set the code up properly but it failed with a null pointer exception when the animator was started in another method).

sigh it’s always the really DUMB errors with me :slight_smile:

fyi, There’s actually an option in Eclipse to throw you a warning when it thinkgs you might have done that very thing. It’s quite useful at times.

Ta, but I’ve recently gone over to Netbeans :o)