src/render/software/SDL_render_sw.c
changeset 11958 d7582d7286aa
parent 11811 5d94cb6b24d3
child 12288 005e1d1bcf05
child 12372 bced4041fcc0
     1.1 --- a/src/render/software/SDL_render_sw.c	Mon May 07 19:26:02 2018 -0700
     1.2 +++ b/src/render/software/SDL_render_sw.c	Mon May 07 19:52:25 2018 -0700
     1.3 @@ -588,18 +588,6 @@
     1.4  }
     1.5  
     1.6  static int
     1.7 -GetScaleQuality(void)
     1.8 -{
     1.9 -    const char *hint = SDL_GetHint(SDL_HINT_RENDER_SCALE_QUALITY);
    1.10 -
    1.11 -    if (!hint || *hint == '0' || SDL_strcasecmp(hint, "nearest") == 0) {
    1.12 -        return 0;
    1.13 -    } else {
    1.14 -        return 1;
    1.15 -    }
    1.16 -}
    1.17 -
    1.18 -static int
    1.19  SW_RenderCopyEx(SDL_Renderer * renderer, SDL_Texture * texture,
    1.20                  const SDL_Rect * srcrect, const SDL_FRect * dstrect,
    1.21                  const double angle, const SDL_FPoint * center, const SDL_RendererFlip flip)
    1.22 @@ -717,7 +705,7 @@
    1.23  
    1.24      if (!retval) {
    1.25          SDLgfx_rotozoomSurfaceSizeTrig(tmp_rect.w, tmp_rect.h, angle, &dstwidth, &dstheight, &cangle, &sangle);
    1.26 -        src_rotated = SDLgfx_rotateSurface(src_clone, angle, dstwidth/2, dstheight/2, GetScaleQuality(), flip & SDL_FLIP_HORIZONTAL, flip & SDL_FLIP_VERTICAL, dstwidth, dstheight, cangle, sangle);
    1.27 +        src_rotated = SDLgfx_rotateSurface(src_clone, angle, dstwidth/2, dstheight/2, (texture->scaleMode == SDL_ScaleModeNearest) ? 0 : 1, flip & SDL_FLIP_HORIZONTAL, flip & SDL_FLIP_VERTICAL, dstwidth, dstheight, cangle, sangle);
    1.28          if (src_rotated == NULL) {
    1.29              retval = -1;
    1.30          }