summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
31861ae)
Some older library implementations don't support %zu conversions.
Since the use in lbximg is entirely pointless, this is just
gratuitious incompatibility.
struct lbx_colour *palette)
{
bool masked = img_is_masked(mask, width, height);
struct lbx_colour *palette)
{
bool masked = img_is_masked(mask, width, height);
- unsigned x, y;
- size_t depth;
if (fprintf_ascii(f, "P7\nWIDTH %u\nHEIGHT %u\n", width, height) < 0)
goto err;
if (fprintf_ascii(f, "P7\nWIDTH %u\nHEIGHT %u\n", width, height) < 0)
goto err;
if (palette) {
depth = masked ? 4 : 3;
if (palette) {
depth = masked ? 4 : 3;
- if (fprintf_ascii(f, "DEPTH %zu\nMAXVAL 63\n"
+ if (fprintf_ascii(f, "DEPTH %u\nMAXVAL 63\n"
"TUPLTYPE RGB%s\nENDHDR\n",
depth, masked ? "_ALPHA" : "") < 0)
goto err;
"TUPLTYPE RGB%s\nENDHDR\n",
depth, masked ? "_ALPHA" : "") < 0)
goto err;
} else {
depth = masked ? 2 : 1;
} else {
depth = masked ? 2 : 1;
- if (fprintf_ascii(f, "DEPTH %zu\nMAXVAL 255\n"
+ if (fprintf_ascii(f, "DEPTH %u\nMAXVAL 255\n"
"TUPLTYPE GRAYSCALE%s\nENDHDR\n",
depth, masked ? "_ALPHA" : "") < 0)
goto err;
"TUPLTYPE GRAYSCALE%s\nENDHDR\n",
depth, masked ? "_ALPHA" : "") < 0)
goto err;