fix im_benchmark()
This commit is contained in:
parent
1da3064e7b
commit
223cb02305
8
TODO
8
TODO
@ -1,9 +1,5 @@
|
||||
- fix im_benchmarkn
|
||||
|
||||
(vips:16785): GLib-GObject-WARNING **: value "0.500000" of type
|
||||
'\''gdouble'\'' is invalid or out of range for property '\''m1'\'' of
|
||||
type '\''gdouble'\''
|
||||
LabQ2sRGB: coding '\''labq'\'' only
|
||||
- some vips8 operators repack labq after processing ... new policy: accept any
|
||||
format and never repack
|
||||
|
||||
|
||||
- seen some leaks from
|
||||
|
@ -1,7 +1,5 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -x
|
||||
|
||||
uname -a
|
||||
gcc --version
|
||||
vips --version
|
||||
|
@ -359,14 +359,14 @@ vips_sharpen_class_init( VipsSharpenClass *class )
|
||||
_( "Slope for flat areas" ),
|
||||
VIPS_ARGUMENT_OPTIONAL_INPUT,
|
||||
G_STRUCT_OFFSET( VipsSharpen, m1 ),
|
||||
1, 1000000, 1 );
|
||||
0, 1000000, 1 );
|
||||
|
||||
VIPS_ARG_DOUBLE( class, "m2", 9,
|
||||
_( "m2" ),
|
||||
_( "Slope for jaggy areas" ),
|
||||
VIPS_ARGUMENT_OPTIONAL_INPUT,
|
||||
G_STRUCT_OFFSET( VipsSharpen, m2 ),
|
||||
1, 1000000, 2 );
|
||||
0, 1000000, 2 );
|
||||
|
||||
}
|
||||
|
||||
|
@ -2335,22 +2335,24 @@ im_sharpen( IMAGE *in, IMAGE *out,
|
||||
double x1, double y2, double y3,
|
||||
double m1, double m2 )
|
||||
{
|
||||
VipsImage *x;
|
||||
VipsImage **t = (VipsImage **)
|
||||
vips_object_local_array( VIPS_OBJECT( out ), 2 );
|
||||
|
||||
if( vips_call( "sharpen", in, &x,
|
||||
/* im_sharpen() always recoded as labq and im_benchmark() depends
|
||||
* upon this behaviour.
|
||||
*/
|
||||
if( vips_call( "sharpen", in, &t[0],
|
||||
"radius", mask_size / 2,
|
||||
"x1", x1,
|
||||
"y2", y2,
|
||||
"y3", y3,
|
||||
"m1", m1,
|
||||
"m2", m2,
|
||||
NULL ) )
|
||||
NULL ) ||
|
||||
vips_colourspace( t[0], &t[1],
|
||||
VIPS_INTERPRETATION_LABQ, NULL ) ||
|
||||
vips_image_write( t[1], out ) )
|
||||
return( -1 );
|
||||
if( im_copy( x, out ) ) {
|
||||
g_object_unref( x );
|
||||
return( -1 );
|
||||
}
|
||||
g_object_unref( x );
|
||||
|
||||
return( 0 );
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user