src/render/opengl/SDL_render_gl.c
changeset 9977 f9cd179cf50e
parent 9958 687e118144c7
child 9998 f67cf37e9cd4
equal deleted inserted replaced
9976:9637657107a3 9977:f9cd179cf50e
  1050             data->glScissor(renderer->viewport.x + rect->x, renderer->viewport.y + rect->y, rect->w, rect->h);
  1050             data->glScissor(renderer->viewport.x + rect->x, renderer->viewport.y + rect->y, rect->w, rect->h);
  1051         } else {
  1051         } else {
  1052             int w, h;
  1052             int w, h;
  1053 
  1053 
  1054             SDL_GetRendererOutputSize(renderer, &w, &h);
  1054             SDL_GetRendererOutputSize(renderer, &w, &h);
  1055             data->glScissor(renderer->viewport.x + rect->x, (h - renderer->viewport.y - renderer->viewport.h) + rect->y, rect->w, rect->h);
  1055             data->glScissor(renderer->viewport.x + rect->x, h - renderer->viewport.y - rect->y - rect->h, rect->w, rect->h);
  1056         }
  1056         }
  1057     } else {
  1057     } else {
  1058         data->glDisable(GL_SCISSOR_TEST);
  1058         data->glDisable(GL_SCISSOR_TEST);
  1059     }
  1059     }
  1060     return 0;
  1060     return 0;