[Rawstudio-commit] r2023 - trunk/src
Anders Brander
anders at brander.dk
Mon Sep 22 08:25:22 CEST 2008
Author: abrander
Date: 2008-09-22 08:25:22 +0200 (Mon, 22 Sep 2008)
New Revision: 2023
Modified:
trunk/src/tiff-meta.c
Log:
Ported Panasonic thumbnail loader to RSFiletype.
Modified: trunk/src/tiff-meta.c
===================================================================
--- trunk/src/tiff-meta.c 2008-09-22 06:02:04 UTC (rev 2022)
+++ trunk/src/tiff-meta.c 2008-09-22 06:25:22 UTC (rev 2023)
@@ -26,7 +26,7 @@
#include "rs-image.h"
#include "rs-color-transform.h"
#include "rs-utils.h"
-#include "rs-photo.h"
+#include "rs-filetypes.h"
#include "rs-metadata.h"
/* It is required having some arbitrary maximum exposure time to prevent borked
@@ -1165,16 +1165,16 @@
/* Special case for Panasonic - most have no embedded thumbnail */
else if (meta->make == MAKE_PANASONIC)
{
- RS_PHOTO *photo;
- if ((photo = rs_photo_load_from_file(filename, TRUE)))
+ RS_IMAGE16 *input;
+ if ((input = rs_filetype_load(filename, TRUE)))
{
gint c;
gfloat pre_mul[4];
RS_IMAGE16 *image;
RSColorTransform *rct = rs_color_transform_new();
- image = rs_image16_transform(photo->input, NULL,
- NULL, NULL, photo->crop, 128, 128, TRUE, -1.0,
- photo->angle, photo->orientation, NULL);
+ image = rs_image16_transform(input, NULL,
+ NULL, NULL, NULL, 128, 128, TRUE, -1.0,
+ 0.0, 0, NULL);
pixbuf = gdk_pixbuf_new(GDK_COLORSPACE_RGB, FALSE, 8, image->w, image->h);
for(c=0;c<4;c++)
@@ -1185,7 +1185,7 @@
image->rowstride, gdk_pixbuf_get_pixels(pixbuf),
gdk_pixbuf_get_rowstride(pixbuf));
- g_object_unref(photo);
+ g_object_unref(input);
g_object_unref(image);
g_object_unref(rct);
}
More information about the Rawstudio-commit
mailing list