On Tue, 30 Sep 2003, Richard Ellis wrote:

> For a while it has seemed to me that negative width and height values
> given to yuvdenoise on the -b parameter have not in fact created a

        Never used them myself - and judging from the length of time
        the code has (apparently) never been right no one else has
        till now either ;)

> values given to -b are put into the structure denoiser.border.[xywh]. 
> The definition of the denoiser.border structure in global.h defines
> border.[xywh] as uint16_t, or unsigned.  This appears to be the
> source of this bug in the info dump:

        Hmmm, that's part of the problem but even if that were fixed
        the next thing you'll see is that there's no code to take
        the frame width and subtract (or add the negative) border
        size.   

> 
> INFO: [yuvdenoise]  Frame border     : x:  4 y:  4 w:65532 h:65532

> Note the w: and h: sizes.  The border was specified as -b 4,4,-4,-4,
> and when a -4 signed int is stuffed into an unsigned int variable,
> 65532 is the resultant value.

        That's the -4 exactly - what should have happened is that
        the frame width and the relative border offset should have
        been added together - 720 + -4 would give 716 regardless of
        the unsigned/signed nature of the border value (since
        720 + 65532 within 16 bits will give 716 just as 720 - 4 does).
        Similarily for the height, the 65532 should have become 476 
        (480 - 4 or 480 + 65532 within 16 bits).

        I suspect the manpage was written with the expectation that
        relative offsets would be done eventually or if the calculations
        were accidentally removed.

        Probably Be easier to update the manpage and remove the reference
        to relative offsets - it's obviously not a heavily used feature ;)

        Cheers,
        Steven Schultz



-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users

Reply via email to