diff --git a/ChangeLog b/ChangeLog index 2d5bfec3..4f5ee6a6 100644 --- a/ChangeLog +++ b/ChangeLog @@ -22,6 +22,8 @@ - include sys/param.h to get PATH_MAX in more places - VIPS_INTERPOLATE_SHIFT bumped to 12, we need the extra precision for u16 gel data +- added vips_format_get_flags() +- oop, forgot to check for cancel during tiled tiff write 11/9/08 started 7.16.3 - oop typo in manpage for im_project() diff --git a/TODO b/TODO index 2669ce38..edec7a98 100644 --- a/TODO +++ b/TODO @@ -1,6 +1,4 @@ -- tiled tiff save won't cancel -- tiled tiff im_open() seems to decompress to ram? fix before benchmarking - add params diff --git a/include/vips/format.h b/include/vips/format.h index 95e7e4d0..a376d0b3 100644 --- a/include/vips/format.h +++ b/include/vips/format.h @@ -110,6 +110,8 @@ void *vips_format_map( VSListMap2Fn fn, void *a, void *b ); VipsFormatClass *vips_format_for_file( const char *filename ); VipsFormatClass *vips_format_for_name( const char *filename ); +VipsFormatFlags vips_format_get_flags( VipsFormatClass *format ); + /* Read/write an image convenience functions. */ int vips_format_read( const char *name, IMAGE *out ); diff --git a/libsrc/format/format.c b/libsrc/format/format.c index 5941ec3a..af85b5bb 100644 --- a/libsrc/format/format.c +++ b/libsrc/format/format.c @@ -125,6 +125,12 @@ vips_format_init( VipsFormat *object ) { } +VipsFormatFlags +vips_format_get_flags( VipsFormatClass *format ) +{ + return( format->get_flags ? format->get_flags( filename ) : 0 ); +} + /* VIPS format class. */ diff --git a/libsrc/format/im_vips2tiff.c b/libsrc/format/im_vips2tiff.c index 7e105606..d6c3e3e6 100644 --- a/libsrc/format/im_vips2tiff.c +++ b/libsrc/format/im_vips2tiff.c @@ -1061,13 +1061,11 @@ write_tif_tile( TiffWrite *tw ) if( tw->layer && new_tile( tw->layer, tw->reg, &area ) ) return( -1 ); - /* Trigger any eval callbacks on our source image. + /* Trigger any eval callbacks on our source image and + * check for errors. */ - im__handle_eval( im, area.width, area.height ); - - /* Check for errors. - */ - if( im_threadgroup_iserror( tw->tg ) ) + if( im__handle_eval( im, area.width, area.height ) || + im_threadgroup_iserror( tw->tg ) ) return( -1 ); }