better tiled tiff tilecache on write

This commit is contained in:
John Cupitt 2014-11-20 13:28:17 +00:00
parent 037f6cd162
commit fcc790f6c0
1 changed files with 5 additions and 4 deletions

View File

@ -1385,15 +1385,16 @@ make_tiff_write( VipsImage *im, const char *filename,
else
tw->tls = VIPS_IMAGE_SIZEOF_PEL( im ) * tw->tilew;
/* If we will be writing tiles, we need to cache tileh pixels of the
/* If we will be writing tiles, we need to cache tileh lines of the
* input, since we say we're sequential.
*/
if( tw->tile ) {
if( vips_tilecache( tw->im, &tw->cache,
"tile_width", tw->im->Xsize,
"tile_height", tw->tileh,
"max_tiles", 1,
NULL ) )
"tile_height", 1,
"max_tiles", 2 * tw->tileh,
"threaded", TRUE,
NULL ) )
return( NULL );
tw->im = tw->cache;