Moridin
Snow Leopard
- Reaction score
- 144
Hey there,
Right now I'm trying to get SFML to work with my Visual Studio 2010, so I can start learning how to make windows applications and games using the libraries within SFML. I'm following the tutorial here to open a new window, but my program seems to break instantly. I really don't know why :S. It seems to build and compile, but then breaks.
Edit: It breaks at this line:
App.Create(sf::VideoMode(800, 600, 32), "SFML Window");
Edit: This is the output I get:
Also, I should note:
On the SFML website, the tutorials for setting it up with Visual Studio seem to be for VS 2008 (Setting up SFML with VS). I managed to get a set of instructions for VS2010 and set it up. I used a short program to test if the SFML libraries were working:
^This program worked fine.
Right now I'm trying to get SFML to work with my Visual Studio 2010, so I can start learning how to make windows applications and games using the libraries within SFML. I'm following the tutorial here to open a new window, but my program seems to break instantly. I really don't know why :S. It seems to build and compile, but then breaks.
Edit: It breaks at this line:
App.Create(sf::VideoMode(800, 600, 32), "SFML Window");
Edit: This is the output I get:
'SFML Tutorials.exe': Loaded 'C:\Users\100464441\Documents\Visual Studio 2010\Projects\SFML Tutorials\Debug\SFML Tutorials.exe', Symbols loaded.
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\ntdll.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\kernel32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\KernelBase.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Users\100464441\Documents\Visual Studio 2010\Projects\SFML Tutorials\Debug\sfml-window-d.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\opengl32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\msvcrt.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\advapi32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\sechost.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\rpcrt4.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\gdi32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\user32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\lpk.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\usp10.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\glu32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\ddraw.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\dciman32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\setupapi.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\cfgmgr32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\oleaut32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\ole32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\devobj.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\dwmapi.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\winmm.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Users\100464441\Documents\Visual Studio 2010\Projects\SFML Tutorials\Debug\sfml-system-d.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\winsxs\x86_microsoft.vc90.debugcrt_1fc8b3b9a1e18e3b_9.0.30729.6161_none_2a4f639a55563668\msvcp90d.dll', Symbols loaded.
'SFML Tutorials.exe': Loaded 'C:\Windows\winsxs\x86_microsoft.vc90.debugcrt_1fc8b3b9a1e18e3b_9.0.30729.6161_none_2a4f639a55563668\msvcr90d.dll', Symbols loaded.
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\msvcp100d.dll', Symbols loaded.
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\msvcr100d.dll', Symbols loaded.
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\imm32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\msctf.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\nvinit.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Program Files\NVIDIA Corporation\coprocmanager\detoured.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Program Files\NVIDIA Corporation\coprocmanager\Nvd3d9wrap.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Program Files\NVIDIA Corporation\coprocmanager\nvdxgiwrap.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\uxtheme.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Program Files\RocketDock\RocketDock.dll', Binary was not built with debug information.
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\psapi.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\wintrust.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\crypt32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\msasn1.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\nvoglv32.dll', Cannot find or open the PDB file
The thread 'Win32 Thread' (0x8c0) has exited with code 0 (0x0).
First-chance exception at 0x75698210 in SFML Tutorials.exe: 0xC0000005: Access violation reading location 0x6e695720.
Unhandled exception at 0x75698210 in SFML Tutorials.exe: 0xC0000005: Access violation reading location 0x6e695720.
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\ntdll.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\kernel32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\KernelBase.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Users\100464441\Documents\Visual Studio 2010\Projects\SFML Tutorials\Debug\sfml-window-d.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\opengl32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\msvcrt.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\advapi32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\sechost.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\rpcrt4.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\gdi32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\user32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\lpk.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\usp10.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\glu32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\ddraw.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\dciman32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\setupapi.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\cfgmgr32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\oleaut32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\ole32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\devobj.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\dwmapi.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\winmm.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Users\100464441\Documents\Visual Studio 2010\Projects\SFML Tutorials\Debug\sfml-system-d.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\winsxs\x86_microsoft.vc90.debugcrt_1fc8b3b9a1e18e3b_9.0.30729.6161_none_2a4f639a55563668\msvcp90d.dll', Symbols loaded.
'SFML Tutorials.exe': Loaded 'C:\Windows\winsxs\x86_microsoft.vc90.debugcrt_1fc8b3b9a1e18e3b_9.0.30729.6161_none_2a4f639a55563668\msvcr90d.dll', Symbols loaded.
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\msvcp100d.dll', Symbols loaded.
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\msvcr100d.dll', Symbols loaded.
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\imm32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\msctf.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\nvinit.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Program Files\NVIDIA Corporation\coprocmanager\detoured.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Program Files\NVIDIA Corporation\coprocmanager\Nvd3d9wrap.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Program Files\NVIDIA Corporation\coprocmanager\nvdxgiwrap.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\uxtheme.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Program Files\RocketDock\RocketDock.dll', Binary was not built with debug information.
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\psapi.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\wintrust.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\crypt32.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\msasn1.dll', Cannot find or open the PDB file
'SFML Tutorials.exe': Loaded 'C:\Windows\System32\nvoglv32.dll', Cannot find or open the PDB file
The thread 'Win32 Thread' (0x8c0) has exited with code 0 (0x0).
First-chance exception at 0x75698210 in SFML Tutorials.exe: 0xC0000005: Access violation reading location 0x6e695720.
Unhandled exception at 0x75698210 in SFML Tutorials.exe: 0xC0000005: Access violation reading location 0x6e695720.
Code:
#include <SFML/Window.hpp>
int main ()
{
sf::Window App;
App.Create(sf::VideoMode(800, 600, 32), "SFML Window");
bool Running = true;
while (Running)
{
sf::Event Event;
while (App.GetEvent(Event))
{
if (Event.Type == sf::Event::Closed)
Running = false;
if ((Event.Type == sf::Event::KeyPressed) && (Event.Key.Code == sf::Key::Escape))
Running = false;
}
App.Display();
}
return EXIT_SUCCESS;
}
Also, I should note:
On the SFML website, the tutorials for setting it up with Visual Studio seem to be for VS 2008 (Setting up SFML with VS). I managed to get a set of instructions for VS2010 and set it up. I used a short program to test if the SFML libraries were working:
Code:
#include <SFML/System.hpp>
#include <iostream>
int main()
{
sf::Clock Clock;
while (Clock.GetElapsedTime() < 5.f)
{
std::cout << Clock.GetElapsedTime() << std::endl;
sf::Sleep(0.5f);
}
return 0;
}
^This program worked fine.