diff options
author | drumsetmonkey <abelleisle@roadrunner.com> | 2016-11-22 21:25:34 -0500 |
---|---|---|
committer | drumsetmonkey <abelleisle@roadrunner.com> | 2016-11-22 21:25:34 -0500 |
commit | 05dd30a5158184fea83d93f53e8100aecaebb74a (patch) | |
tree | 9bf7a49b1aeb7d9b41d0c2fffbddc7f91243bf32 /src/ui.cpp | |
parent | e51b9ee1e0f9b8aeef98b8875f66260db0e7b502 (diff) |
Scaling textures (start)
Diffstat (limited to 'src/ui.cpp')
-rw-r--r-- | src/ui.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -1337,10 +1337,12 @@ void InputSystem::update(entityx::EntityManager &en, entityx::EventManager &ev, break; case SDLK_F12: // Make the BYTE array, factor of 3 because it's RBG. - static GLubyte* pixels; + /*static GLubyte* pixels; pixels = new GLubyte[ 3 * SCREEN_WIDTH * SCREEN_HEIGHT]; glReadPixels(0, 0, SCREEN_WIDTH, SCREEN_HEIGHT, GL_RGB, GL_UNSIGNED_BYTE, pixels); - takeScreenshot(pixels); + takeScreenshot(pixels);*/ + + ev.emit<ScreenshotEvent>(game::SCREEN_WIDTH, game::SCREEN_HEIGHT); std::cout << "Took screenshot" << std::endl; break; |