Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: Access Violation in VS2010, but not in VS2008  (Read 1524 times)

0 Members and 1 Guest are viewing this topic.

Portalboat

  • Newbie
  • *
  • Posts: 9
    • View Profile
Access Violation in VS2010, but not in VS2008
« on: February 07, 2011, 07:20:07 am »
What the title says. I recently upgrading to VS2010, but when I try to run the program, it gives me an access violation. However, when I run the EXACT SAME code in VS2008, it doesn't crash, and it runs correctly. The program is just a basic main() function:
Code: [Select]
#include <SFML/Graphics.hpp>
int main()
{
//Create main window, using the best available resolution, and make the reference
sf::RenderWindow App(sf::VideoMode(800, 600, 32), "SFML Window");

//Reference Classes

//This is the main loop, it will loop until you exit the system.
while (App.IsOpened())
{
//Here we process the events list
sf::Event Event;
while (App.GetEvent(Event))
{
//Close window: exit
if (Event.Type == sf::Event::Closed)
{
App.Close();
}
//Clear the screen with a color

//Here you will draw all of the stuff in the frame buffer

//Render the frame on screen
App.Display();
}
}
return EXIT_SUCCESS;
}


Why would it be glitching out like this?

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32504
    • View Profile
    • SFML's website
    • Email
Access Violation in VS2010, but not in VS2008
« Reply #1 on: February 07, 2011, 07:29:02 am »
You must recompiler SFML, the 2008 libs are not compatible with 2010.
Laurent Gomila - SFML developer