No Video Devices Available

Hi All,

I keep getting No Video Devices Available when trying to run
SDL_Init(SDL_INIT_VIDEO). I’ve read through the FAQ for the section
regarding this error, but I can’t seem to get it working. ANy help would be
greatly appreciated.

Tim

What OS are you using? Under Linux, if the environment variable
SDL_VIDEODRIVER is set to “dga” (to use the DGA backend), then you need to
run the program as root. This is a limitation of DGA itself, not SDL or SDL’s
DGA backend. Not running it as root will simply cause SDL to return an error
stating that it couldn’t find any video devices (since it can’t use DGA).

So, the solution would be to either run the program as root (bad), or change
SDL_VIDEODRIVER to “x11” (good).

-Sean RidenourOn Thursday 18 December 2003 3:06 pm, Tim Preager wrote:

Hi All,

I keep getting No Video Devices Available when trying to run
SDL_Init(SDL_INIT_VIDEO). I’ve read through the FAQ for the section
regarding this error, but I can’t seem to get it working. ANy help would
be greatly appreciated.

Tim

I’m using RH, doesn’t look like there is an SDL_VIDEODRIVER env var, I tried
to create one, but it didn’t look like it stayed.> ----- Original Message -----

From: Sean Ridenour [mailto:s_ridenour@kewlpc.org]
Sent: Thursday, December 18, 2003 6:12 PM
To: sdl at libsdl.org
Subject: Re: [SDL] No Video Devices Available

On Thursday 18 December 2003 3:06 pm, Tim Preager wrote:

Hi All,

I keep getting No Video Devices Available when trying to run
SDL_Init(SDL_INIT_VIDEO). I’ve read through the FAQ for the section
regarding this error, but I can’t seem to get it working. ANy help would
be greatly appreciated.

Tim

What OS are you using? Under Linux, if the environment variable
SDL_VIDEODRIVER is set to “dga” (to use the DGA backend), then you need to
run the program as root. This is a limitation of DGA itself, not SDL or
SDL’s
DGA backend. Not running it as root will simply cause SDL to return an error

stating that it couldn’t find any video devices (since it can’t use DGA).

So, the solution would be to either run the program as root (bad), or change

SDL_VIDEODRIVER to “x11” (good).

-Sean Ridenour


SDL mailing list
SDL at libsdl.org
http://www.libsdl.org/mailman/listinfo/sdl

I’m using RH, doesn’t look like there is an SDL_VIDEODRIVER env var, I
tried to create one, but it didn’t look like it stayed.

Assuming that you’re using X Windows, set it to “x11” right before you run
your program, then check it right after:
export SDL_VIDEODRIVER=“x11”
./yourprogram
echo $SDL_VIDEODRIVER

and see what happens.

-Sean Ridenour> -----Original Message-----

From: Sean Ridenour [mailto:@Sean_Ridenour]
Sent: Thursday, December 18, 2003 6:12 PM
To: sdl at libsdl.org
Subject: Re: [SDL] No Video Devices Available

On Thursday 18 December 2003 3:06 pm, Tim Preager wrote:

Hi All,

I keep getting No Video Devices Available when trying to run
SDL_Init(SDL_INIT_VIDEO). I’ve read through the FAQ for the section
regarding this error, but I can’t seem to get it working. ANy help would
be greatly appreciated.

Tim

What OS are you using? Under Linux, if the environment variable
SDL_VIDEODRIVER is set to “dga” (to use the DGA backend), then you need to
run the program as root. This is a limitation of DGA itself, not SDL or
SDL’s
DGA backend. Not running it as root will simply cause SDL to return an
error

stating that it couldn’t find any video devices (since it can’t use DGA).

So, the solution would be to either run the program as root (bad), or
change

SDL_VIDEODRIVER to “x11” (good).

-Sean Ridenour


SDL mailing list
SDL at libsdl.org
http://www.libsdl.org/mailman/listinfo/sdl

Hi All,

I keep getting No Video Devices Available when trying to run
SDL_Init(SDL_INIT_VIDEO). I’ve read through the FAQ for the section
regarding this error, but I can’t seem to get it working. ANy help would be
greatly appreciated.

What have you tried? The FAQ covers the more common cases, but maybe you
can elaborate? Did you build from source? Did you use a pre-built package?

See ya,
-Sam Lantinga, Software Engineer, Blizzard Entertainment

I think I got it working now. I installed it right from the package, since
it’s the easier way. Looks like I needed both SDL_VIDEODRIVER=x11 and also
I had to run ‘xhost + localhost’. I’m not too sure what it does, I think
something to do with allowing local connections to XWindows or something
like that. Do you know why you have to run this before the app?> ----- Original Message -----

From: Sam Lantinga [mailto:slouken@devolution.com]
Sent: Tuesday, December 23, 2003 9:46 AM
To: sdl at libsdl.org
Subject: Re: [SDL] No Video Devices Available

Hi All,

I keep getting No Video Devices Available when trying to run
SDL_Init(SDL_INIT_VIDEO). I’ve read through the FAQ for the section
regarding this error, but I can’t seem to get it working. ANy help would
be
greatly appreciated.

What have you tried? The FAQ covers the more common cases, but maybe you
can elaborate? Did you build from source? Did you use a pre-built package?

See ya,
-Sam Lantinga, Software Engineer, Blizzard Entertainment


SDL mailing list
SDL at libsdl.org
http://www.libsdl.org/mailman/listinfo/sdl