diff options
author | nullableVoidPtr <30564701+nullableVoidPtr@users.noreply.github.com> | 2018-11-29 19:24:28 +0800 |
---|---|---|
committer | nullableVoidPtr <30564701+nullableVoidPtr@users.noreply.github.com> | 2018-12-06 09:44:08 +0800 |
commit | 3909b6408c0125fe311d49a3029a2806993615f7 (patch) | |
tree | a02365a6eb268dce08941968e11e319f3a7fe080 /src/blit.c | |
parent | 1b33ad6c26fa83aa7b77055ddde59c61df03d0e4 (diff) |
Fix alloc.c as per #386, define INVALID_ constants and rename malloc to alloc as per #325
Some of the INVALID_ are likely erroneously placed, due to lack of documentation
Diffstat (limited to 'src/blit.c')
-rw-r--r-- | src/blit.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/blit.c b/src/blit.c index b4d5f7de5..2ba0e489c 100644 --- a/src/blit.c +++ b/src/blit.c @@ -3,7 +3,7 @@ void BlitBitmapRect4BitWithoutColorKey(struct Bitmap *src, struct Bitmap *dst, u16 srcX, u16 srcY, u16 dstX, u16 dstY, u16 width, u16 height) { - BlitBitmapRect4Bit(src, dst, srcX, srcY, dstX, dstY, width, height, 0xFF); + BlitBitmapRect4Bit(src, dst, srcX, srcY, dstX, dstY, width, height, INVALID_U8); } void BlitBitmapRect4Bit(struct Bitmap *src, struct Bitmap *dst, u16 srcX, u16 srcY, u16 dstX, u16 dstY, u16 width, u16 height, u8 colorKey) @@ -33,7 +33,7 @@ void BlitBitmapRect4Bit(struct Bitmap *src, struct Bitmap *dst, u16 srcX, u16 sr multiplierSrcY = (src->width + (src->width & 7)) >> 3; multiplierDstY = (dst->width + (dst->width & 7)) >> 3; - if (colorKey == 0xFF) + if (colorKey == INVALID_U8) { for (loopSrcY = srcY, loopDstY = dstY; loopSrcY < yEnd; loopSrcY++, loopDstY++) { @@ -132,7 +132,7 @@ void BlitBitmapRect4BitTo8Bit(struct Bitmap *src, struct Bitmap *dst, u16 srcX, multiplierSrcY = (src->width + (src->width & 7)) >> 3; multiplierDstY = (dst->width + (dst->width & 7)) >> 3; - if (colorKey == 0xFF) + if (colorKey == INVALID_U8) { for (loopSrcY = srcY, loopDstY = dstY; loopSrcY < yEnd; loopSrcY++, loopDstY++) { |