Hans Verkuil wrote:
> On Saturday 20 October 2007 18:56:22 Duncan Webb wrote:
>> Hans Verkuil wrote:
>>> On Saturday 20 October 2007 17:02:16 Duncan Webb wrote:
>>>> Hans Verkuil wrote:
>>>>> On Saturday 20 October 2007 11:31:27 Duncan Webb wrote:
>>>>>> Hans Verkuil wrote:
>>>>>>> The old IVTV_IOC_S_GOP_END has been removed. Instead use the
>>>>>>> new VIDIOC_ENCODER_CMD and VIDIOC_TRY_ENCODER_CMD ioctls if you
>>>>>>> want this feature. See the v4l2 spec for more details.
>>>>>> Still having a little bit of a problem with VIDIOC_ENCODER_CMD,
>>>>>> does this need to be called just before the stream off command,
>>>>>> replace it (as I think is correct) or as with IVTV_IOC_S_GOP_END
>>>>>> before reading begins?
>>>>> It replaces STREAMOFF. STREAMOFF was always a half-baked
>>>>> implementation at best and was replaced with this command. The
>>>>> STREAMON/OFF command are really meant for the V4L2 stream I/O
>>>>> API. Since ivtv doesn't support stream I/O the driver's
>>>>> VIDIOC_STREAMOFF support was removed.
>>>> Sorry to bug you Hans,
>>>>
>>>> I can't seem to get VIDIOC_ENCODER_CMD to work, I written a little
>>>> test program (attached)
>>>>
>>>> I would expect that after having sent the VIDIOC_ENCODER_CMD to
>>>> stop, that a read would return 0 bytes, but it seems that the
>>>> buffer is always full.
>>> Hmm, I suddenly remembered that I fixed something related to
>>> GOP_END:
>>>
>>> changeset:   6096:13e00f878706
>>> user:        Hans Verkuil <[EMAIL PROTECTED]>
>>> date:        Thu Aug 23 22:51:07 2007 +0200
>>> files:       linux/drivers/media/video/ivtv/ivtv-fileops.c
>>> linux/drivers/media/video/ivtv/ivtv-streams.c
>>> description:
>>> ivtv: fix V4L2_ENC_CMD_STOP_AT_GOP_END support
>>>
>>> From: Hans Verkuil <[EMAIL PROTECTED]>
>>>
>>> Support for V4L2_ENC_CMD_STOP_AT_GOP_END was broken. While the
>>> driver correctly waited for the card to capture until the GOP was
>>> complete, afterwards the driver buffers were just flushed instead
>>> of waiting for the application to read all the pending data.
>>>
>>> Signed-off-by: Hans Verkuil <[EMAIL PROTECTED]>
>>>
>>> The fix is in the v4l-dvb repository and will appear in the 2.6.24
>>> kernel.
>>>
>>> Testing you app with the v4l-dvb repository shows that it works
>>> fine.
>> Just installed the v4l-dvb from its repository, I'm not sure if this
>> is a valid thing to do with a 2.6.22.5 kernel. But it compiled and
>> installed cleanly.
>>
>> My little app failed with an invalid argument, I'm wonder if there is
>> some module that I should have removed.
>>
>> ioctl V4L2_ENC_CMD_STOP failed: Invalid argument
>>
>> Sorry to be a pain, I would like this to work because memcoder and
>> matroska like complete GOPs otherwise the audio gets out of sync, but
>> this could be an encoding option problem.
> 
> Are you sure you're not using an old ivtv? The version reported in the 
> kernel log should be 1.1.0. Your test app runs fine here.
> 
> Oh, make sure you are using the right videodev2.h. Check if the 
> videodev2.h you are including in your test application is up to date.

Works perfectly, it was my fault :(

The problems is that I have a saa7134 card in the machine as well and
sometimes the devices change the order. So what I tried was to put the
modules in /etc/sysconfig/modules in a fixed order, but this runs too
soon for the ivtv driver and it doesn't find the firmware, so I left in
the saa7134 card in /etc/sysconfig/modules and let udev load the ivtv
card and forgot that the ivtv card was /dev/video1.

Regards,
Duncan


_______________________________________________
ivtv-devel mailing list
[email protected]
http://ivtvdriver.org/mailman/listinfo/ivtv-devel

Reply via email to