www.jpct.net

jPCT - a 3d engine for Java => Bugs => Topic started by: rolz on May 03, 2005, 05:36:31 pm

Title: AWTGlRenderer
Post by: rolz on May 03, 2005, 05:36:31 pm
Occurs when AWT canvas is used on complicated scenes

Code: [Select]

Exception in thread "main" java.lang.ArrayIndexOutOfBoundsException: 16384
at com.threed.jpct.AWTBufferList.fill(Unknown Source)
at com.threed.jpct.VisList.extract(Unknown Source)
at com.threed.jpct.AWTDisplayList.add(Unknown Source)
at com.threed.jpct.AWTJPCTCanvas.add(Unknown Source)
at com.threed.jpct.AWTGLRenderer.drawVertexArray(Unknown Source)

at com.threed.jpct.World.draw(Unknown Source)
at com.threed.jpct.World.draw(Unknown Source)
at techno.client.engine.Engine.paintOnce(Engine.java:175)
at techno.client.engine.Engine.start(Engine.java:155)
at techno.editor.map.MapViewer.start(MapViewer.java:61)
at techno.editor.map.MapViewer.main(MapViewer.java:104)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at com.intellij.rt.execution.application.AppMain.main(AppMain.java:78)

Process finished with exit code 0
Title: Ok, figured it out
Post by: rolz on May 03, 2005, 05:40:06 pm
Just figured out the problem was in too small Config.maxPolysVisible setting
Title: Re: Ok, figured it out
Post by: EgonOlsen on May 03, 2005, 11:22:18 pm
Quote from: "rolz"
Just figured out the problem was in too small Config.maxPolysVisible setting
It should not behave this way even in that case. I'll look into it...
Title: AWTGlRenderer
Post by: EgonOlsen on May 03, 2005, 11:56:37 pm
Fixed it. The new version is here:
 
http://www.jpct.net/download/jpctapi_106a2.zip

But if you reach the limit of maxPolysVisible, you'll still get problems, because the polygons wont be drawn anymore. But at least it doesn't crash now.