[FFmpeg-devel] Fwd: framebuffer device demuxer

Luca Abeni lucabe72
Mon Feb 22 13:18:27 CET 2010

Stefano Sabatini wrote:
>> From a quick look at the patch, the code implementing
>> the timing seems to be overly complex (and looks wrong
>> - but I did not completely check). Anyway, this seems
>> to be the cause for the wrong frame rate I obtain.
>> Moreover, I believe that support for the NONBLOCK flag
>> should be implemented before the patch is ready for svn.
> I vaguely remember the discussion about the NONBLOCK flag when the
> jackdev input was added, but no more than that. Can you provide some
> pointers to the discussion?

I have no pointers to the discussion, but basically every input
device should support the AVFMT_FLAG_NONBLOCK flag (yes, I know
there are some input devices that do not support it, but this
is because they are old input devices that have not been updated
yet; new code should support AVFMT_FLAG_NONBLOCK).
There was some discussion about supporting it for output
devices, but I do not remember the conclusion.
Anyway, for input devices, it is pretty simple: if
AVFMT_FLAG_NONBLOCK is set, the input device should never block
(but return AVERROR(EAGAIN) if no data is available).
You can look at v4l2.c, alsa input, or vfwcap.c for examples.

>> Finally, a warning: are your sure about the license?
>> The code claims to be LGPL, but seems to be based on
>> GPLed code.
> fbgrab.c is GPLed, at a quick glance doesn't seem they're sharing a
> significant part of code, while the framebuffer_read_packet() code
> mostly comes from x11grab.c.
Exactly. The potential problem is that the comments say:
  * This file contains code from fbgrab.c:
(which is release under GPL, as far as I can see)
  * This file contains code from the x11grab.c:
(which is GPLed too, I think).
  * FFmpeg is free software; you can redistribute it and/or
  * modify it under the terms of the GNU Lesser General Public
  * License as published by the Free Software Foundation; either
  * version 2.1 of the License, or (at your option) any later version.
  * You should have received a copy of the GNU Lesser General Public
  * License along with FFmpeg; if not, write to the Free Software
Which looks like a contraddiction (contains code from GPLed, but
is released under LGPL).

I did not check which part of the comment is wrong, but I
think that something has to be fixed, there :)


More information about the ffmpeg-devel mailing list