From 415b6d08be5ed8b427a33c8ea6bd04c0c029e1ff Mon Sep 17 00:00:00 2001 From: John Cupitt Date: Thu, 19 Jun 2014 09:59:29 +0100 Subject: [PATCH] small fixups - remove -c abbrv. for --vips-concurrency - better desc for insert - revise vips.1 man page --- TODO | 6 ++++-- libvips/conversion/insert.c | 3 ++- libvips/iofuncs/init.c | 2 +- man/vips.1 | 29 +++++++++++++++-------------- 4 files changed, 22 insertions(+), 18 deletions(-) diff --git a/TODO b/TODO index a5d9d939..d64c2ede 100644 --- a/TODO +++ b/TODO @@ -6,9 +6,11 @@ on set_progress(FALSE) vips_sink_disc() should stop calling vips_image_preeval() -- rewrite vips.1 manpage +- shouldn't -- remove -c abbrev. for --vips-concurrency + $ vips invert --help + + produce help for invert? or did that get removed? - threadpool recyling might be useful for dzsave? diff --git a/libvips/conversion/insert.c b/libvips/conversion/insert.c index 240ddc51..d9bbb9bb 100644 --- a/libvips/conversion/insert.c +++ b/libvips/conversion/insert.c @@ -451,7 +451,8 @@ vips_insert_class_init( VipsInsertClass *class ) gobject_class->get_property = vips_object_get_property; vobject_class->nickname = "insert"; - vobject_class->description = _( "insert an image" ); + vobject_class->description = + _( "insert image @sub into @main at @x, @y" ); vobject_class->build = vips_insert_build; operation_class->flags = VIPS_OPERATION_SEQUENTIAL_UNBUFFERED; diff --git a/libvips/iofuncs/init.c b/libvips/iofuncs/init.c index 680fdc70..c6e63d4b 100644 --- a/libvips/iofuncs/init.c +++ b/libvips/iofuncs/init.c @@ -511,7 +511,7 @@ static GOptionEntry option_entries[] = { { "vips-fatal", 0, G_OPTION_FLAG_HIDDEN | G_OPTION_FLAG_NO_ARG, G_OPTION_ARG_CALLBACK, (gpointer) &vips_set_fatal_cb, N_( "abort on first error or warning" ), NULL }, - { "vips-concurrency", 'c', 0, + { "vips-concurrency", 0, 0, G_OPTION_ARG_INT, &vips__concurrency, N_( "evaluate with N concurrent threads" ), "N" }, { "vips-tile-width", 0, G_OPTION_FLAG_HIDDEN, diff --git a/man/vips.1 b/man/vips.1 index 4186470b..668f94c8 100644 --- a/man/vips.1 +++ b/man/vips.1 @@ -6,13 +6,13 @@ vips \- run vips operations from the command line .SH DESCRIPTION .B vips(1) is the VIPS universal main program. You can use it to run any VIPS operation -from the command line, to query the VIPS function database, and to +from the command line, to query the VIPS class hierarchy, and to maintain parts of the VIPS library. To run a VIPS function, the first argument should be the name of the function and following arguments should be the function parameters. For example: - $ vips im_invert lena.v lena2.v + $ vips invert lena.v lena2.v .SH OPTIONS .TP @@ -28,7 +28,7 @@ Show VIPS version. .TP .B list PACKAGE List operations defined in PACKAGE. PACKAGE can also be "classes", "packages" -or "all". +or "all". .TP .B cpph PACKAGE @@ -46,26 +46,27 @@ vips8 interface. .SH EXAMPLES -Run a vips7 operation. The vips7 interface does not suport optional arguments. - - $ vips im_invert lena.v lena2.v - Run a vips8 operation. Operation options must follow the operation name. - $ vips add --imtest=option.jpg lena.v lena2.v out.v + $ vips insert lena.v lena2.v out.v 0 0 --background "128 0 0" Get a "usage" message for an operation - $ vips add + $ vips insert + insert image @sub into @main at @x, @y usage: - add left right out - add two images + insert main sub out x y where: - left - Left-hand image argument, input VipsImage - right - Right-hand image argument, input VipsImage + main - Main input image, input VipsImage + sub - Sub-image to insert into main image, input VipsImage out - Output image, output VipsImage + x - Left edge of sub in main, input gint + y - Top edge of sub in main, input gint + optional arguments: + expand - Expand output to hold all of both inputs, input gboolean + background - Colour for new pixels, input VipsArrayDouble operation flags: sequential-unbuffered - add: too few arguments + insert: too few arguments .SH RETURN VALUE returns 0 on success and non-zero on error.