GLX issue (ERROR: unable to initialize VideoManager)

For those having trouble installing/running the game or to report a bug

Moderator: Staff

raging_hog
Contributor
Posts: 20
Joined: Mon Oct 09, 2006 8:08 am
Location: Lahti, Finland

GLX issue (ERROR: unable to initialize VideoManager)

Postby raging_hog » Mon Oct 09, 2006 8:35 am

Try to run the game and it gives the above error?
And if you try to run it with the "-d all"-flag it says, among other things:

...
Couldn't find matching GLX visual
VIDEO ERROR: SDL_SetVideoMode() failed in ApplySettings()!
VIDEO ERROR: ChangeMode() failed in GameVideo::SingletonInitialize()!
ERROR: unable to initialize VideoManager
...

Have a shot at this solution:
While in the directory from where you tried to run the game,
open the file src/engine/video/video.cpp
find these rows:

SDL_GL_SetAttribute(SDL_GL_RED_SIZE, 8);
SDL_GL_SetAttribute(SDL_GL_GREEN_SIZE, 8);
SDL_GL_SetAttribute(SDL_GL_BLUE_SIZE, 8);
SDL_GL_SetAttribute(SDL_GL_DEPTH_SIZE, 16);
SDL_GL_SetAttribute(SDL_GL_ALPHA_SIZE, 8);
SDL_GL_SetAttribute(SDL_GL_DOUBLEBUFFER, 1);

and change the numbers in the ends of the rows.
This worked for me:

SDL_GL_SetAttribute(SDL_GL_RED_SIZE, 5);
SDL_GL_SetAttribute(SDL_GL_GREEN_SIZE, 6);
SDL_GL_SetAttribute(SDL_GL_BLUE_SIZE, 5);
SDL_GL_SetAttribute(SDL_GL_DEPTH_SIZE, 16);
SDL_GL_SetAttribute(SDL_GL_ALPHA_SIZE, 0);
SDL_GL_SetAttribute(SDL_GL_DOUBLEBUFFER, 1);

And also this worked:

SDL_GL_SetAttribute(SDL_GL_RED_SIZE, 1);
SDL_GL_SetAttribute(SDL_GL_GREEN_SIZE, 1);
SDL_GL_SetAttribute(SDL_GL_BLUE_SIZE, 1);
SDL_GL_SetAttribute(SDL_GL_DEPTH_SIZE, 8);
SDL_GL_SetAttribute(SDL_GL_ALPHA_SIZE, 0);
SDL_GL_SetAttribute(SDL_GL_DOUBLEBUFFER, 1);

Then run make.
Don't know if the Debian package has the sources but this works atleast with the SVN version and the demo tarball.

This program I found might help in finding out what modes your system supports:
http://www.linuxdevcenter.com/linux/200 ... /modes.cpp
it needs to be compiled with `sdl-config --libs` `sdl-config --cflags`
outside
Newbie
Posts: 15
Joined: Thu Oct 05, 2006 7:33 pm

Postby outside » Mon Oct 09, 2006 9:28 am

All I have to say is "woot!"

I can now run the program without a video error.

These values worked for me:
SDL_GL_SetAttribute(SDL_GL_RED_SIZE, 5);
SDL_GL_SetAttribute(SDL_GL_GREEN_SIZE, 6);
SDL_GL_SetAttribute(SDL_GL_BLUE_SIZE, 5);
SDL_GL_SetAttribute(SDL_GL_DEPTH_SIZE, 16);
SDL_GL_SetAttribute(SDL_GL_ALPHA_SIZE, 0);
SDL_GL_SetAttribute(SDL_GL_DOUBLEBUFFER, 1);

According to the modes.cpp program, I can also set the DEPTH_SIZE to 8 if need be.
User avatar
Steu
Developer
Posts: 926
Joined: Thu Jan 05, 2006 10:41 pm
Location: Medicine Hat
Contact:

Postby Steu » Mon Oct 09, 2006 2:37 pm

Does the game still run correctly with these settings, because what you done is change the graphics setting from a 32-bit mode to a 16-bit mode. Especially you've remove the alpha setting, does the transparency still show through correctly, because we use alot of transparency in our images.
raging_hog
Contributor
Posts: 20
Joined: Mon Oct 09, 2006 8:08 am
Location: Lahti, Finland

Postby raging_hog » Mon Oct 09, 2006 6:07 pm

It actually works surprisingly well. I didn't even notice the differences until I just a minute ago played it the same time with my WinXP-laptop. My desktop monitor is bad and dimmer but I'd say atleast in the main menu the background is clearly more pixelated with the stripped settings. Of course it might crash somewhere not included in the demo depending on how it's coded.
ettin
Junior Member
Posts: 45
Joined: Thu Aug 31, 2006 9:23 pm

Re: GLX issue (ERROR: unable to initialize VideoManager)

Postby ettin » Mon Oct 09, 2006 9:08 pm

Raging_Hog wrote:Then run make.
Don't know if the Debian package has the sources but this works atleast with the SVN version and the demo tarball.


Yeah, you can get the sources from:

Code: Select all

deb-src http://debian.ettin.org/allacrost/ unstable main

Return to “Technical Issues”

Who is online

Users browsing this forum: No registered users and 1 guest