diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/VideoPlayer.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/VideoPlayer.cpp b/src/VideoPlayer.cpp index 7ce5f19..41b6d0e 100644 --- a/src/VideoPlayer.cpp +++ b/src/VideoPlayer.cpp @@ -185,6 +185,8 @@ namespace QuickMedia { { video_size.x = w; video_size.y = h; + context.reset(new sf::Context(sf::ContextSettings(), w, h)); + context->setActive(true); // TODO: Verify if it's valid to re-create the texture like this, // instead of using deconstructor if(texture.create(w, h)) { @@ -192,8 +194,6 @@ namespace QuickMedia { if(newTextureBuf) textureBuffer = (sf::Uint8*)newTextureBuf; } - context.reset(new sf::Context(sf::ContextSettings(), w, h)); - context->setActive(true); glViewport(0, 0, w, h); context->setActive(false); resize(desired_size); |