This commit is contained in:
John Cupitt 2009-11-05 13:41:21 +00:00
parent 07d4b0a6f7
commit a19c6cd175
1 changed files with 43 additions and 1 deletions

View File

@ -781,10 +781,51 @@ static im_function resize_linear_desc = {
"resize to X by Y pixels with linear interpolation",
0, /* Flags */
resize_linear_vec, /* Dispatch function */
IM_NUMBER( resize_linear_args ), /* Size of arg list */
IM_NUMBER( resize_linear_args ), /* Size of arg list */
resize_linear_args /* Arg list */
};
/* Args for im_insertplaceset.
*/
static im_arg_desc insertplaceset_args[] = {
IM_INPUT_IMAGE( "main" ),
IM_INPUT_IMAGE( "sub" ),
IM_OUTPUT_IMAGE( "out" ),
IM_INPUT_INTVEC( "x" ),
IM_INPUT_INTVEC( "y" )
};
/* Call im_insertplaceplaceset via arg vector.
*/
static int
insertplaceset_vec( im_object *argv )
{
im_intvec_object *xv = (im_intvec_object *) argv[3];
im_intvec_object *yv = (im_intvec_object *) argv[4];
if( xv->n != yv->n ) {
im_error( "im_insertplaceset", "%s",
_( "vectors not same length" ) );
return( -1 );
}
if( im_insertset( argv[0], argv[1], argv[2], xv->n, xv->vec, yv->vec ) )
return( -1 );
return( 0 );
}
/* Description of im_insertplaceset.
*/
static im_function insertplaceset_desc = {
"im_insertplaceset", /* Name */
"insert sub into main at every position in x, y",
0, /* Flags */
insertplaceset_vec, /* Dispatch function */
IM_NUMBER( insertplaceset_args ), /* Size of arg list */
insertplaceset_args /* Arg list */
};
/* Package up all these functions.
*/
static im_function *deprecated_list[] = {
@ -805,6 +846,7 @@ static im_function *deprecated_list[] = {
&convsub_desc,
&clip2s_desc,
&clip2ui_desc,
&insertplaceset_desc,
&clip2us_desc,
&print_desc,
&slice_desc,