[FFmpeg-devel] [PATCH 3/3] apng: Add a basic APNG muxer

Donny Yang work at kota.moe
Wed Apr 1 16:30:47 CEST 2015


On 2 April 2015 at 00:23, Michael Niedermayer <michaelni at gmx.at> wrote:

> On Wed, Apr 01, 2015 at 01:17:50PM +0000, Donny Yang wrote:
> > On 1 April 2015 at 23:28, Michael Niedermayer <michaelni at gmx.at> wrote:
> >
> > > On Wed, Apr 01, 2015 at 12:07:46PM +0000, Donny Yang wrote:
> > > > On 1 April 2015 at 22:57, Paul B Mahol <onemda at gmail.com> wrote:
> > > >
> > > > > On 4/1/15, Donny Yang <work at kota.moe> wrote:
> > > > > > On 1 April 2015 at 17:03, Paul B Mahol <onemda at gmail.com> wrote:
> > > > > >
> > > > > >> Dana 31. 3. 2015. 22:59 osoba "Donny Yang" <work at kota.moe>
> > > napisala je:
> > > > > >> > +#include <zlib.h>
> > > > > >>
> > > > > >> This is missing dependency on zlib in configure.
> > > > > >>
> > > > > > Fixed
> > > > > >
> > > > > >
> > > > >
> > > > > But this is more appropriate for APNG encoder. APNG muxer seems to
> not
> > > > > use zlib at all.
> > > > >
> > > > It's used for it's crc32 functions for editing/creating chunks.
> > >
> > > please use libavutil/crc*
> > >
> >
> > I applied the following patch to my code, but ffmpeg's functions seem to
> be
> > producing the wrong crc32 value.
> >
> > For example:
> > $ crc32 <(printf "acTL\x00\x00\x00\x14\x00\x00\x00\x00")
> > 1c2df152
> > While a `av_crc(av_crc_get_table(AV_CRC_32_IEEE), 0,
> > "acTL\x00\x00\x00\x14\x00\x00\x00\x00", 12)` returns 0xf6f7ccdd.
> > (using AV_CRC_32_IEEE_LE also produces an incorrect checksum)
> >
> > What am I doing wrong?
>
> http://www.w3.org/TR/PNG-CRCAppendix.html
> says:
>
> /* Update a running CRC with the bytes buf[0..len-1]--the CRC
>       should be initialized to all 1's, and the transmitted value
>       is the 1's complement of the final running CRC (see the
>       crc() routine below)). */
>

Thanks. Patch has been updated.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-apng-Add-a-basic-APNG-muxer.patch
Type: text/x-diff
Size: 13444 bytes
Desc: not available
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20150401/1d777b6c/attachment.bin>


More information about the ffmpeg-devel mailing list