diff options
author | Sethpaien <sethpaien@gmail.com> | 2014-05-08 18:05:30 +0200 |
---|---|---|
committer | Sethpaien <sethpaien@gmail.com> | 2014-05-08 18:05:30 +0200 |
commit | e1fcb2fdfb8b94f7baa212031cad25242514ec4e (patch) | |
tree | 942d3af755d8d4d4d39c592b92df03254d7538fa /src | |
parent | fixed a bug where ExeFs code was being incorrectly masked (diff) | |
download | yuzu-e1fcb2fdfb8b94f7baa212031cad25242514ec4e.tar yuzu-e1fcb2fdfb8b94f7baa212031cad25242514ec4e.tar.gz yuzu-e1fcb2fdfb8b94f7baa212031cad25242514ec4e.tar.bz2 yuzu-e1fcb2fdfb8b94f7baa212031cad25242514ec4e.tar.lz yuzu-e1fcb2fdfb8b94f7baa212031cad25242514ec4e.tar.xz yuzu-e1fcb2fdfb8b94f7baa212031cad25242514ec4e.tar.zst yuzu-e1fcb2fdfb8b94f7baa212031cad25242514ec4e.zip |
Diffstat (limited to 'src')
-rw-r--r-- | src/video_core/renderer_opengl/renderer_opengl.cpp | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/src/video_core/renderer_opengl/renderer_opengl.cpp b/src/video_core/renderer_opengl/renderer_opengl.cpp index b63a73d18..24f9a91fd 100644 --- a/src/video_core/renderer_opengl/renderer_opengl.cpp +++ b/src/video_core/renderer_opengl/renderer_opengl.cpp @@ -58,15 +58,14 @@ void RendererOpenGL::SwapBuffers() { * @todo Early on hack... I'd like to find a more efficient way of doing this /bunnei */ void RendererOpenGL::FlipFramebuffer(const u8* in, u8* out) { - for (int y = 0; y < VideoCore::kScreenTopHeight; y++) { - for (int x = 0; x < VideoCore::kScreenTopWidth; x++) { - int in_coord = (VideoCore::kScreenTopHeight * 3 * x) + (VideoCore::kScreenTopHeight * 3) - - (3 * y + 3); - int out_coord = (VideoCore::kScreenTopWidth * y * 3) + (x * 3); - - out[out_coord + 0] = in[in_coord + 0]; + int in_coord = 0; + for (int x = 0; x < VideoCore::kScreenTopWidth; x++) { + for (int y = VideoCore::kScreenTopHeight-1; y >= 0; y--) { + int out_coord = (x + y * VideoCore::kScreenTopWidth) * 3; + out[out_coord] = in[in_coord]; out[out_coord + 1] = in[in_coord + 1]; out[out_coord + 2] = in[in_coord + 2]; + in_coord+=3; } } } |