Mercurial > sdl-ios-xcode
comparison src/video/SDL_blit_A.c @ 2260:202ddfd1cfb1
indent
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Fri, 17 Aug 2007 02:55:21 +0000 |
parents | 340942cfda48 |
children | c20476d7d7b3 |
comparison
equal
deleted
inserted
replaced
2259:1e690901ecd7 | 2260:202ddfd1cfb1 |
---|---|
369 Uint64 multmask; | 369 Uint64 multmask; |
370 | 370 |
371 __m64 src1, dst1, mm_alpha, mm_zero, dmask; | 371 __m64 src1, dst1, mm_alpha, mm_zero, dmask; |
372 | 372 |
373 mm_zero = _mm_setzero_si64(); /* 0 -> mm_zero */ | 373 mm_zero = _mm_setzero_si64(); /* 0 -> mm_zero */ |
374 multmask = 0xFFFF; | 374 multmask = 0xFFFF; |
375 multmask <<= (ashift * 2); | 375 multmask <<= (ashift * 2); |
376 multmask = ~multmask; | 376 multmask = ~multmask; |
377 dmask = *(__m64 *) & multmask; /* dst alpha mask -> dmask */ | 377 dmask = *(__m64 *) & multmask; /* dst alpha mask -> dmask */ |
378 | 378 |
379 while (height--) { | 379 while (height--) { |
1387 Uint64 multmask; | 1387 Uint64 multmask; |
1388 | 1388 |
1389 __m64 src1, dst1, mm_alpha, mm_zero, dmask; | 1389 __m64 src1, dst1, mm_alpha, mm_zero, dmask; |
1390 | 1390 |
1391 mm_zero = _mm_setzero_si64(); /* 0 -> mm_zero */ | 1391 mm_zero = _mm_setzero_si64(); /* 0 -> mm_zero */ |
1392 multmask = 0xFFFF; | 1392 multmask = 0xFFFF; |
1393 multmask <<= (ashift * 2); | 1393 multmask <<= (ashift * 2); |
1394 multmask = ~multmask; | 1394 multmask = ~multmask; |
1395 dmask = *(__m64 *) & multmask; /* dst alpha mask -> dmask */ | 1395 dmask = *(__m64 *) & multmask; /* dst alpha mask -> dmask */ |
1396 | 1396 |
1397 while (height--) { | 1397 while (height--) { |
1872 | 1872 |
1873 /* fast RGB555->RGB555 blending with surface alpha */ | 1873 /* fast RGB555->RGB555 blending with surface alpha */ |
1874 static void | 1874 static void |
1875 Blit555to555SurfaceAlpha(SDL_BlitInfo * info) | 1875 Blit555to555SurfaceAlpha(SDL_BlitInfo * info) |
1876 { | 1876 { |
1877 unsigned alpha = (info->cmod >> 24); /* downscale alpha to 5 bits */ | 1877 unsigned alpha = (info->cmod >> 24); /* downscale alpha to 5 bits */ |
1878 if (alpha == 128) { | 1878 if (alpha == 128) { |
1879 Blit16to16SurfaceAlpha128(info, 0xfbde); | 1879 Blit16to16SurfaceAlpha128(info, 0xfbde); |
1880 } else { | 1880 } else { |
1881 int width = info->d_width; | 1881 int width = info->d_width; |
1882 int height = info->d_height; | 1882 int height = info->d_height; |