Sign in to follow this  
overeasy

screen res and flickering in JAVA

Recommended Posts

why can't I change the screen resolution? gs.isDisplayChangeSupported() always returns false. and how come a simple loop of simulate() repaint() causes sync issues? IE variables are changing during drawing from the simulation? I used setIgnoreRepaint(false) but that didn't help. does java automatically make a new thread? how do I wait on drawing? thanks in advance...

Share this post


Link to post
Share on other sites
My game extends JFrame and overrides the paint method. It is using a buffer strategy and the flickering is not while idling; it is while the player is scrolling and the scrolling offsets are changing in between each object being painted. it looks horrendous.

When it goes fullscreen, it just changes Graphics2d to win.getGraphics() and paints the same as it normally would. (in case that is the cause of not being able to set fullscreen, but the jittering happens in windowed too)

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this