summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 3b44783)
raw | patch | inline | side by side (parent: 3b44783)
author | Nikhil Devshatwar <nikhil.nd@ti.com> | |
Wed, 5 Nov 2014 09:30:48 +0000 (15:00 +0530) | ||
committer | Nikhil Devshatwar <nikhil.nd@ti.com> | |
Fri, 14 Nov 2014 11:33:11 +0000 (17:03 +0530) |
Currently the VIP S_FMT ioctl does not specify the field type of
the capture. Request for alternate field type.
Also, the field type of captured buffer is returned by the driver.
Pass this field type when queuing buffers for the VPE source.
Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
the capture. Request for alternate field type.
Also, the field type of captured buffer is returned by the driver.
Pass this field type when queuing buffers for the VPE source.
Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
capturevpedisplay.c | patch | blob | history | |
util/vpe-common.c | patch | blob | history |
diff --git a/capturevpedisplay.c b/capturevpedisplay.c
index 15a308887b874ac963046d5090a52b9833e06c43..0b86d3b19923268769e671e5c18ae2adbc7aac1d 100644 (file)
--- a/capturevpedisplay.c
+++ b/capturevpedisplay.c
fmt.fmt.pix.width = width;
fmt.fmt.pix.height = height;
fmt.fmt.pix.pixelformat = fourcc;
+ fmt.fmt.pix.field = V4L2_FIELD_ALTERNATE;
ret = ioctl(vipfd, VIDIOC_S_FMT, &fmt);
if (ret < 0)
* @return: buf.index int
*****************************************************************************
*/
-int vip_dqbuf()
+int vip_dqbuf(struct vpe * vpe)
{
int ret;
struct v4l2_buffer buf;
if (ret < 0)
pexit("vip: DQBUF failed: %s\n", strerror(errno));
- dprintf("vip: DQBUF index = %d\n", buf.index);
+ dprintf("vip: DQBUF idx = %d, field = %s\n", buf.index,
+ buf.field == V4L2_FIELD_TOP? "Top" : "Bottom");
+ vpe->field = buf.field;
return buf.index;
}
vpe->field = V4L2_FIELD_ANY;
while (1)
{
- index = vip_dqbuf();
+ index = vip_dqbuf(vpe);
vpe_input_qbuf(vpe, index);
for (i = 1; i <= NUMBUF; i++) {
/** To star deinterlace, minimum 3 frames needed */
if (vpe->deint && count != 3) {
- index = vip_dqbuf();
+ index = vip_dqbuf(vpe);
vpe_input_qbuf(vpe, index);
} else {
stream_ON(vpe->fd, V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE);
diff --git a/util/vpe-common.c b/util/vpe-common.c
index c3f6e4eb48ebee09f9c58fed670f17c6e93cb15a..576addf194bf579ad5815efb47b7adea5db32db3 100755 (executable)
--- a/util/vpe-common.c
+++ b/util/vpe-common.c
struct v4l2_buffer buf;
struct v4l2_plane planes[2];
- dprintf("vpe input buffer queue\n");
+ dprintf("vpe: src QBUF (%d):%s field", vpe->field,
+ vpe->field==V4L2_FIELD_TOP?"top":"bottom");
memset(&buf, 0, sizeof buf);
memset(&planes, 0, sizeof planes);