I re-edited this to appeal to people who need help with the issue, or are google searching as it was very hard to figure out.
Apparently there are issues with SFML right now with certain new graphics card drivers on both Radeon and Nvidia cards.
This issue is fixed by switching to the statically linked version of the library, rather than using the dynamic version.
I don't know the ups and downs of static/dynamic linking, but my window shows up fine now when compiling statically.
[SOLVED] SFML window not showing
Moderator: Coders of Rage
-
- Chaos Rift Regular
- Posts: 101
- Joined: Thu Dec 09, 2010 2:13 am
[SOLVED] SFML window not showing
Last edited by like80ninjas on Wed Apr 27, 2011 4:04 pm, edited 1 time in total.
-
- Chaos Rift Regular
- Posts: 173
- Joined: Thu Feb 11, 2010 9:46 pm
Re: Weird SFML issue. REALLY need help.
That code runs perfectly fine for me :S
-
- Chaos Rift Regular
- Posts: 101
- Joined: Thu Dec 09, 2010 2:13 am
Re: Weird SFML issue. REALLY need help.
Yeah, i've tried to look this up and only found one thread in a random forum where someone had a similar issue, but the people in the thread wrote it off as "64bit windows 7"'s fault.
I don't have windows seven, nor is my pc 64bit. 32 bit vista.
I also heard while searching that it could be an issue with VC2010, but I tried 2008 and I get the same issue. I've tried making new projects as well. It all compiles and runs but all that comes up is a blank console window, that's it.
I don't have windows seven, nor is my pc 64bit. 32 bit vista.
I also heard while searching that it could be an issue with VC2010, but I tried 2008 and I get the same issue. I've tried making new projects as well. It all compiles and runs but all that comes up is a blank console window, that's it.
-
- Chaos Rift Regular
- Posts: 173
- Joined: Thu Feb 11, 2010 9:46 pm
Re: Weird SFML issue. REALLY need help.
Well, I'm running win7 64-bit so that's not an issue. You said:
Does the program exit successfully if you immediately return from your main function before doing anything?like80ninjas wrote:Even if I add cout before the SFML stuff it just opens a blank console window and hangs there.
-
- Chaos Rift Regular
- Posts: 101
- Joined: Thu Dec 09, 2010 2:13 am
Re: Weird SFML issue. REALLY need help.
Well it doesn't exit on it's own. With the code I posted, no keys will work (escape should close it) but when you 'x' out the console window it hangs for maybe 10 seconds(looks like it freezes) and then returns 0 (success).
- short
- ES Beta Backer
- Posts: 548
- Joined: Thu Apr 30, 2009 2:22 am
- Current Project: c++, c
- Favorite Gaming Platforms: SNES, PS2, SNES, SNES, PC NES
- Programming Language of Choice: c, c++
- Location: Oregon, US
Re: [SOLVED] SFML window not showing
like80ninjas wrote:I re-edited this to appeal to people who need help with the issue, or are google searching as it was very hard to figure out.
Apparently there are issues with SFML right now with certain new graphics card drivers on both Radeon and Nvidia cards.
This issue is fixed by switching to the statically linked version of the library, rather than using the dynamic version.
I don't know the ups and downs of static/dynamic linking, but my window shows up fine now when compiling statically.
http://www.learncpp.com/cpp-tutorial/a1 ... libraries/
My github repository contains the project I am currently working on,
link: https://github.com/bjadamson
link: https://github.com/bjadamson