[FFmpeg-soc] [soc]: r2505 - aac/aac.c

Michael Niedermayer michaelni at gmx.at
Sat Jun 21 15:59:57 CEST 2008


On Sat, Jun 21, 2008 at 03:49:06PM +0200, superdump wrote:
> Author: superdump
> Date: Sat Jun 21 15:49:05 2008
> New Revision: 2505
> 
> Log:
> Make VLC tables static and use INIT_VLC_USE_STATIC for VLC initialisation
> 
> 
> Modified:
>    aac/aac.c
> 
> Modified: aac/aac.c
> ==============================================================================
> --- aac/aac.c	(original)
> +++ aac/aac.c	Sat Jun 21 15:49:05 2008
> @@ -65,6 +65,9 @@ DECLARE_ALIGNED_16(static float, kbd_sho
>  DECLARE_ALIGNED_16(static float, sine_long_1024[1024]);
>  DECLARE_ALIGNED_16(static float, sine_short_128[128]);
>  
> +static VLC mainvlc;
> +static VLC books[11];
> +
>  /**
>   * Audio Object Types
>   */
> @@ -365,8 +368,6 @@ typedef struct {
>       * @defgroup tables   Computed / setup during initialization
>       * @{
>       */
> -    VLC mainvlc;
> -    VLC books[11];
>      MDCTContext mdct;
>      MDCTContext mdct_small;
>      MDCTContext *mdct_ltp;
> @@ -813,10 +814,10 @@ static int aac_decode_init(AVCodecContex
>          int dim = (i >= 4 ? 2 : 4);
>          int mod = mod_cb[i], off = off_cb[i], index = 0;
>  
> -        if(init_vlc(&ac->books[i], 6, values,
> +        if(!books[i].table && init_vlc(&books[i], 6, values,
>                  tmp[i].a_bits, a_bits_size, a_bits_size,
>                  tmp[i].a_code, a_code_size, a_code_size,
> -                0) < 0)
> +                INIT_VLC_USE_STATIC) < 0)
>              return -1;

NO!!!

INIT_VLC_STATIC or INIT_VLC_USE_NEW_STATIC 
NOT INIT_VLC_USE_STATIC

RTFS:
#define INIT_VLC_USE_STATIC 1 ///< VERY strongly deprecated and forbidden

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

Everything should be made as simple as possible, but not simpler.
-- Albert Einstein
-------------- 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-soc/attachments/20080621/d96cbcf4/attachment.pgp>


More information about the FFmpeg-soc mailing list