[aravis] control: improve arv-control help output.



commit 82c00792efcf73a8393ef8979014fb7e6ef63d58
Author: Emmanuel Pacaud <emmanuel gnome org>
Date:   Mon Jun 20 16:46:08 2011 +0200

    control: improve arv-control help output.

 src/Makefile.am  |    1 +
 src/arvcontrol.c |   11 ++++++++---
 2 files changed, 9 insertions(+), 3 deletions(-)
---
diff --git a/src/Makefile.am b/src/Makefile.am
index 9c66e74..5af8972 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -12,6 +12,7 @@ INCLUDES = \
 	-DPACKAGE_SRC_DIR=\""$(srcdir)"\" \
 	-DPACKAGE_DATA_DIR=\""$(datadir)"\" $(ARAVIS_CFLAGS) \
 	-DARAVIS_DATA_DIR=\""$(aravis_datadir)"\" \
+	-DARAVIS_API_VERSION=\""$(ARAVIS_API_VERSION)"\" \
 	-DG_LOG_DOMAIN=\"Aravis\"
 
 AM_CFLAGS = -Wall
diff --git a/src/arvcontrol.c b/src/arvcontrol.c
index 720e39b..4122b34 100644
--- a/src/arvcontrol.c
+++ b/src/arvcontrol.c
@@ -10,13 +10,13 @@ static char *arv_option_debug_domains = NULL;
 static const GOptionEntry arv_option_entries[] =
 {
 	{ "name",		'n', 0, G_OPTION_ARG_STRING,
-		&arv_option_device_name,	"Camera name", NULL},
+		&arv_option_device_name,	NULL, "device_name"},
 	{ "list",		'l', 0, G_OPTION_ARG_NONE,
 		&arv_option_list,		"List available features", NULL},
 	{ "description",	'i', 0, G_OPTION_ARG_NONE,
 		&arv_option_show_description,	"Show feature description", NULL},
 	{ "debug", 		'd', 0, G_OPTION_ARG_STRING,
-		&arv_option_debug_domains, 	"Debug domains", NULL },
+		&arv_option_debug_domains, 	"Debug", "domain[:level][,domain:[level]]..." },
 	{ NULL }
 };
 
@@ -65,7 +65,12 @@ main (int argc, char **argv)
 	g_thread_init (NULL);
 	g_type_init ();
 
-	context = g_option_context_new (NULL);
+	context = g_option_context_new ("feature[=value] ...");
+	g_option_context_set_summary (context, "Small utility for read/write of Genicam device features.");
+	g_option_context_set_description (context,
+					  "For example the setting of the Width and Height features, followed by"
+					  " the read of the Gain, is done with this command: 'arv-control-"
+					  ARAVIS_API_VERSION " Width=128 Height=128 Gain'.");
 	g_option_context_add_main_entries (context, arv_option_entries, NULL);
 
 	if (!g_option_context_parse (context, &argc, &argv, &error)) {



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]