fix vips_resize() bug
if hscale and vscale were very different, resize could fail with "reduce factor too large" ... just a silly typo
This commit is contained in:
parent
2b52f87c24
commit
d7da3c7de7
@ -38,6 +38,7 @@
|
||||
vips_relational_const() have changed argument order to match
|
||||
Python/CLI/C++ ... sorry
|
||||
- added vips_rot90() etc. convenience functions
|
||||
- fix vips_resize() bug when hscale and vscale were very different
|
||||
|
||||
8/12/16 started 8.4.5
|
||||
- allow libgsf-1.14.26 to help centos, thanks tdiprima
|
||||
|
4
TODO
4
TODO
@ -17,10 +17,6 @@
|
||||
|
||||
- try moving some more of the CLI tests to py
|
||||
|
||||
- try SEQ_UNBUFFERED on jpg source, get out of order error?
|
||||
|
||||
- could load pdf thumbnails?
|
||||
|
||||
- colour needs to split _build() into preprocess / process / postprocess
|
||||
phases
|
||||
|
||||
|
@ -1622,12 +1622,12 @@ vips_image_set_progress( VipsImage *image, gboolean progress )
|
||||
* vips_image_iskilled:
|
||||
* @image: image to test
|
||||
*
|
||||
* If @image has been killed (see vips_image_kill()), set an error message,
|
||||
* If @image has been killed (see vips_image_set_kill()), set an error message,
|
||||
* clear the #VipsImage.kill flag and return %FALSE. Otherwise return %TRUE.
|
||||
*
|
||||
* Handy for loops which need to run sets of threads which can fail.
|
||||
*
|
||||
* See also: vips_image_kill().
|
||||
* See also: vips_image_set_kill().
|
||||
*
|
||||
* Returns: %FALSE if @image has been killed.
|
||||
*/
|
||||
|
@ -832,6 +832,8 @@ vips_reducev_build( VipsObject *object )
|
||||
if( VIPS_OBJECT_CLASS( vips_reducev_parent_class )->build( object ) )
|
||||
return( -1 );
|
||||
|
||||
g_info( "reducev by factor %g", reducev->vshrink );
|
||||
|
||||
in = resample->in;
|
||||
|
||||
if( reducev->vshrink < 1 ) {
|
||||
|
@ -127,7 +127,7 @@ vips_resize_int_shrink( VipsResize *resize, double scale )
|
||||
|
||||
case VIPS_KERNEL_LANCZOS2:
|
||||
case VIPS_KERNEL_LANCZOS3:
|
||||
return( VIPS_MAX( 1, VIPS_FLOOR( 1.0 / (resize->scale * 2) ) ) );
|
||||
return( VIPS_MAX( 1, VIPS_FLOOR( 1.0 / (scale * 2) ) ) );
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user