summaryrefslogtreecommitdiff
path: root/Build/source/libs/gd/libgd-src/src/gd_bmp.c
diff options
context:
space:
mode:
authorAkira Kakuto <kakuto@fuk.kindai.ac.jp>2021-02-03 06:51:32 +0000
committerAkira Kakuto <kakuto@fuk.kindai.ac.jp>2021-02-03 06:51:32 +0000
commitc8c75c6ba1679cf8c1811b484701d8b0a261b5d8 (patch)
tree7a6eeed210d8eaa215e70b3d486ed4e3ffa28247 /Build/source/libs/gd/libgd-src/src/gd_bmp.c
parent5f9f8fe99e68c0ef1fbd129019404a3c52e37e8a (diff)
libgd 2.3.1
git-svn-id: svn://tug.org/texlive/trunk@57607 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/libs/gd/libgd-src/src/gd_bmp.c')
-rw-r--r--Build/source/libs/gd/libgd-src/src/gd_bmp.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/Build/source/libs/gd/libgd-src/src/gd_bmp.c b/Build/source/libs/gd/libgd-src/src/gd_bmp.c
index 5bef2d2ab29..e186ac951be 100644
--- a/Build/source/libs/gd/libgd-src/src/gd_bmp.c
+++ b/Build/source/libs/gd/libgd-src/src/gd_bmp.c
@@ -223,10 +223,10 @@ static int _gdImageBmpCtx(gdImagePtr im, gdIOCtxPtr out, int compression)
/* 8-bit colours */
if (!im->trueColor) {
for(i = 0; i< im->colorsTotal; ++i) {
- Putchar(gdImageBlue(im, i), out);
- Putchar(gdImageGreen(im, i), out);
- Putchar(gdImageRed(im, i), out);
- Putchar(0, out);
+ gdPutC(gdImageBlue(im, i), out);
+ gdPutC(gdImageGreen(im, i), out);
+ gdPutC(gdImageRed(im, i), out);
+ gdPutC(0, out);
}
if (compression) {
@@ -247,14 +247,14 @@ static int _gdImageBmpCtx(gdImagePtr im, gdIOCtxPtr out, int compression)
if (compression) {
*uncompressed_row++ = (unsigned char)gdImageGetPixel(im, xpos, row);
} else {
- Putchar(gdImageGetPixel(im, xpos, row), out);
+ gdPutC(gdImageGetPixel(im, xpos, row), out);
}
}
if (!compression) {
/* Add padding to make sure we have n mod 4 == 0 bytes per row */
for (xpos = padding; xpos > 0; --xpos) {
- Putchar('\0', out);
+ gdPutC('\0', out);
}
} else {
int compressed_size = 0;
@@ -267,8 +267,8 @@ static int _gdImageBmpCtx(gdImagePtr im, gdIOCtxPtr out, int compression)
gdPutBuf(uncompressed_row, compressed_size, out);
- Putchar(BMP_RLE_COMMAND, out);
- Putchar(BMP_RLE_ENDOFLINE, out);
+ gdPutC(BMP_RLE_COMMAND, out);
+ gdPutC(BMP_RLE_ENDOFLINE, out);
bitmap_size += 2;
}
}
@@ -279,8 +279,8 @@ static int _gdImageBmpCtx(gdImagePtr im, gdIOCtxPtr out, int compression)
goto cleanup;
}
/* Update filesize based on new values and set compression flag */
- Putchar(BMP_RLE_COMMAND, out);
- Putchar(BMP_RLE_ENDOFBITMAP, out);
+ gdPutC(BMP_RLE_COMMAND, out);
+ gdPutC(BMP_RLE_ENDOFBITMAP, out);
bitmap_size += 2;
/* Write new total bitmap size */
@@ -297,14 +297,14 @@ static int _gdImageBmpCtx(gdImagePtr im, gdIOCtxPtr out, int compression)
for (xpos = 0; xpos < im->sx; xpos++) {
pixel = gdImageGetPixel(im, xpos, row);
- Putchar(gdTrueColorGetBlue(pixel), out);
- Putchar(gdTrueColorGetGreen(pixel), out);
- Putchar(gdTrueColorGetRed(pixel), out);
+ gdPutC(gdTrueColorGetBlue(pixel), out);
+ gdPutC(gdTrueColorGetGreen(pixel), out);
+ gdPutC(gdTrueColorGetRed(pixel), out);
}
/* Add padding to make sure we have n mod 4 == 0 bytes per row */
for (xpos = padding; xpos > 0; --xpos) {
- Putchar('\0', out);
+ gdPutC('\0', out);
}
}
}