From: Sylwester Nawrocki <sylvester.nawrocki@gmail.com>
To: Mike Dyer <mike.dyer@md-soft.co.uk>
Cc: LMML <linux-media@vger.kernel.org>,
"linux-samsung-soc@vger.kernel.org"
<linux-samsung-soc@vger.kernel.org>
Subject: Re: s5p-fimc capturing interlaced BT656
Date: Fri, 03 Aug 2012 21:17:43 +0200 [thread overview]
Message-ID: <501C23D7.3020307@gmail.com> (raw)
In-Reply-To: <1343911731.4113.5.camel@edge>
Hi Mike,
On 08/02/2012 02:48 PM, Mike Dyer wrote:
> Hi All,
>
> I'm using the S5PV210 camera IF and capturing BT656 video from a TVP5150
> video decoder.
>
> I notice that the capture driver ignores the field interlace flags
> reported by the 'sensor' and always uses 'V4L2_FIELD_NONE'. It also
> seems each field ends up in it's own frame, using only half the height.
s5p-fimc driver doesn't support the interlaced video capture, as we had
no such use case yet. Patches adding it are welcome.
> What would need to be done to store both fields in a single frame, for
> example in a V4L2_FIELD_INTERLACE_TB/BT format?
Firstly, it would good to figure out FIMC register settings that would
allow storing both fields in a single frame. I _suspect_ it's as simple
as setting CAM_INTERLACE bit in CIGCTRL register. Have you perhaps tried
it already ?
For a quick test a patch as below might be sufficient.
diff --git a/drivers/media/video/s5p-fimc/fimc-reg.c b/drivers/media/video/s5p-fimc/fimc-reg.c
index 1fc4ce8..19afa1a 100644
--- a/drivers/media/video/s5p-fimc/fimc-reg.c
+++ b/drivers/media/video/s5p-fimc/fimc-reg.c
@@ -576,6 +576,8 @@ int fimc_hw_set_camera_polarity(struct fimc_dev *fimc,
if (cam->flags & V4L2_MBUS_FIELD_EVEN_LOW)
cfg |= FIMC_REG_CIGCTRL_INVPOLFIELD;
+ cfg |= FIMC_REG_CIGCTRL_INTERLACE;
+
writel(cfg, fimc->regs + FIMC_REG_CIGCTRL);
return 0;
--
Thanks,
Sylwester
next prev parent reply other threads:[~2012-08-03 19:17 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-02 12:48 s5p-fimc capturing interlaced BT656 Mike Dyer
2012-08-03 19:17 ` Sylwester Nawrocki [this message]
2012-08-03 20:01 ` Mike Dyer
2012-08-03 20:28 ` Sylwester Nawrocki
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=501C23D7.3020307@gmail.com \
--to=sylvester.nawrocki@gmail.com \
--cc=linux-media@vger.kernel.org \
--cc=linux-samsung-soc@vger.kernel.org \
--cc=mike.dyer@md-soft.co.uk \
/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 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).