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

Author Topic: SFML and Qt  (Read 5242 times)

0 Members and 1 Guest are viewing this topic.

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Re: SFML and Qt
« Reply #15 on: June 06, 2012, 09:10:18 am »
It was not stupid, it's also a good strategy to assume that everything may throw, and make all your code exception-safe. In this case you can do this:
window.clear();
{
    sf::Lock lock(m_mutex);
    window.draw(sprite);
}
window.display();
Laurent Gomila - SFML developer

Foaly

  • Sr. Member
  • ****
  • Posts: 453
    • View Profile
Re: SFML and Qt
« Reply #16 on: June 06, 2012, 09:14:15 am »
Ah ok. That is a good idea. I'll try that later. Thanks again for all the help.

 

anything