SFML community forums
Help => General => Topic started by: Bicepz on March 17, 2011, 10:19:05 am
-
I'm trying to install SFML. I've been working over the tutorial for quite some time and can not figure out why my library is not being installed.
I went through and added the path of sfml lib and include to vs VC++ directories / libraries
I also added the sfml library to my projects linker input but it still returns
Cannot open include file: 'SFML/Window.hpp': No such file or directory
here is the code
#include "stdafx.h"
#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;
}
I'm new to VS. Is there something I am doing wrong? I've tried putting all the dll's in my projects directories and it still wont work.
-
This code doesn't include Window.hpp. What's inside stdafx.h?
-
Nothing, its just the default header file that's created with win32 console apps.
-
So you can't have this error with this code. Are you really sure that it says "Window.hpp" and not "System.hpp"?
-
Oh I had an include for the window as well just testing if it would work. It did not. But this code gives the same error for System.hpp.
-
Ok. There's something you did wrong, follow the tutorial again and make sure that you did exactly what's explained, with the help of screenshots.