Skip to content

Commit

Permalink
fix .dzi format string
Browse files Browse the repository at this point in the history
dzsave left the save options attached to the Format string in the .dzi
file

also, version bump
  • Loading branch information
jcupitt committed Oct 2, 2012
1 parent 0e5e34e commit 4050c47
Show file tree
Hide file tree
Showing 4 changed files with 132 additions and 117 deletions.
3 changes: 3 additions & 0 deletions ChangeLog
@@ -1,3 +1,6 @@
2/10/12 started 7.30.4
- remove options from format string in .dzi (thanks Martin)

13/9/12 started 7.30.3
- linecache sized itself too large
- fix a compile failure if libtiff was not found (thanks Martin)
Expand Down
8 changes: 4 additions & 4 deletions configure.in
Expand Up @@ -2,7 +2,7 @@

# also update the version number in the m4 macros below

AC_INIT([vips], [7.30.3], [vipsip@jiscmail.ac.uk])
AC_INIT([vips], [7.30.4], [vipsip@jiscmail.ac.uk])
# required for gobject-introspection
AC_PREREQ(2.62)

Expand All @@ -17,7 +17,7 @@ AC_CONFIG_MACRO_DIR([m4])
# user-visible library versioning
m4_define([vips_major_version], [7])
m4_define([vips_minor_version], [30])
m4_define([vips_micro_version], [3])
m4_define([vips_micro_version], [4])
m4_define([vips_version],
[vips_major_version.vips_minor_version.vips_micro_version])

Expand All @@ -37,8 +37,8 @@ VIPS_VERSION_STRING=$VIPS_VERSION-`date`
# binary interface changes not backwards compatible?: reset age to 0

LIBRARY_CURRENT=33
LIBRARY_REVISION=6
LIBRARY_AGE=2
LIBRARY_REVISION=7
LIBRARY_AGE=3

# patched into include/vips/version.h
AC_SUBST(VIPS_VERSION)
Expand Down
9 changes: 8 additions & 1 deletion libvips/foreign/dzsave.c
Expand Up @@ -20,6 +20,8 @@
* 1/10/12
* - did not write low pyramid layers for images with an odd number of
* scan lines (thanks Martin)
* 2/10/12
* - remove filename options from format string in .dzi (thanks Martin)
*/

/*
Expand Down Expand Up @@ -257,15 +259,20 @@ write_dzi( VipsForeignSaveDz *dz )
{
FILE *fp;
char buf[PATH_MAX];
char *p;

vips_snprintf( buf, PATH_MAX, "%s.dzi", dz->basename );
if( !(fp = vips__file_open_write( buf, TRUE )) )
return( -1 );

vips_snprintf( buf, PATH_MAX, "%s", dz->suffix + 1 );
if( (p = vips__find_rightmost_brackets( buf )) )
*p = '\0';

fprintf( fp, "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n" );
fprintf( fp, "<Image "
"xmlns=\"http://schemas.microsoft.com/deepzoom/2008\"\n" );
fprintf( fp, " Format=\"%s\"\n", dz->suffix + 1 );
fprintf( fp, " Format=\"%s\"\n", buf );
fprintf( fp, " Overlap=\"%d\"\n", dz->overlap );
fprintf( fp, " TileSize=\"%d\"\n", dz->tile_size );
fprintf( fp, " >\n" );
Expand Down

0 comments on commit 4050c47

Please sign in to comment.