Make thumbnailers pass back raw images

This commit is contained in:
2022-02-20 19:43:21 +01:00
parent a28fbf25bc
commit 04ec292caf
6 changed files with 137 additions and 36 deletions

7
fiv.c
View File

@@ -1822,9 +1822,14 @@ main(int argc, char *argv[])
exit_fatal("unknown thumbnail size: %s", thumbnail_size);
GFile *target = g_file_new_for_commandline_arg(path_arg);
if (!fiv_thumbnail_produce(target, size, &error))
cairo_surface_t *surface = NULL;
if (!fiv_thumbnail_produce(target, size, &surface, &error))
exit_fatal("%s", error->message);
g_object_unref(target);
if (surface) {
fiv_io_serialize_to_stdout(surface);
cairo_surface_destroy(surface);
}
return 0;
}