From: Kenneth B. R. <kbr...@al...> - 2002-10-29 21:20:49
|
What animation technique are you using? I recommend using a GLAnimCanvas with the GLEventListener paradigm for getting the application code to run. If you're calling repaint() on the GLCanvas then the thread switching from the application thread to the AWT thread and back may be affecting your framerate. See http://java.sun.com/products/jfc/tsc/articles/jcanyon/ for an example of this technique in the context of terrain rendering. > I ported some C++/openGL terrain rendering code (uses triangle strips > from indexed vertex arrays compiled into a display list) over to > gl4java. It runs with pretty much the frame speed as the C++ version, > but it stutters slightly. > > I've checked to see whether it was GC causing problems - but I turned on > -verbose:gc and found the GC isn't to blame - GC is happening only > rarely and not causing any visual discontinuities when it does occur. > > Any other ideas what I should look at to find the problem? > > System: Java 1.4.1, gl4Java 2.8.2.0, Windows 2000, NVidia Geforce 256 |