Bienvenue, Invité. Merci de vous connecter ou de vous inscrire.
Avez-vous perdu votre e-mail d'activation ?

Auteur Sujet: Exception à la création d'une sf::Window  (Lu 1797 fois)

0 Membres et 1 Invité sur ce sujet

SmallPhil

  • Newbie
  • *
  • Messages: 7
    • Voir le profil
Exception à la création d'une sf::Window
« le: Août 26, 2016, 09:41:45 pm »
Bonjour,

lorsque j'utilise le debugger en version Debug sous Visual Studio, j'ai un message d'exception:

«Exception thrown at 0x77993923 (ntdll.dll) in test exception on startup sfml.exe: 0xC0000005: Access violation reading location 0x701F14C8.»

Le programme fonctionne bien quand je l'ignore, mais c'est tout de même gênant de toujours avoir ce message :/


Code minimal:
#include <SFML/Window.hpp>

int main()
{
        sf::Window window({ 640, 480 }, "test");
        return 0;
}
 

Call stack:
> test exception on startup sfml.exe!sf::priv::WglContext::setDevicePixelFormat(unsigned int bitsPerPixel) Line 398 C++
  test exception on startup sfml.exe!sf::priv::WglContext::createSurface(sf::priv::WglContext * shared, unsigned int width, unsigned int height, unsigned int bitsPerPixel) Line 535 C++
  test exception on startup sfml.exe!sf::priv::WglContext::WglContext(sf::priv::WglContext * shared) Line 90 C++
  test exception on startup sfml.exe!sf::priv::GlContext::globalInit() Line 182 C++
  test exception on startup sfml.exe!sf::GlResource::GlResource() Line 56 C++
  test exception on startup sfml.exe!sf::Window::Window(sf::VideoMode mode, const sf::String & title, unsigned int style, const sf::ContextSettings & settings) Line 60 C++
  test exception on startup sfml.exe!main() Line 5 C++


J'avais l'exception dans un projet sous SFML 2.3.2, j'ai donc essayé avec SFML 2.4.0, mais le résultat est le même :/ Est-ce un bug de SFML?

Merci!

valentin_616

  • Newbie
  • *
  • Messages: 8
    • Voir le profil
Re : Exception à la création d'une sf::Window
« Réponse #1 le: Août 29, 2016, 09:26:08 pm »
Salut
essai:
sf::Window window(sf::VideoMode(1280,720),"SFML window")
 

SmallPhil

  • Newbie
  • *
  • Messages: 7
    • Voir le profil
Re : Exception à la création d'une sf::Window
« Réponse #2 le: Août 30, 2016, 02:28:07 am »
Même exception à la même ligne...