From: Hans Verkuil <hverkuil@xs4all.nl>
To: Nicolas Dufresne <nicolas.dufresne@collabora.co.uk>,
Philipp Zabel <philipp.zabel@gmail.com>
Cc: Linux Media Mailing List <linux-media@vger.kernel.org>,
Mauro Carvalho Chehab <m.chehab@samsung.com>,
Kamil Debski <k.debski@samsung.com>,
Nicolas Dufresne <nicolas.dufresne@collabora.com>,
Sascha Hauer <kernel@pengutronix.de>
Subject: Re: [PATCH 2/3] [media] coda: fix coda_g_selection
Date: Sun, 27 Jul 2014 20:21:44 +0200 [thread overview]
Message-ID: <53D54338.9090707@xs4all.nl> (raw)
In-Reply-To: <69ab-53d52e80-1-565f8200@126846484>
On 07/27/2014 06:53 PM, Nicolas Dufresne wrote:
>
> Le Samedi 26 Juillet 2014 12:37 EDT, Philipp Zabel <philipp.zabel@gmail.com> a écrit:
>
>> I have tried the GStreamer v4l2videodec element with the coda driver and
>> noticed that GStreamer calls VIDIOC_CROPCAP to obtain the pixel aspect
>> ratio. This always fails with -EINVAL because of this issue. Currently GStreamer
>> throws a warning if the return value is an error other than -ENOTTY.
>
> But for now, this seems like a fair thing to do. We currently assume that if your
> driver is not implementing CROPCAP, then pixel aspect ratio at output will be
> unchanged at capture. If there is an error though, it's not good sign, and we report
> it. If that is wrong, let us know why and how to detect your driver error isn't a an error.
If cropcap returns -EINVAL then that means that the current input or output does
not support cropping (for input) or composing (for output). In that case the
pixel aspect ratio is undefined and you have no way to get hold of that information,
which is a bug in the V4L2 API.
In the case of an m2m device you can safely assume that whatever the pixel aspect
is of the image you give to the m2m device, it will still be the same pixel
aspect when you get it back. In fact, I would say that if an m2m device returns
cropcap information, then the pixel aspect ratio information is most likely not
applicable to the device and will typically be 1:1.
Pixel aspect ratio is only relevant if the video comes in or goes out to a physical
interface (sensor, video receiver/transmitter).
Regards,
Hans
next prev parent reply other threads:[~2014-07-27 18:22 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-26 14:34 [PATCH 1/3] [media] coda: fix coda_s_fmt_vid_out Philipp Zabel
2014-07-26 14:34 ` [PATCH 2/3] [media] coda: fix coda_g_selection Philipp Zabel
2014-07-26 15:12 ` Hans Verkuil
2014-07-26 16:37 ` Philipp Zabel
2014-07-26 17:08 ` Hans Verkuil
2014-07-27 16:53 ` Nicolas Dufresne
2014-07-27 18:21 ` Hans Verkuil [this message]
2014-07-27 21:32 ` Nicolas Dufresne
2014-07-27 22:22 ` Hans Verkuil
2014-07-28 9:28 ` Philipp Zabel
2014-07-26 14:34 ` [PATCH 3/3] [media] coda: set capture frame size with output S_FMT Philipp Zabel
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=53D54338.9090707@xs4all.nl \
--to=hverkuil@xs4all.nl \
--cc=k.debski@samsung.com \
--cc=kernel@pengutronix.de \
--cc=linux-media@vger.kernel.org \
--cc=m.chehab@samsung.com \
--cc=nicolas.dufresne@collabora.co.uk \
--cc=nicolas.dufresne@collabora.com \
--cc=philipp.zabel@gmail.com \
/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.