[FFmpeg-devel] [RFC v2 3/3] daaladec: Implement a native Daala decoder

Michael Niedermayer michael at niedermayer.cc
Tue Dec 29 18:25:12 CET 2015


On Tue, Dec 29, 2015 at 02:12:44AM +0000, Rostislav Pehlivanov wrote:
> Hmm, kinda odd.
> I've attached a v2 of the RFC Patch which does this:
> 1. Fixed some typos.
> 2. Fixed some missing newlines at the end of daalatab*
> 3. Moves the pix_fmt finding function inside the main decoder file.
[...]

> +#ifndef AVCODEC_DAALAENTROPY_H
> +#define AVCODEC_DAALAENTROPY_H
> +
> +#include "libavutil/avassert.h"
> +
> +#include "daala.h"
> +#include "daalatab.h"
> +
> +#define DAALAENT_CDF_ACCESS(n) &daalaent_cdf_tab[((n)*((n) - 1) >> 1) - 1]
> +
> +#define DAALAENT_WSIZE (int)sizeof(ent_win)*CHAR_BIT
> +#define DAALAENT_BIT_ABUNDANCE 16384
> +#define DAALAENT_UINT_BITS 4
> +#define DAALAENT_MODEL_TAB 12

> +#define DAALAENT_SAT(a,b) (a - FFMIN(a,b))

the "a" should be protected by a ()


> +
> +#define DAALAENT_PVQ_COUNT    2
> +#define DAALAENT_PVQ_COUNT_EX 3
> +#define DAALAENT_PVQ_K        0
> +#define DAALAENT_PVQ_SUM_EX   1

> +#define DAALAENT_PVQ_NOVAL    (-2147483647-1)

why is the 1 not already subtracted in the written value ?
[...]

> +int daaladsp_init(DaalaDSP *d, int bit_depth)

needs a prefix or static

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

While the State exists there can be no freedom; when there is freedom there
will be no State. -- Vladimir Lenin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20151229/6c1b69a6/attachment.sig>


More information about the ffmpeg-devel mailing list