Update of /cvsroot/ufraw/ufraw In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv6468
Modified Files: Makefile.am README configure.ac ufraw-gimp.c ufraw.h ufraw_preview.c Log Message: Bump version to 0.20. Remove Cinepaint plug-in. Index: Makefile.am =================================================================== RCS file: /cvsroot/ufraw/ufraw/Makefile.am,v retrieving revision 1.60 retrieving revision 1.61 diff -u -d -r1.60 -r1.61 --- Makefile.am 14 Mar 2013 09:00:16 -0000 1.60 +++ Makefile.am 26 Mar 2013 16:30:12 -0000 1.61 @@ -18,11 +18,6 @@ gimpbindir = $(GIMP_LIBDIR)/plug-ins endif -if MAKE_CINEPAINT - cinepaintbin_PROGRAMS = ufraw-cinepaint - cinepaintbindir = $(CINEPAINT_PROGRAMPLUGINDIR)/plug-ins -endif - POD2MAN = @POD2MAN@ man_MANS = ufraw.1 @@ -96,13 +91,6 @@ ufraw_gimp_LDADD = $(LDADD) $(GIMP_LIBS) $(GTK_LIBS) endif -if MAKE_CINEPAINT - ufraw_cinepaint_SOURCES = ufraw-gimp.c - ufraw_cinepaint_CPPFLAGS = $(AM_CPPFLAGS) $(CINEPAINT_CFLAGS) \ - -DUFRAW_CINEPAINT - ufraw_cinepaint_LDADD = $(LDADD) $(CINEPAINT_LIBS) $(GTK_LIBS) -endif - if MAKE_EXTRAS dcraw_SOURCES = dcraw.cc dcraw_CPPFLAGS = $(UFRAW_CPPFLAGS) Index: configure.ac =================================================================== RCS file: /cvsroot/ufraw/ufraw/configure.ac,v retrieving revision 1.175 retrieving revision 1.176 diff -u -d -r1.175 -r1.176 --- configure.ac 23 Mar 2013 14:15:11 -0000 1.175 +++ configure.ac 26 Mar 2013 16:30:12 -0000 1.176 @@ -1,5 +1,5 @@ dnl $Id$ -AC_INIT(UFRaw, 0.19.2) +AC_INIT(UFRaw, 0.20) AC_PREREQ(2.57) # Create host_os, host_cpu, host_alias variables. @@ -87,14 +87,13 @@ ] ) ] ) have_gimp=no -have_cinepaint=no if test "$have_gtk" = "yes"; then PKG_CHECK_MODULES(GTK, gtkimageview >= 1.6) -# It is not clear if we should install the GIMP and Cinepaint plugins -# in the corresponding place in our prefix, or in GIMP's or -# Cinepaint's lib dir in their prefixes. Currently, we install the -# plugin in our prefix. If the gimp/cinepaint prefix and the +# It is not clear if we should install the GIMP plugin +# in the corresponding place in our prefix, or in GIMP's +# lib dir in its prefix. Currently, we install the +# plugin in our prefix. If the GIMP prefix and the # configured UFRaw prefix are the same, this doesn't matter. pkg_prefix="$PKG_CONFIG" test $prefix = NONE || pkg_prefix="$pkg_prefix --define-variable=prefix=$prefix" @@ -126,26 +125,6 @@ [ AC_DEFINE_UNQUOTED(HAVE_GIMP_2_9, 0, have Gimp 2.9 or later) ]) fi - AC_ARG_WITH([cinepaint], - [AS_HELP_STRING([--with-cinepaint], - [build cinepaint plugin @<:@default=check@:>@])], - [], - [with_cinepaint=check]) - - AS_IF([test "x$with_cinepaint" != xno], - [PKG_CHECK_MODULES(CINEPAINT, cinepaint-gtk >= 0.22, - [ have_cinepaint=yes - CINEPAINT_LIBDIR=`$pkg_prefix --variable=libdir cinepaint-gtk` - CINEPAINT_PROGRAMPLUGINDIR=`$pkg_prefix --variable=programplugindir cinepaint-gtk` ], - [ have_cinepaint=no - CINEPAINT_LIBDIR= - CINEPAINT_PROGRAMPLUGINDIR= - if test "x$with_cinepaint" != xcheck; then - AC_MSG_FAILURE( - [--with-cinepaint was given, but test for cinepaint failed]) - fi - ] ) ] ) - # Disable deprecated functions on tested versions of GTK. if $PKG_CONFIG --max-version=2.18.99 gtk+-2.0; then AC_DEFINE(G_DISABLE_DEPRECATED, [], disable deprecated glib features) @@ -163,11 +142,6 @@ AC_SUBST(GIMP_LIBS) AC_SUBST(GIMP_LIBDIR) -AM_CONDITIONAL(MAKE_CINEPAINT, test $have_cinepaint = yes) -AC_SUBST(CINEPAINT_CFLAGS) -AC_SUBST(CINEPAINT_LIBS) -AC_SUBST(CINEPAINT_PROGRAMPLUGINDIR) - # Check for zlib. AC_CHECK_LIB(z, deflate) have_zlib=${ac_cv_lib_z_deflate:-no} @@ -391,7 +365,6 @@ AC_MSG_NOTICE(====================== summary =====================) AC_MSG_NOTICE(build GTK GUI: $have_gtk) AC_MSG_NOTICE(build GIMP plug-in: $have_gimp) -AC_MSG_NOTICE(build CinePaint plug-in: $have_cinepaint) AC_MSG_NOTICE(EXIF support using exiv2: $have_exiv2) AC_MSG_NOTICE(JPEG support: $have_jpeg) AC_MSG_NOTICE(JPEG2000 (libjasper) support: $have_jasper) Index: README =================================================================== RCS file: /cvsroot/ufraw/ufraw/README,v retrieving revision 1.67 retrieving revision 1.68 diff -u -d -r1.67 -r1.68 --- README 25 Mar 2013 05:50:44 -0000 1.67 +++ README 26 Mar 2013 16:30:12 -0000 1.68 @@ -4,7 +4,7 @@ by Udi Fuchs UFRaw is a utility to read and manipulate raw images from digital cameras. -It can be used by itself or as a GIMP or CinePaint plug-in. +It can be used by itself or as a GIMP plug-in. It reads raw images using Dave Coffin's raw conversion utility DCRaw. It supports basic color management using Little CMS, allowing the user to apply color profiles. @@ -54,7 +54,6 @@ configure: ====================== summary ===================== configure: build GTK GUI: yes configure: build GIMP plug-in: yes -configure: build CinePaint plug-in: yes configure: EXIF support using exiv2: yes configure: JPEG support: yes configure: JPEG2000 (libjasper) support: yes @@ -74,9 +73,6 @@ Development packages for GIMP version 2.2 or higher is required to build the GIMP plug-in. -Development packages for Cinepaint-gtk version 0.22 or higher is required to -build the Cinepaint plug-in. - The development package for exiv2 version 0.20 or higher is required for reading the EXIF data. Among the supported formats are Canon (CRW, CR2), Fuji (RAF), Minolta (MRW), Nikon (NEF), Pentax (PEF), Samsung (PEF), @@ -141,10 +137,10 @@ To make a system wide installation: make install -Note that the GIMP and Cinepaint plugins, if built, will be installed -into UFRaw's prefix. Thus, if UFRaw's prefix is different from GIMP's -and Cinepaint's prefix, you may have to add plugin directories to the -search path, add symbolic links, or something similar. +Note that the GIMP plugin, if built, will be installed into UFRaw's prefix. +Thus, if UFRaw's prefix is different from GIMP's prefix, you may have to add +the plugin directory to the search path, add a symbolic link, or something +similar. To use the UFRaw GIMP plugin, ensure that other raw converters (e.g. rawphoto) are not installed because they may claim the raw file Index: ufraw_preview.c =================================================================== RCS file: /cvsroot/ufraw/ufraw/ufraw_preview.c,v retrieving revision 1.365 retrieving revision 1.366 diff -u -d -r1.365 -r1.366 --- ufraw_preview.c 24 Mar 2013 07:30:28 -0000 1.365 +++ ufraw_preview.c 26 Mar 2013 16:30:12 -0000 1.366 @@ -4831,7 +4831,9 @@ gtk_table_attach(table, label, 0, 4, 7, 8, 0, 0, 0, 0); data->BitDepthCombo = GTK_COMBO_BOX(uf_combo_box_new_text()); uf_combo_box_append_text(data->BitDepthCombo, "8", (void*)8); - if (plugin != 1) +#if !HAVE_GIMP_2_9 + if (plugin != ufraw_gimp_plugin) +#endif uf_combo_box_append_text(data->BitDepthCombo, "16", (void*)16); uf_combo_box_set_data(GTK_COMBO_BOX(data->BitDepthCombo), &CFG->profile[out_profile][CFG->profileIndex[out_profile]].BitDepth); @@ -5223,7 +5225,7 @@ gtk_box_pack_start(GTK_BOX(hBox), chooser, TRUE, TRUE, 0); g_signal_connect(G_OBJECT(chooser), "selection-changed", G_CALLBACK(outpath_chooser_changed), NULL); - if (plugin == 3) + if (plugin == ufraw_standalone_output) gtk_widget_set_sensitive(chooser, FALSE); hBox = gtk_hbox_new(FALSE, 0); @@ -5240,7 +5242,7 @@ TRUE, TRUE, 0); g_signal_connect(G_OBJECT(data->OutFileEntry), "changed", G_CALLBACK(outfile_entry_changed), NULL); - if (plugin == 3) + if (plugin == ufraw_standalone_output) gtk_widget_set_sensitive(GTK_WIDGET(data->OutFileEntry), FALSE); data->TypeCombo = GTK_COMBO_BOX(gtk_combo_box_new_text()); i = 0; @@ -5270,7 +5272,7 @@ FALSE, FALSE, 0); g_signal_connect(G_OBJECT(data->TypeCombo), "changed", G_CALLBACK(type_combo_changed), &CFG->type); - if (plugin == 3) + if (plugin == ufraw_standalone_output) gtk_widget_set_sensitive(GTK_WIDGET(data->TypeCombo), FALSE); gtk_box_pack_start(GTK_BOX(vBox), gtk_hseparator_new(), @@ -5605,7 +5607,7 @@ data->PageNumCrop = gtk_notebook_page_num(notebook, page); transformations_fill_interface(data, page); - if (plugin == 0 || plugin == 3) { + if (plugin != ufraw_gimp_plugin) { page = notebook_page_new(notebook, _("Save"), GTK_STOCK_SAVE_AS); save_fill_interface(data, page, plugin); } @@ -5740,11 +5742,7 @@ G_CALLBACK(control_button_event), (gpointer)cancel_button); gtk_box_pack_start(box, button, FALSE, FALSE, 0); - /* plugin=0 : Normal stand-alone - * plugin=1 : Gimp plug-in - * plugin=2 : Cinepaint plug-in - * plugin=3 : Stand-alone with --output option */ - if (plugin == 1 || plugin == 2) { + if (plugin == ufraw_gimp_plugin) { // OK button for the plug-in data->SaveButton = gtk_button_new_from_stock(GTK_STOCK_OK); gtk_box_pack_start(box, data->SaveButton, FALSE, FALSE, 0); @@ -5759,7 +5757,7 @@ G_CALLBACK(control_button_event), (gpointer)save_button); set_save_tooltip(data); } - if (plugin == 0) { + if (plugin == ufraw_standalone) { // Send to Gimp button GtkWidget *gimpButton = control_button("gimp", _("Send image to _Gimp"), gimp_button, data); Index: ufraw-gimp.c =================================================================== RCS file: /cvsroot/ufraw/ufraw/ufraw-gimp.c,v retrieving revision 1.75 retrieving revision 1.76 diff -u -d -r1.75 -r1.76 --- ufraw-gimp.c 10 Mar 2013 17:15:11 -0000 1.75 +++ ufraw-gimp.c 26 Mar 2013 16:30:12 -0000 1.76 @@ -17,41 +17,19 @@ #include "ufraw.h" #include "uf_gtk.h" -#ifdef UFRAW_CINEPAINT -/* Bypass a bug in CinePaint header files */ -#define RNH_FLOAT -#include <plugin_main.h> -#define GIMP_CONST -/* Fix some compatibility issues between CinePaint and GIMP */ -typedef GimpRunModeType GimpRunMode; -#define PLUGIN_MODE 2 -#define DEPTH_TO_BASETYPE(depth) (depth == 3 ? RGB : U16_RGB) -#define DEPTH_TO_IMAGETYPE(depth) (depth == 3 ? RGB_IMAGE : U16_RGB_IMAGE) -#else /* GIMP */ #if HAVE_GIMP_2_9 #include <gegl.h> -#define PLUGIN_MODE 2 -#else -#define PLUGIN_MODE 1 #endif #include <libgimpbase/gimpbase.h> #include <libgimp/gimp.h> #include <libgimp/gimpui.h> -#define GIMP_CONST const -/* Missing and irrelevant definitions in GIMP */ -#define U16_RGB 0 -#define U16_RGB_IMAGE 0 -#define DEPTH_TO_BASETYPE(depth) GIMP_RGB -#define DEPTH_TO_IMAGETYPE(depth) GIMP_RGB_IMAGE -#define DEPTH_TO_PRECISION(depth) (depth == 3 ? GIMP_PRECISION_U8 : GIMP_PRECISION_U16) -#endif #include <glib/gi18n.h> #include <string.h> void query(); -void run(GIMP_CONST gchar *name, +void run(const gchar *name, gint nparams, - GIMP_CONST GimpParam *param, + const GimpParam *param, gint *nreturn_vals, GimpParam **return_vals); @@ -68,25 +46,23 @@ void query() { - static GIMP_CONST GimpParamDef load_args[] = { + static const GimpParamDef load_args[] = { { GIMP_PDB_INT32, "run_mode", "Interactive, non-interactive" }, { GIMP_PDB_STRING, "filename", "The name of the file to load" }, { GIMP_PDB_STRING, "raw_filename", "The name of the file to load" }, }; - static GIMP_CONST GimpParamDef load_return_vals[] = { + static const GimpParamDef load_return_vals[] = { { GIMP_PDB_IMAGE, "image", "Output image" }, }; -#ifndef UFRAW_CINEPAINT - static GIMP_CONST GimpParamDef thumb_args[] = { + static const GimpParamDef thumb_args[] = { { GIMP_PDB_STRING, "filename", "The name of the file to load" }, { GIMP_PDB_INT32, "thumb_size", "Preferred thumbnail size" } }; - static GIMP_CONST GimpParamDef thumb_return_vals[] = { + static const GimpParamDef thumb_return_vals[] = { { GIMP_PDB_IMAGE, "image", "Thumbnail image" }, { GIMP_PDB_INT32, "image_width", "Width of full-sized image" }, { GIMP_PDB_INT32, "image_height", "Height of full-sized image" } }; -#endif gimp_install_procedure("file_ufraw_load", "Loads digital camera raw files", "Loads digital camera raw files.", @@ -95,11 +71,7 @@ "Copyright 2004 by Pawel Jochym\n" "Copyright 2004-2013 by Udi Fuchs", "ufraw-" VERSION, -#ifndef UFRAW_CINEPAINT "raw image", -#else - "<Load>/UFRaw", -#endif NULL, GIMP_PLUGIN, G_N_ELEMENTS(load_args), @@ -109,7 +81,6 @@ gimp_register_load_handler("file_ufraw_load", (char *)raw_ext, ""); -#ifndef UFRAW_CINEPAINT gimp_install_procedure("file_ufraw_load_thumb", "Loads thumbnails from digital camera raw files.", "Loads thumbnails from digital camera raw files.", @@ -125,25 +96,14 @@ gimp_register_thumbnail_loader("file_ufraw_load", "file_ufraw_load_thumb"); -#endif } char *ufraw_binary; - -#ifdef UFRAW_CINEPAINT -/* There is no way to get the full executable path in Cinepaint. - * It is only needed for windows, so no big deal. */ -char *gimp_get_progname() -{ - return "ufraw-cinepaint"; -} -#endif - gboolean sendToGimpMode; -void run(GIMP_CONST gchar *name, +void run(const gchar *name, gint nparams, - GIMP_CONST GimpParam *param, + const GimpParam *param, gint *nreturn_vals, GimpParam **return_vals) { @@ -254,7 +214,7 @@ ufraw_config(uf, &rc, NULL, NULL); sendToGimpMode = (uf->conf->createID == send_id); -#if !defined(UFRAW_CINEPAINT) && !HAVE_GIMP_2_9 +#if !HAVE_GIMP_2_9 if (loadThumbnail) { uf->conf->size = size; uf->conf->embeddedImage = TRUE; @@ -271,7 +231,7 @@ !loadThumbnail && !sendToGimpMode) { /* Show the preview in interactive mode, unless if we are * in thumbnail mode or 'send to gimp' mode. */ - status = ufraw_preview(uf, &rc, PLUGIN_MODE, ufraw_save_gimp_image); + status = ufraw_preview(uf, &rc, ufraw_gimp_plugin, ufraw_save_gimp_image); } else { if (sendToGimpMode) { char *text = g_strdup_printf(_("Loading raw file '%s'"), @@ -369,7 +329,7 @@ if (ufraw_convert_image(uf) != UFRAW_SUCCESS) return UFRAW_ERROR; ufraw_get_scaled_crop(uf, &Crop); -#if defined(UFRAW_CINEPAINT) || HAVE_GIMP_2_9 +#if HAVE_GIMP_2_9 if (uf->conf->profile[out_profile] [uf->conf->profileIndex[out_profile]].BitDepth == 16) depth = 6; @@ -381,12 +341,11 @@ } #if HAVE_GIMP_2_9 uf->gimpImage = - gimp_image_new_with_precision(Crop.width, Crop.height, - DEPTH_TO_BASETYPE(depth), - DEPTH_TO_PRECISION(depth)); + gimp_image_new_with_precision(Crop.width, Crop.height, GIMP_RGB, + depth == 3 ? GIMP_PRECISION_U8 : + GIMP_PRECISION_U16); #else - uf->gimpImage = gimp_image_new(Crop.width, Crop.height, - DEPTH_TO_BASETYPE(depth)); + uf->gimpImage = gimp_image_new(Crop.width, Crop.height, GIMP_RGB); #endif if (uf->gimpImage == -1) { ufraw_message(UFRAW_ERROR, _("Can't allocate new image.")); @@ -396,17 +355,13 @@ /* Create the "background" layer to hold the image... */ layer = gimp_layer_new(uf->gimpImage, _("Background"), Crop.width, - Crop.height, DEPTH_TO_IMAGETYPE(depth), - 100.0, GIMP_NORMAL_MODE); -#ifdef UFRAW_CINEPAINT - gimp_image_add_layer(uf->gimpImage, layer, 0); -#else + Crop.height, GIMP_RGB_IMAGE, 100.0, + GIMP_NORMAL_MODE); #if defined(GIMP_CHECK_VERSION) && GIMP_CHECK_VERSION(2,7,3) gimp_image_insert_layer(uf->gimpImage, layer, 0, 0); #else gimp_image_add_layer(uf->gimpImage, layer, 0); #endif -#endif /* Get the drawable and set the pixel region for our load... */ #if HAVE_GIMP_2_9 @@ -449,27 +404,6 @@ if (uf->conf->embeddedImage) return UFRAW_SUCCESS; -#ifdef UFRAW_CINEPAINT - /* No parasites in CinePaint. - * We need to disable EXIF export. - * ICC profile export works differently. */ - if (strcmp(uf->developer->profileFile[out_profile], "") == 0) { - gimp_image_set_srgb_profile(uf->gimpImage); - } else { - char *buf; - gsize len; - if (g_file_get_contents(uf->developer->profileFile[out_profile], - &buf, &len, NULL)) { - gimp_image_set_icc_profile_by_mem(uf->gimpImage, len, buf, - ICC_IMAGE_PROFILE); - g_free(buf); - } else { - ufraw_message(UFRAW_WARNING, - _("Failed to embed output profile '%s' in image."), - uf->developer->profileFile[out_profile]); - } - } -#else ufraw_exif_prepare_output(uf); if (uf->outputExifBuf != NULL) { if (uf->outputExifBufLen > 65533) { @@ -503,7 +437,6 @@ uf->developer->profileFile[out_profile]); } } -#endif return UFRAW_SUCCESS; } Index: ufraw.h =================================================================== RCS file: /cvsroot/ufraw/ufraw/ufraw.h,v retrieving revision 1.168 retrieving revision 1.169 diff -u -d -r1.168 -r1.169 --- ufraw.h 3 Feb 2013 11:30:23 -0000 1.168 +++ ufraw.h 26 Mar 2013 16:30:12 -0000 1.169 @@ -123,6 +123,13 @@ restore_types }; enum { digital_highlights, film_highlights, highlights_types }; + +/* ufraw_standalone : Normal stand-alone + * ufraw_gimp_plugin : Gimp plug-in + * ufraw_standalone_output : Stand-alone with --output option + */ +enum { ufraw_standalone, ufraw_gimp_plugin, ufraw_standalone_output }; + typedef enum { display_developer, file_developer, auto_developer } DeveloperMode; typedef enum { perceptual_intent, relative_intent, saturation_intent, ------------------------------------------------------------------------------ Own the Future-Intel® Level Up Game Demo Contest 2013 Rise to greatness in Intel's independent game demo contest. Compete for recognition, cash, and the chance to get your game on Steam. $5K grand prize plus 10 genre and skill prizes. Submit your demo by 6/6/13. http://p.sf.net/sfu/intel_levelupd2d _______________________________________________ ufraw-cvs mailing list ufraw-cvs@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/ufraw-cvs