[FFmpeg-devel] [PATCH 2/4] avcodec/ffv1: Implementation of the CRC proposal for v4

Michael Niedermayer michael at niedermayer.cc
Fri Oct 18 21:24:21 EEST 2019


On Fri, Oct 18, 2019 at 03:09:48AM +0200, Lynne wrote:
> Oct 17, 2019, 23:25 by michael at niedermayer.cc:
> Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
> ---
>  libavcodec/ffv1.h    |  1 +
>  libavcodec/ffv1dec.c | 10 +++++++---
>  libavcodec/ffv1enc.c | 10 +++++++---
>  3 files changed, 15 insertions(+), 6 deletions(-)
> 
> Why 0x4964AF46 instead of 0xFFFFFFFF?

CRC32 of 0x4964AF46 is 0xFFFFFFFF

its effect is just to apply a 0xFFFFFFFF flip where its needed on the decoder
side

This is the result of building a block [data] + [32bit checksum] which as a
whole has a CRC of 0.
So the code can be made simpler on the decoder side, the checksum no longer
represents a special case and if you want to apply error correction also
the checksum is not a special case

If theres a more beautifull way to achive the same then iam certainly
interrested in that

Thanks

--
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

"I am not trying to be anyone's saviour, I'm trying to think about the
 future and not be sad" - Elon Musk

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: not available
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20191018/72d99fae/attachment.sig>


More information about the ffmpeg-devel mailing list