Mercurial > sdl-ios-xcode
changeset 3279:fd207dce9f94
I think this fixes the texture pixel alignment
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Sat, 19 Sep 2009 12:48:52 +0000 |
parents | b2a3cbb9ec08 |
children | 00cace2d9080 |
files | src/video/win32/SDL_d3drender.c |
diffstat | 1 files changed, 4 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/src/video/win32/SDL_d3drender.c Sat Sep 19 07:33:15 2009 +0000 +++ b/src/video/win32/SDL_d3drender.c Sat Sep 19 12:48:52 2009 +0000 @@ -1060,10 +1060,10 @@ data->beginScene = SDL_FALSE; } - minx = (float) dstrect->x; - miny = (float) dstrect->y; - maxx = (float) dstrect->x + dstrect->w; - maxy = (float) dstrect->y + dstrect->h; + minx = (float) dstrect->x - 0.5f; + miny = (float) dstrect->y - 0.5f; + maxx = (float) dstrect->x + dstrect->w - 0.5f; + maxy = (float) dstrect->y + dstrect->h - 0.5f; minu = (float) srcrect->x / texture->w; maxu = (float) (srcrect->x + srcrect->w) / texture->w;