|
91 | 91 | * - add IIIF3 layout
|
92 | 92 | * 21/12/21 whalehub
|
93 | 93 | * - remove trailing comma from IIIFv3 folder names
|
| 94 | + * 29/3/22 |
| 95 | + * - always write a properties file |
| 96 | + * - add .szi as a registered suffix |
94 | 97 | */
|
95 | 98 |
|
96 | 99 | /*
|
@@ -2363,8 +2366,7 @@ vips_foreign_save_dz_build( VipsObject *object )
|
2363 | 2366 | g_assert_not_reached();
|
2364 | 2367 | }
|
2365 | 2368 |
|
2366 |
| - if( dz->properties && |
2367 |
| - write_vips_meta( dz ) ) |
| 2369 | + if( write_vips_meta( dz ) ) |
2368 | 2370 | return( -1 );
|
2369 | 2371 |
|
2370 | 2372 | if( dz->container == VIPS_FOREIGN_DZ_CONTAINER_SZI &&
|
@@ -2440,7 +2442,7 @@ static int bandfmt_dz[10] = {
|
2440 | 2442 | UC, C, US, S, UI, I, F, F, D, D
|
2441 | 2443 | };
|
2442 | 2444 |
|
2443 |
| -static const char *dz_suffs[] = { ".dz", NULL }; |
| 2445 | +static const char *dz_suffs[] = { ".dz", ".szi", NULL }; |
2444 | 2446 |
|
2445 | 2447 | static void
|
2446 | 2448 | vips_foreign_save_dz_class_init( VipsForeignSaveDzClass *class )
|
@@ -2527,13 +2529,6 @@ vips_foreign_save_dz_class_init( VipsForeignSaveDzClass *class )
|
2527 | 2529 | G_STRUCT_OFFSET( VipsForeignSaveDz, container ),
|
2528 | 2530 | VIPS_TYPE_FOREIGN_DZ_CONTAINER, VIPS_FOREIGN_DZ_CONTAINER_FS );
|
2529 | 2531 |
|
2530 |
| - VIPS_ARG_BOOL( class, "properties", 16, |
2531 |
| - _( "Properties" ), |
2532 |
| - _( "Write a properties file to the output directory" ), |
2533 |
| - VIPS_ARGUMENT_OPTIONAL_INPUT, |
2534 |
| - G_STRUCT_OFFSET( VipsForeignSaveDz, properties ), |
2535 |
| - FALSE ); |
2536 |
| - |
2537 | 2532 | VIPS_ARG_INT( class, "compression", 17,
|
2538 | 2533 | _( "Compression" ),
|
2539 | 2534 | _( "ZIP deflate compression level" ),
|
@@ -2593,6 +2588,13 @@ vips_foreign_save_dz_class_init( VipsForeignSaveDzClass *class )
|
2593 | 2588 | G_STRUCT_OFFSET( VipsForeignSaveDz, tile_size ),
|
2594 | 2589 | 1, 8192, 254 );
|
2595 | 2590 |
|
| 2591 | + VIPS_ARG_BOOL( class, "properties", 16, |
| 2592 | + _( "Properties" ), |
| 2593 | + _( "Write a properties file to the output directory" ), |
| 2594 | + VIPS_ARGUMENT_OPTIONAL_INPUT | VIPS_ARGUMENT_DEPRECATED, |
| 2595 | + G_STRUCT_OFFSET( VipsForeignSaveDz, properties ), |
| 2596 | + FALSE ); |
| 2597 | + |
2596 | 2598 | }
|
2597 | 2599 |
|
2598 | 2600 | static void
|
@@ -2806,7 +2808,6 @@ vips_foreign_save_dz_buffer_init( VipsForeignSaveDzBuffer *buffer )
|
2806 | 2808 | * * @centre: %gboolean centre the tiles
|
2807 | 2809 | * * @angle: #VipsAngle rotate the image by this much
|
2808 | 2810 | * * @container: #VipsForeignDzContainer set container type
|
2809 |
| - * * @properties: %gboolean write a properties file |
2810 | 2811 | * * @compression: %gint zip deflate compression level
|
2811 | 2812 | * * @region_shrink: #VipsRegionShrink how to shrink each 2x2 region
|
2812 | 2813 | * * @skip_blanks: %gint skip tiles which are nearly equal to the background
|
@@ -2845,12 +2846,6 @@ vips_foreign_save_dz_buffer_init( VipsForeignSaveDzBuffer *buffer )
|
2845 | 2846 | * yourself with vips_rot(). Note that the `autorotate` option to the loader
|
2846 | 2847 | * may do what you need.
|
2847 | 2848 | *
|
2848 |
| - * If @properties is %TRUE, vips_dzsave() will write a file called |
2849 |
| - * `vips-properties.xml` to the output directory. This file lists all of the |
2850 |
| - * metadata attached to @in in an obvious manner. It can be useful for viewing |
2851 |
| - * programs which wish to use fields from source files loaded via |
2852 |
| - * vips_openslideload(). |
2853 |
| - * |
2854 | 2849 | * By default, all tiles are stripped since usually you do not want a copy of
|
2855 | 2850 | * all metadata in every tile. Set @no_strip if you want to keep metadata.
|
2856 | 2851 | *
|
@@ -2908,7 +2903,6 @@ vips_dzsave( VipsImage *in, const char *name, ... )
|
2908 | 2903 | * * @centre: %gboolean centre the tiles
|
2909 | 2904 | * * @angle: #VipsAngle rotate the image by this much
|
2910 | 2905 | * * @container: #VipsForeignDzContainer set container type
|
2911 |
| - * * @properties: %gboolean write a properties file |
2912 | 2906 | * * @compression: %gint zip deflate compression level
|
2913 | 2907 | * * @region_shrink: #VipsRegionShrink how to shrink each 2x2 region.
|
2914 | 2908 | * * @skip_blanks: %gint skip tiles which are nearly equal to the background
|
|
0 commit comments