Fix for #1577, SDL_RenderCopyEx - Runtime check fails when dstrect == NULL and center == NULL

Thanks Michael Ehrmann.
This commit is contained in:
Gabriel Jacobo 2012-08-24 11:56:21 -03:00
parent 1114169772
commit 5c98584a78

View file

@ -1260,10 +1260,10 @@ SDL_RenderCopyEx(SDL_Renderer * renderer, SDL_Texture * texture,
/* We don't intersect the dstrect with the viewport as RenderCopy does because of potential rotation clipping issues... TODO: should we? */
if (dstrect) real_dstrect = *dstrect;
else {
real_srcrect.x = 0;
real_srcrect.y = 0;
real_srcrect.w = renderer->viewport.w;
real_srcrect.h = renderer->viewport.h;
real_dstrect.x = 0;
real_dstrect.y = 0;
real_dstrect.w = renderer->viewport.w;
real_dstrect.h = renderer->viewport.h;
}
if (texture->native) {