[FFmpeg-devel] [PATCH] improve DV probe score

Michael Niedermayer michaelni
Tue Sep 15 03:54:23 CEST 2009

On Mon, Sep 14, 2009 at 03:38:53PM +0200, Reimar D?ffinger wrote:
> On Mon, Sep 14, 2009 at 03:06:06PM +0200, Michael Niedermayer wrote:
> > On Mon, Sep 14, 2009 at 09:59:31AM +0200, Reimar D?ffinger wrote:
> > that said, while i disagree with how you solve this, i
> > do not object to the patch, it is an improvment to what we have now
> > i just think it can be done quite a bit more solidly, even a check
> > of the number of startcodes per byte && the matches being > 3 would
> > be better than what its now, also as you return a score >0 for a single
> > match, am i missing something or shouldnt a single valid frame have at
> > least 10 matches? it seems requireing 3 before a non 0 score is returned
> > seems quite reasonable to me
> How did you come up with the number 10? These checks are exactly like
> that used to find the start of the frame, so there should be at most 2
> matches per frame, and we have a sample with only one match per frame

static void dv_format_frame(DVVideoContext* c, uint8_t* buf)
    int chan, i, j, k;

    for (chan = 0; chan < c->sys->n_difchan; chan++) {
        for (i = 0; i < c->sys->difseg_size; i++) {
            buf += dv_write_dif_id(dv_sect_header, chan, i, 0, buf);
            buf += dv_write_pack((c->sys->dsf ? dv_header625 : dv_header525), c, buf);

difseg_size being at least 10 in dvdata.h

PS: why are some functions in dvdata.h? iam asking because it drives me
nuts having to hunt them down when RTFS ...

Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Into a blind darkness they enter who follow after the Ignorance,
they as if into a greater darkness enter who devote themselves
to the Knowledge alone. -- Isha Upanishad
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20090915/ab24521d/attachment.pgp>

More information about the ffmpeg-devel mailing list