1
Window / SFML with QT - No window showing.
« on: September 18, 2012, 03:12:11 am »
Hi guys,
New to the forums, new to sfml and it seems i've run into a brick wall here.
So i've been trying now for the past 20 minutes to try and get SFML's initial tutorial running. I am just to say not using anything related to the QT SDK, just using the IDE, currently all i get on compile is the following command prompt;
http://i.imgur.com/x3Nfx.png
The code compiles fine it seems, so, here's my project file'
And the main.cpp file;
Honestly not sure were im going wrong, any help is greatly appreciated, just really want to get up and running .
*As for what version, im using SFML 2.0 RC, using the Visual C++ 2010 build, my compiler it set to us my visual c++ 2010 compiler in the projects file so i don't really know where i am going wrong here
New to the forums, new to sfml and it seems i've run into a brick wall here.
So i've been trying now for the past 20 minutes to try and get SFML's initial tutorial running. I am just to say not using anything related to the QT SDK, just using the IDE, currently all i get on compile is the following command prompt;
http://i.imgur.com/x3Nfx.png
The code compiles fine it seems, so, here's my project file'
Code: [Select]
INCLUDEPATH += "D:\SFML\include"
LIBS += -L"D:\SFML\lib" -lsfml-graphics -lsfml-window -lsfml-network -lsfml-audio -lsfml-system
SOURCES += main.cpp
And the main.cpp file;
#include<SFML/Graphics.hpp>
int main()
{
sf::RenderWindow window(sf::VideoMode(200, 200), "SFML works!");
sf::CircleShape shape(100.f);
shape.setFillColor(sf::Color::Green);
while (window.isOpen())
{
sf::Event event;
while (window.pollEvent(event))
{
if (event.type == sf::Event::Closed)
window.close();
}
window.clear();
window.draw(shape);
window.display();
}
return 0;
}
int main()
{
sf::RenderWindow window(sf::VideoMode(200, 200), "SFML works!");
sf::CircleShape shape(100.f);
shape.setFillColor(sf::Color::Green);
while (window.isOpen())
{
sf::Event event;
while (window.pollEvent(event))
{
if (event.type == sf::Event::Closed)
window.close();
}
window.clear();
window.draw(shape);
window.display();
}
return 0;
}
Honestly not sure were im going wrong, any help is greatly appreciated, just really want to get up and running .
*As for what version, im using SFML 2.0 RC, using the Visual C++ 2010 build, my compiler it set to us my visual c++ 2010 compiler in the projects file so i don't really know where i am going wrong here