Hi,
I’m developing a simple JOGL application. I’m having a bit of trouble getting the animation to look perfectly smooth. I’m trying a variety of different approches, but they all look slightly jerky. For instance displaying a textured rectangle and letting the user control it by pressing the keyboard.
Problem 1> The rectangle seems to “wobble” as it moves across the screen. I am simply doing a glTranslate to move it. I have also tried using mipmaps, but although it looks better, it doesn’t get rid of the wobble. Is this an aliasing or interpolation issue and does anyone have any ideas?
Problem 2> I can’t seem to get an even frame rate. If I automate the glTranslate (rather than have it being controlled by keyboard, etc) then it seems really jerky. I’ve had it set up so that it if, for instance, it needs to go from point A to point B in 3000 milliseconds, then I figure out how much time as elapsed and then calculate where it should be (ie at the midpoint of AB after 1500ms). This in principle should make sure everything is timed properly, but as I said, it looks a bit jerky. If I have it simply move a certain amount at each loop of the display loop, it still seems uneven.
I’ve read on this forum of people getting hundreds of FPS. I seem to be bouncing between 30 and 60 FPS depending on how much I have on the screen. I am using FPSAnimator set to 100 (I’ve tried different intervals) and also have tried the regular Animator set to runFastAsPossible.
Any help with the wobbling and jerking would be greatly appreciated!
-spiraljetty