Repas Dev
Repas Dev

Reputation: 41

LWJGL 2.9 - Pixel format not accelerated error out of the blue

So, while programming in Java and LWJGL I was working on a simple game for fun. And everything worked, I could run the game, and play. But then I leave my computer alone for about 30 minutes and come back to run the game again, and I get the Pixel format not accelerated error. I don't know where it came from, but I assure you it worked earlier. I thought maybe restarting the engine and game to see if I could fix it again.

Here is my code after restarting:

`

package engine.dungeon.core;

import org.lwjgl.LWJGLException;
import org.lwjgl.opengl.Display;
import org.lwjgl.opengl.DisplayMode;

public class Window {

    public static final int WIDTH = 640, HEIGHT = 480;

    public Window() {
        try {
            Display.setDisplayMode(new DisplayMode(640, 480));
            Display.create();
        } catch (LWJGLException e) {
            e.printStackTrace();
        }
    } 
}

`

Upvotes: 0

Views: 1680

Answers (3)

user5119241
user5119241

Reputation:

This is a known issue with the Nvidia driver 378.49. This driver is simply broken. See for more detail:

or simply google "LWJGL Pixel format not accelerated" and you'll find hundreds of posts mostly from Minecraft users.

Upvotes: 0

Repas Dev
Repas Dev

Reputation: 41

I figured it out! There was an update for my graphics card that I got after restarting my computer for a second time.

Upvotes: 0

Ryan
Ryan

Reputation: 1974

A Pixel format not accelerated error has to do with your graphics card.

  • Some video cards are too old, and should either be updated with drivers, or replaced.
  • Some times GPU drivers could crash so a computer restart may solve your problem

Upvotes: 1

Related Questions