[Ffmpeg-devel] [patch] *BSD bktr grab support

Jacob Meuser jakemsr
Sun May 22 20:25:25 CEST 2005


On Sun, May 22, 2005 at 11:04:13AM +0200, Michael Niedermayer wrote:
> Hi
> 
> On Thursday 19 May 2005 05:42, Jacob Meuser wrote:
> > here is the cleaned up patch for gab support for the bktr driver
> > found on *BSD systems.
> >
> > the license is now LGPL, I changed the tabs to 4 spaces, added a
> > couple comments, and took out an #if 0 block and a CVS Id
> > that were accidently left in the last version.
> 
> 
> > --- libavformat/grab.c	30 Apr 2005 21:43:58 -0000	1.34
> > +++ libavformat/grab.c	19 May 2005 03:37:10 -0000
> > @@ -364,7 +364,7 @@
> >  }
> >  
> >  static AVInputFormat video_grab_device_format = {
> > -    "video4linux",
> > +    "video_device",
> 
> is it theoretically impossible for v4l and bktr to coexist on the same 
> machine?

unless bktr is ported to Linux (unlikely), or V4L and bttv are ported
to *BSD (maybe some day, but then there would be no need for bktr) ...

impossible, well, no.  likely, definitely no.

> 
> > +uint8_t *video_buf;
> > +volatile sig_atomic_t nsignals = 0;
> [...]
> > +    static u_int64_t last_frame_time = 0;
> 
> non constant globals

OK

> 
> > +                printf ("\nSLEPT NO signals - %d microseconds late\n",
> > +                        (int) (av_gettime() - last_frame_time - 
> per_frame));
> 
> printf -> av_log

OK

> 
> > +void bf_memcpy (char *dest, char *src, int size)
> > +{
> > +    while (size -= 2)
> > +    {
> > +        dest[0] = src[1];
> > +        dest[1] = src[0];
> > +        dest += 2;
> > +        src += 2;
> > +    }
> > +}
> 
> colorspace conversation is not allowed in codecs, (de)muxers, video grab 
> code, ...

OK, I assume there are already functions for that in libavformat?

thanks again, Michael :)

-- 
<jakemsr at jakemsr.com>





More information about the ffmpeg-devel mailing list