[FFmpeg-devel] [PATCH][4/4] Enable use of the extended API

Benoit Fouet benoit.fouet
Mon Dec 17 09:43:39 CET 2007


Hi,

Michael Niedermayer wrote:
> On Fri, Dec 14, 2007 at 11:52:29AM +0100, Bj?rn Axelsson wrote:
>   
>> On Thu, 2007-12-13 at 23:26 +0100, Michael Niedermayer wrote:
>> [...]
>>     
>>> [...]
>>>       
>>>> @@ -1093,6 +1101,20 @@
>>>>      return 0;
>>>>  }
>>>>  
>>>> +static int asf_read_play(AVFormatContext *s)
>>>> +{
>>>> +    if (s->pb && s->pb->read_play)
>>>> +        return av_url_read_fplay(s->pb);
>>>> +    return AVERROR(ENOSYS);
>>>> +}
>>>> +
>>>> +static int asf_read_pause(AVFormatContext *s)
>>>> +{
>>>> +    if (s->pb && s->pb->read_pause)
>>>> +        return av_url_read_fpause(s->pb);
>>>> +    return AVERROR(ENOSYS);
>>>> +}
>>>> +
>>>>  AVInputFormat asf_demuxer = {
>>>>      "asf",
>>>>      "asf format",
>>>> @@ -1103,4 +1125,6 @@
>>>>      asf_read_close,
>>>>      asf_read_seek,
>>>>      asf_read_pts,
>>>> +    .read_play  = asf_read_play,
>>>> +    .read_pause = asf_read_pause,
>>>>  };
>>>>         
>>> i think the 2 functions above could be defaults if read_play/read_pause
>>> are NULL
>>>
>>> that is
>>> int av_read_pause(AVFormatContext *s)
>>> {
>>>     if(s->iformat->read_pause)
>>>         return s->iformat->read_pause(s);
>>>     if(s->pb && s->pb->read_pause)
>>>         return av_url_read_fpause(s->pb);
>>>     return AVERROR(ENOSYS);
>>> }
>>>
>>> [...]
>>>       
>> Yes, that makes sense. New patch attached.
>>     
>
> patch ok
>
>   

i missed some mails of those threads.
can this patch be applied even though the 3 others are not (my guess is 
that it can) ?

-- 
Ben
Purple Labs S.A.
www.purplelabs.com




More information about the ffmpeg-devel mailing list