[FFmpeg-cvslog] r17863 - trunk/libavdevice/alsa-audio-common.c

Luca Abeni lucabe72
Fri Nov 20 15:18:26 CET 2009


Hi Michael,

Michael Niedermayer wrote:
[...]
>>> Nevertheless, my fix might be the correct behaviour anyway, because the 
>>> documentation says:
>>> #define AVFMT_FLAG_NONBLOCK     0x0004 ///< Do not block when reading 
>>> packets from input.
>>> So it's an input-only flag, not an output flag.
>> You are right; there is an inconsistency between behaviour and 
>> documentation.
>> However, I do not know if the error is in the documentation or in the 
>> current
>> behaviour; maybe Michael can comment on this (he is the one who asked for 
>> the
>> nonblocking behaviour).
> 
> id say setting AVFMT_FLAG_NONBLOCK for output has undefined behaviour
> we could change that and define it in some sane way of course ...

Ok... So, what's the behaviour we want for output?
I just verified that the "file" protocol is blocking for output, even
if AVFMT_FLAG_NONBLOCK is defined... So, maybe Ivo's patch is the best
solution (making the alsa output device consistent with the file protocol).

The other solution would be to update the documentation, changing it in
"Do not block when reading packets from input or writhing them to output".

Which one do you prefer?


				Thanks,
					Luca



More information about the ffmpeg-cvslog mailing list