linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/2] media-ctl: fix ycbcr property in help description
@ 2020-10-27 13:49 Marian Cichy
  2020-10-27 13:49 ` [PATCH 2/2] media-ctl: add v4l2-ycbcr-enc-func field " Marian Cichy
  0 siblings, 1 reply; 2+ messages in thread
From: Marian Cichy @ 2020-10-27 13:49 UTC (permalink / raw)
  To: linux-media; +Cc: Marian Cichy

the help description in media-ctl claims that the
ycbcr property in v4l2-mbusfmt is called 'ycbcr-enc',
which will lead to an EINVAL when used as the property
is actually called 'ycbcr'.

Signed-off-by: Marian Cichy <m.cichy@pengutronix.de>
---
 utils/media-ctl/options.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/utils/media-ctl/options.c b/utils/media-ctl/options.c
index fb923775..fe79af10 100644
--- a/utils/media-ctl/options.c
+++ b/utils/media-ctl/options.c
@@ -78,7 +78,7 @@ static void usage(const char *argv0)
 	printf("\tv4l2-property   = v4l2-mbusfmt | v4l2-crop | v4l2-interval\n");
 	printf("\t                | v4l2-compose | v4l2-interval ;\n");
 	printf("\tv4l2-mbusfmt    = 'fmt:' fcc '/' size ; { 'field:' v4l2-field ; } { 'colorspace:' v4l2-colorspace ; }\n");
-	printf("\t                   { 'xfer:' v4l2-xfer-func ; } { 'ycbcr-enc:' v4l2-ycbcr-enc-func ; }\n");
+	printf("\t                   { 'xfer:' v4l2-xfer-func ; } { 'ycbcr:' v4l2-ycbcr-enc-func ; }\n");
 	printf("\t                   { 'quantization:' v4l2-quant ; }\n");
 	printf("\tv4l2-crop       = 'crop:' rectangle ;\n");
 	printf("\tv4l2-compose    = 'compose:' rectangle ;\n");
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [PATCH 2/2] media-ctl: add v4l2-ycbcr-enc-func field in help description
  2020-10-27 13:49 [PATCH 1/2] media-ctl: fix ycbcr property in help description Marian Cichy
@ 2020-10-27 13:49 ` Marian Cichy
  0 siblings, 0 replies; 2+ messages in thread
From: Marian Cichy @ 2020-10-27 13:49 UTC (permalink / raw)
  To: linux-media; +Cc: Marian Cichy

the help-description of media-ctl shows the possible values
for v4l2-colorspace, v4l2-xfer-func anf v4l2-quant, but misses
to show them for v4l2-ycbcr-enc-func, eveb though they are
perfectly defined in the source code like for the other fields.
Lets print them too in the help description.

Signed-off-by: Marian Cichy <m.cichy@pengutronix.de>
---
 utils/media-ctl/options.c | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)

diff --git a/utils/media-ctl/options.c b/utils/media-ctl/options.c
index fe79af10..ca8106ba 100644
--- a/utils/media-ctl/options.c
+++ b/utils/media-ctl/options.c
@@ -103,23 +103,29 @@ static void usage(const char *argv0)
 		printf("\t                %s\n",
 		       v4l2_subdev_field_to_string(i));
 
-	printf("\tv4l2-colorspace One of the following:\n");
+	printf("\tv4l2-colorspace     One of the following:\n");
 
 	for (i = V4L2_COLORSPACE_DEFAULT; i <= V4L2_COLORSPACE_DCI_P3; i++)
 		printf("\t                %s\n",
 		       v4l2_subdev_colorspace_to_string(i));
 
-	printf("\tv4l2-xfer-func  One of the following:\n");
+	printf("\tv4l2-xfer-func      One of the following:\n");
 
 	for (i = V4L2_XFER_FUNC_DEFAULT; i <= V4L2_XFER_FUNC_SMPTE2084; i++)
 		printf("\t                %s\n",
 		       v4l2_subdev_xfer_func_to_string(i));
 
-	printf("\tv4l2-quant      One of the following:\n");
+	printf("\tv4l2-quant          One of the following:\n");
 
 	for (i = V4L2_QUANTIZATION_DEFAULT; i <= V4L2_QUANTIZATION_LIM_RANGE; i++)
 		printf("\t                %s\n",
 		       v4l2_subdev_quantization_to_string(i));
+
+	printf("\tv4l2-ycbcr-enc-func One of the following:\n");
+
+	for (i = V4L2_YCBCR_ENC_DEFAULT; i <= V4L2_YCBCR_ENC_SMPTE240M; i++)
+		printf("\t                %s\n",
+		       v4l2_subdev_ycbcr_encoding_to_string(i));
 }
 
 #define OPT_PRINT_DOT			256
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-10-27 13:50 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-10-27 13:49 [PATCH 1/2] media-ctl: fix ycbcr property in help description Marian Cichy
2020-10-27 13:49 ` [PATCH 2/2] media-ctl: add v4l2-ycbcr-enc-func field " Marian Cichy

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).