Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build error: thread '<main>' panicked #7

Closed
MightyPork opened this issue Sep 11, 2015 · 7 comments
Closed

Build error: thread '<main>' panicked #7

MightyPork opened this issue Sep 11, 2015 · 7 comments

Comments

@MightyPork
Copy link
Contributor

Well, I was curious, tried to build it.

Here's what I got:

   Compiling pistoncore-event v0.3.0
   Compiling piston v0.3.0
   Compiling piston2d-opengl_graphics v0.4.0
   Compiling pistoncore-glutin_window v0.4.0
     Running `target/release/rocket`
thread '<main>' panicked at 'called `Result::unwrap()` on an `Err` value: OsError("glx::ChooseFBConfig failed")', src/libcore/result.rs:731
An unknown error occurred

To learn more, run the command again with --verbose.

No idea if it's in your code or somewhere in Rust, just thought you might like to have a look. I've just started learning Rust, so can't make much sense of anything here :P

@MightyPork
Copy link
Contributor Author

oops, a dupe. But I now did what was suggested here, and...

$ cargo run --release
     Running `target/release/rocket`
[glutin] x error code=42 major=0 minor=0!
thread '<main>' panicked at 'called `Result::unwrap()` on an `Err` value: OsError("GL context creation failed")', src/libcore/result.rs:731
An unknown error occurred

To learn more, run the command again with --verbose.

@aochagavia
Copy link
Owner

Are you sure your graphics card supports OpenGL 3.2 and that it is installed in your computer? It seems to me that the problem lies there.

@MightyPork
Copy link
Contributor Author

Not sure, maybe not. It's a ThinkPad x201 with Intel i5. Strange that a 2D game needs high-end graphics, but ok

@aochagavia
Copy link
Owner

I am not sure there is a need for high-end graphics. I guess it should work with older versions of OpenGL (you can try changing this line). I didn't have any special reason to use 3.2.

Good luck learning Rust!

@MightyPork
Copy link
Contributor Author

that did it, I tried _2_1 and works without any problems. Nice game!

@aochagavia
Copy link
Owner

Feel free to submit a PR for this 😉

@MagaTailor
Copy link

On my Odroid C1 it works using mesa after using the above method. To get acceleration via glshim it would have to go down to 1.5

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants