Mercurial > sdl-ios-xcode
comparison src/video/SDL_blit_A.c @ 1443:9ebbbb4ae53b
Fixed some OpenWatcom warnings
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Sun, 26 Feb 2006 19:37:40 +0000 |
parents | 5f52867ba65c |
children | 84de7511f79f |
comparison
equal
deleted
inserted
replaced
1442:e3242177fe4a | 1443:9ebbbb4ae53b |
---|---|
1466 | 1466 |
1467 while(w > 1) { | 1467 while(w > 1) { |
1468 Uint32 sw, dw, s; | 1468 Uint32 sw, dw, s; |
1469 sw = *(Uint32 *)srcp; | 1469 sw = *(Uint32 *)srcp; |
1470 dw = *(Uint32 *)dstp; | 1470 dw = *(Uint32 *)dstp; |
1471 if(SDL_BYTEORDER == SDL_BIG_ENDIAN) | 1471 #if SDL_BYTEORDER == SDL_BIG_ENDIAN |
1472 s = (prev_sw << 16) + (sw >> 16); | 1472 s = (prev_sw << 16) + (sw >> 16); |
1473 else | 1473 #else |
1474 s = (prev_sw >> 16) + (sw << 16); | 1474 s = (prev_sw >> 16) + (sw << 16); |
1475 #endif | |
1475 prev_sw = sw; | 1476 prev_sw = sw; |
1476 *(Uint32 *)dstp = BLEND2x16_50(dw, s, mask); | 1477 *(Uint32 *)dstp = BLEND2x16_50(dw, s, mask); |
1477 dstp += 2; | 1478 dstp += 2; |
1478 srcp += 2; | 1479 srcp += 2; |
1479 w -= 2; | 1480 w -= 2; |
1480 } | 1481 } |
1481 | 1482 |
1482 /* final pixel if any */ | 1483 /* final pixel if any */ |
1483 if(w) { | 1484 if(w) { |
1484 Uint16 d = *dstp, s; | 1485 Uint16 d = *dstp, s; |
1485 if(SDL_BYTEORDER == SDL_BIG_ENDIAN) | 1486 #if SDL_BYTEORDER == SDL_BIG_ENDIAN |
1486 s = (Uint16)prev_sw; | 1487 s = (Uint16)prev_sw; |
1487 else | 1488 #else |
1488 s = (Uint16)(prev_sw >> 16); | 1489 s = (Uint16)(prev_sw >> 16); |
1490 #endif | |
1489 *dstp = BLEND16_50(d, s, mask); | 1491 *dstp = BLEND16_50(d, s, mask); |
1490 srcp++; | 1492 srcp++; |
1491 dstp++; | 1493 dstp++; |
1492 } | 1494 } |
1493 srcp += srcskip - 1; | 1495 srcp += srcskip - 1; |