From: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
To: Nicolas Dufresne <nicolas@ndufresne.ca>
Cc: linux-media@vger.kernel.org, gstreamer-devel@freedesktop.org
Subject: Re: Gstreamer and vim2m with bayer capture formats
Date: Fri, 1 Feb 2019 16:23:46 -0200 [thread overview]
Message-ID: <20190201162346.729cf830@silica.lan> (raw)
In-Reply-To: <20190201155506.76354195@silica.lan>
Em Fri, 1 Feb 2019 15:55:06 -0200
Mauro Carvalho Chehab <mchehab+samsung@kernel.org> escreveu:
> Em Fri, 01 Feb 2019 12:03:49 -0500
> Nicolas Dufresne <nicolas@ndufresne.ca> escreveu:
>
> > If my change you have resources or time to work on a proper patch, be
> > aware that patch submissions works through gitlab.freedesktop.org Merge
> > Request (basically pushing a branch on a fork there and doing couple of
> > webui clicks).
>
> Ah, ok. Well, the intention here was just to do a RFC and check with
> you about the proper solution.
>
> While I do have a limited amount of time, due to my kernel duties,
> I could try to write a different patch for it once I understand
> better what should be done.
>
> While that doesn't happen, IMHO, the best is to send RFC patches via
> e-mail, as it allows c/c the discussions to the linux-media ML.
Cheers,
Mauro
Ah, I guess I see the issue... gst_v4l2_object_get_raw_caps() doesn't
associate bayer formats as a format that a v4l2transform would accept.
So, a change like the one below would make it to recognize the 4 bayer
formats that was added to vim2m as belonging to a v4l2convert type, right?
Indeed with this patch it is now recognizing the formats and a
v4l2video0convert block was recognized.
Unfortunately, this is not working yet:
$ gst-launch-1.0 videotestsrc ! video/x-raw,format=BGR ! v4l2video0convert disable-passthrough=1 extra-controls="s,horizontal_flip=1,vertical_flip=1" ! video/x-bayer,format=bggr ! bayer2rgb ! videoconvert ! ximagesink
Maybe I need to change something else too for it to negotiate between
a v4l2 capture sink from videoconvert and bayer2rgb source.
-
diff --git a/sys/v4l2/gstv4l2object.c b/sys/v4l2/gstv4l2object.c
index 124c778c626d..5a1e52989903 100644
--- a/sys/v4l2/gstv4l2object.c
+++ b/sys/v4l2/gstv4l2object.c
@@ -157,10 +157,10 @@ static const GstV4L2FormatDesc gst_v4l2_formats[] = {
{V4L2_PIX_FMT_NV42, TRUE, GST_V4L2_RAW},
/* Bayer formats - see http://www.siliconimaging.com/RGB%20Bayer.htm */
- {V4L2_PIX_FMT_SBGGR8, TRUE, GST_V4L2_CODEC},
- {V4L2_PIX_FMT_SGBRG8, TRUE, GST_V4L2_CODEC},
- {V4L2_PIX_FMT_SGRBG8, TRUE, GST_V4L2_CODEC},
- {V4L2_PIX_FMT_SRGGB8, TRUE, GST_V4L2_CODEC},
+ {V4L2_PIX_FMT_SBGGR8, TRUE, GST_V4L2_RAW | GST_V4L2_CODEC},
+ {V4L2_PIX_FMT_SGBRG8, TRUE, GST_V4L2_RAW | GST_V4L2_CODEC},
+ {V4L2_PIX_FMT_SGRBG8, TRUE, GST_V4L2_RAW | GST_V4L2_CODEC},
+ {V4L2_PIX_FMT_SRGGB8, TRUE, GST_V4L2_RAW | GST_V4L2_CODEC},
/* compressed formats */
{V4L2_PIX_FMT_MJPEG, FALSE, GST_V4L2_CODEC},
prev parent reply other threads:[~2019-02-01 18:23 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-02-01 14:32 Gstreamer and vim2m with bayer capture formats Mauro Carvalho Chehab
2019-02-01 17:03 ` Nicolas Dufresne
2019-02-01 17:55 ` Mauro Carvalho Chehab
2019-02-01 18:23 ` Mauro Carvalho Chehab [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190201162346.729cf830@silica.lan \
--to=mchehab+samsung@kernel.org \
--cc=gstreamer-devel@freedesktop.org \
--cc=linux-media@vger.kernel.org \
--cc=nicolas@ndufresne.ca \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.