Using native Display is choppy or has artefacts (LWJGLCanvas is fine)

Started by Maykin53, October 01, 2013, 11:20:05

Previous topic - Next topic

Maykin53

Hi all.

I'm running into a problem on Windows 7. When I use LWJGL's native display window in (in either full-screen mode or windowed mode), I sometimes run into situations (seemingly at random) where the the display will be choppy or contain artefacts. However, when I use LWJGLCanvas (with the exact same code otherwise), everything is smooth.

I've tried the following:

1. Full-screen Display with vertical sync enabled = occasionally choppy (most noticeable when the camera moves)
2. Full-screen Display with a timed-sync (60 frames) or no sync = rendering artefacts, such as a wave of lines in the top half of the screen (as if the display isn't keeping up with the monitor's refresh rate or something) - again most noticeable when the camera moves
3. Windowed mode with any of the 3 sync options = occasionally choppy (as with test case '1')
4. LWJGL Canvas in a Swing JFrame = completely smooth regardless of the sync method and at all times during gameplay


In addition, I've tried both of the following timing methods:

public long getTime() throws Exception
	{
		return (Sys.getTime()*1000)/Sys.getTimerResolution();
	}


private static long RESOLUTION = 1000000;
	
	public long getTime() throws Exception
	{
		return (System.nanoTime()/EPcEngineTimer.RESOLUTION);
	}


What's strange is that this issue only occurs for me when using the native display on Windows 7.
Has anyone else experienced any related issues on Windows 7 or have any advice?

Many thanks.

Cornix

I might have had the same problem (or similar problem) as you. Try changing some of the settings in your graphics card. It helped me back then and might do the trick for you as well.

Maykin53

Thanks for the reply Cornix. I tried fiddling with the graphics settings but unfortunately no dice.

It ended up being the NVIDIA graphics driver; when I rolled it back to an earlier version the problem no longer occurred.
Hopefully they fix it soon.