--- src/render/opengl/SDL_render_gl.c 2014-09-25 08:49:32.124062188 +0200 +++ src/render/opengl/SDL_render_gl.c.orig 2014-09-24 22:22:09.890435986 +0200 @@ -1364,20 +1364,20 @@ return -1; } - /* /\* Flip the rows to be top-down *\/ */ - /* length = rect->w * SDL_BYTESPERPIXEL(temp_format); */ - /* src = (Uint8*)temp_pixels + (rect->h-1)*temp_pitch; */ - /* dst = (Uint8*)temp_pixels; */ - /* tmp = SDL_stack_alloc(Uint8, length); */ - /* rows = rect->h / 2; */ - /* while (rows--) { */ - /* SDL_memcpy(tmp, dst, length); */ - /* SDL_memcpy(dst, src, length); */ - /* SDL_memcpy(src, tmp, length); */ - /* dst += temp_pitch; */ - /* src -= temp_pitch; */ - /* } */ - /* SDL_stack_free(tmp); */ + /* Flip the rows to be top-down */ + length = rect->w * SDL_BYTESPERPIXEL(temp_format); + src = (Uint8*)temp_pixels + (rect->h-1)*temp_pitch; + dst = (Uint8*)temp_pixels; + tmp = SDL_stack_alloc(Uint8, length); + rows = rect->h / 2; + while (rows--) { + SDL_memcpy(tmp, dst, length); + SDL_memcpy(dst, src, length); + SDL_memcpy(src, tmp, length); + dst += temp_pitch; + src -= temp_pitch; + } + SDL_stack_free(tmp); status = SDL_ConvertPixels(rect->w, rect->h, temp_format, temp_pixels, temp_pitch,