Update of /cvsroot/ufraw/ufraw
In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv7775

Modified Files:
        ufraw_ufraw.c 
Log Message:
Move TCA to the end of the raw phase, where it belongs.


Index: ufraw_ufraw.c
===================================================================
RCS file: /cvsroot/ufraw/ufraw/ufraw_ufraw.c,v
retrieving revision 1.231
retrieving revision 1.232
diff -u -d -r1.231 -r1.232
--- ufraw_ufraw.c       27 Jan 2010 21:23:22 -0000      1.231
+++ ufraw_ufraw.c       29 Jan 2010 01:43:20 -0000      1.232
@@ -37,6 +37,8 @@
        LF_MODIFY_DISTORTION | LF_MODIFY_GEOMETRY | LF_MODIFY_SCALE)
 static void ufraw_convert_image_vignetting(ufraw_data *uf,
        ufraw_image_data *img, UFRectangle *area);
+static void ufraw_convert_image_tca(ufraw_data *uf, ufraw_image_data *img,
+       ufraw_image_data *outimg, UFRectangle *area);
 static void ufraw_prepare_tca(ufraw_data *uf);
 #endif
 static void ufraw_image_format(int *colors, int *bytes, ufraw_image_data *img,
@@ -1211,6 +1213,16 @@
     dcraw_finalize_raw(raw, dark, uf->developer->rgbWB);
     raw->raw.image = rawimage;
     ufraw_despeckle(uf, phase);
+#ifdef HAVE_LENSFUN
+    ufraw_prepare_tca(uf);
+    if (uf->TCAmodifier != NULL) {
+       ufraw_image_data inImg = *img;
+       img->buffer = g_malloc(img->height * img->rowstride);
+       UFRectangle area = {0, 0, img->width, img->height };
+       ufraw_convert_image_tca(uf, &inImg, img, &area);
+       g_free(inImg.buffer);
+    }
+#endif
 }
 
 /*
@@ -1378,17 +1390,6 @@
     img->width = dcimg->width;
     img->depth = sizeof (dcraw_image_type);
     img->rowstride = img->width * img->depth;
-#ifdef HAVE_LENSFUN
-    ufraw_prepare_tca(uf);
-    if (uf->TCAmodifier != NULL) {
-       ufraw_image_data inImg = *img;
-       inImg.buffer = (guint8 *)dcimg->image;
-       img->buffer = g_realloc(img->buffer, img->height * img->rowstride);
-       UFRectangle area = {0, 0, img->width, img->height };
-       ufraw_convert_image_tca(uf, &inImg, img, &area);
-       return;
-    }
-#endif
     g_free(img->buffer);
     img->buffer = g_memdup(dcimg->image, img->height * img->rowstride);
 }


------------------------------------------------------------------------------
The Planet: dedicated and managed hosting, cloud storage, colocation
Stay online with enterprise data centers and the best network in the business
Choose flexible plans and management services without long-term contracts
Personal 24x7 support from experience hosting pros just a phone call away.
http://p.sf.net/sfu/theplanet-com
_______________________________________________
ufraw-cvs mailing list
ufraw-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ufraw-cvs

Reply via email to