Lines Matching refs:src

85 _colorkey(SDL_Surface *src)  in _colorkey()  argument
88 if (SDL_HasColorKey(src)) { in _colorkey()
89 SDL_GetColorKey(src, &key); in _colorkey()
156 computeSourceIncrements90(SDL_Surface * src, int bpp, int angle, int flipx, int flipy, in computeSourceIncrements90() argument
159 int pitch = flipy ? -src->pitch : src->pitch; in computeSourceIncrements90()
164 case 0: *sincx = bpp; *sincy = pitch - src->w * *sincx; *signx = *signy = 1; break; in computeSourceIncrements90()
165 case 1: *sincx = -pitch; *sincy = bpp - *sincx * src->h; *signx = 1; *signy = -1; break; in computeSourceIncrements90()
166 case 2: *sincx = -bpp; *sincy = -src->w * *sincx - pitch; *signx = *signy = -1; break; in computeSourceIncrements90()
167 … case 3: default: *sincx = pitch; *sincy = -*sincx * src->h - bpp; *signx = -1; *signy = 1; break; in computeSourceIncrements90()
180 …Uint8 *sp = (Uint8*)src->pixels, *dp = (Uint8*)dst->pixels, *de; …
182 …computeSourceIncrements90(src, sizeof(pixelType), angle, flipx, flipy, &sincx, &sincy, &signx, &si…
183 …if (signx < 0) sp += (src->w-1)*sizeof(pixelType); …
184 …if (signy < 0) sp += (src->h-1)*src->pitch; …
199 transformSurfaceRGBA90(SDL_Surface * src, SDL_Surface * dst, int angle, int flipx, int flipy) in transformSurfaceRGBA90() argument
205 transformSurfaceY90(SDL_Surface * src, SDL_Surface * dst, int angle, int flipx, int flipy) in transformSurfaceY90() argument
232 _transformSurfaceRGBA(SDL_Surface * src, SDL_Surface * dst, int cx, int cy, int isin, int icos, int… in _transformSurfaceRGBA() argument
242 xd = ((src->w - dst->w) << 15); in _transformSurfaceRGBA()
243 yd = ((src->h - dst->h) << 15); in _transformSurfaceRGBA()
246 sw = src->w - 1; in _transformSurfaceRGBA()
247 sh = src->h - 1; in _transformSurfaceRGBA()
264 if ((dx > -1) && (dy > -1) && (dx < (src->w-1)) && (dy < (src->h-1))) { in _transformSurfaceRGBA()
265 sp = (tColorRGBA *) ((Uint8 *) src->pixels + src->pitch * dy) + dx; in _transformSurfaceRGBA()
269 sp += (src->pitch/4); in _transformSurfaceRGBA()
313 if ((unsigned)dx < (unsigned)src->w && (unsigned)dy < (unsigned)src->h) { in _transformSurfaceRGBA()
316 *pc = *((tColorRGBA *)((Uint8 *)src->pixels + src->pitch * dy) + dx); in _transformSurfaceRGBA()
346 transformSurfaceY(SDL_Surface * src, SDL_Surface * dst, int cx, int cy, int isin, int icos, int fli… in transformSurfaceY() argument
355 xd = ((src->w - dst->w) << 15); in transformSurfaceY()
356 yd = ((src->h - dst->h) << 15); in transformSurfaceY()
364 SDL_memset(pc, (int)(_colorkey(src) & 0xff), dst->pitch * dst->h); in transformSurfaceY()
375 if ((unsigned)dx < (unsigned)src->w && (unsigned)dy < (unsigned)src->h) { in transformSurfaceY()
376 if (flipx) dx = (src->w-1)-dx; in transformSurfaceY()
377 if (flipy) dy = (src->h-1)-dy; in transformSurfaceY()
378 *pc = *((tColorY *)src->pixels + src->pitch * dy + dx); in transformSurfaceY()
417 SDLgfx_rotateSurface(SDL_Surface * src, double angle, int centerx, int centery, int smooth, int fli… in SDLgfx_rotateSurface() argument
428 if (src == NULL) in SDLgfx_rotateSurface()
431 if (SDL_HasColorKey(src)) { in SDLgfx_rotateSurface()
432 if (SDL_GetColorKey(src, &colorkey) == 0) { in SDLgfx_rotateSurface()
438 is8bit = src->format->BitsPerPixel == 8 && colorKeyAvailable; in SDLgfx_rotateSurface()
439 if (!(is8bit || (src->format->BitsPerPixel == 32 && src->format->Amask))) in SDLgfx_rotateSurface()
452 for (i = 0; i < src->format->palette->ncolors; i++) { in SDLgfx_rotateSurface()
453 rz_dst->format->palette->colors[i] = src->format->palette->colors[i]; in SDLgfx_rotateSurface()
455 rz_dst->format->palette->ncolors = src->format->palette->ncolors; in SDLgfx_rotateSurface()
460 src->format->Rmask, src->format->Gmask, in SDLgfx_rotateSurface()
461 src->format->Bmask, src->format->Amask); in SDLgfx_rotateSurface()
471 SDL_GetSurfaceBlendMode(src, &blendmode); in SDLgfx_rotateSurface()
495 if (SDL_MUSTLOCK(src)) { in SDLgfx_rotateSurface()
496 SDL_LockSurface(src); in SDLgfx_rotateSurface()
514 transformSurfaceY90(src, rz_dst, angle90, flipx, flipy); in SDLgfx_rotateSurface()
516 transformSurfaceY(src, rz_dst, centerx, centery, (int)sangleinv, (int)cangleinv, in SDLgfx_rotateSurface()
522 transformSurfaceRGBA90(src, rz_dst, angle90, flipx, flipy); in SDLgfx_rotateSurface()
524 _transformSurfaceRGBA(src, rz_dst, centerx, centery, (int)sangleinv, (int)cangleinv, in SDLgfx_rotateSurface()
530 if (SDL_MUSTLOCK(src)) { in SDLgfx_rotateSurface()
531 SDL_UnlockSurface(src); in SDLgfx_rotateSurface()