-
-
Notifications
You must be signed in to change notification settings - Fork 729
Open
Labels
Description
Using released libvips v8.18.0, https://github.com/libvips/libvips/releases/tag/v8.18.0
at least vips_thumbnail (just tried this) produces meaningless image on s390x.
Note that s390x is big endian.
C source:
$ cat resize-to-limit-2.c
#include <stdlib.h>
#include <sys/stat.h>
#define MY_ASSERT(expr) \
do { \
if (!(expr)) { \
fprintf(stderr, "LINE[%d] : assertion \"" #expr "\" failed.\n", __LINE__); \
abort(); \
} \
} while(0)
int main(void) {
VipsImage *normal_image;
int ret;
const char *input_path = "./portrait.jpg";
ret = vips_thumbnail(
input_path, &normal_image,
400,
"height", 400,
"size", VIPS_SIZE_DOWN,
NULL
);
MY_ASSERT(!ret);
vips_image_write_to_file(normal_image, "resized.jpg", NULL);
}