Hey all,
Just two quick questions that I’m a bit stuck with at the moment.
Firstly, after much researching and fiddling around with my game loop and drawing to the screen, I’ve managed to get rid of all the tearing and other problems. However one still remains… when windowed, my animation although most of the time smooth, when going across the screen can appear to “stutter”.
I won’t bother to post my game loop (I can if you think it’s important though) but I think it is correct, runs at a solid 60fps and when fullscreen - all animation is as smooth as butter! Therefore it has lead me to believe it is not timing that is an issue, just Java2D itself? Would I be right in this?
Is there anything I could possibly do to stop this in Windowed mode?
Secondly, I called three methods with BufferCapabilities to see what was happening, this was the output:
PageFlipping:true
MultiBufferAvailable: false
FullScreenRequired:false
Surely MultiBufferAvailable should be true? I’m using BufferStrategy… set up as… createBufferStrategy(2); and I get the graphics from the buffer, write to buffer, then show buffer. So is that correct or am I missing something?
Any help would be appreciated! (Would be good to know if it is possible to achieve smooth animation in a window, or only full screen at the moment).
P.S. Although I know the solution would be to use LWJGL etc, for now I’ve stuck with doing it the hard way heh!