HE-AAC Audio Decoder Library

Table of Contents

Library Overview

This section describes the content of the HE-AAC (High-Efficiency Advanced Audio Coding) Audio Decoder Library and the interfaces for using the HE-AAC library from user applications.

The HE-AAC library provides a program interface that decodes AAC-encoded bitstream data that conforms to the HE-AAC Audio format (bitstream data).

The HE-AAC library takes bitstream data as input and outputs PCM RAW data (audio data).


Figure 1: Library Overview

Package Contents

The package content of the HE-AAC library is as follows.

Folder Filename Content
%CAFE_ROOT%\system\lib\ghs\cafe\NDEBUG aacdec.a HE-AAC Audio Decoder Library.
%CAFE_ROOT%\system\include\cafe aacdec.h Header file that defines things like function names and return values.

Resources Occupied

The resources necessary to use this library are as follows.

Content Size (Bytes)
HE-AAC Audio Decoder Library 283,172
Memory the user application should allocate for this library to use. 162,732

Implementation Notes

To implement this library, the user application must allocate memory to be used by the library. For more information about memory allocations and limitations, see Memory.

Library Specifications

Input Specifications

Format

The input format is as follows.

Output Specifications

Format

The output format is as follows.

Operational Specifications

Memory

To run this library, the application must allocate memory to be used by the library.

The library uses three areas of memory: working memory, bitstreams memory to be entered into the library, and audio data memory to be output from the library.

The following table shows memory sizes for the library.

Type of Memory Required Size of Memory (in bytes)
Working memory. 162,732
Bitstream memory (area for loading 1 frame's worth of data into the library). 800 * 6 channels.
Audio data memory (area for writing data to be output from the library). 2048 * 6 channels * 2 (see note).

NOTE:
The final *2 refers to the fact that size is doubled for HE-AAC. The channel part varies depending on the condition set in the library.

Get the working memory size using the utility function HEAACDECMemoryRequirement.

  1. Working memory and audio data memory should be made writable for this library.
  2. The user application holds the memory so that this library can use it from the opening process HEAACDECOpen through the completion process HEAACDECClose for working memory, and during the decoding process (while the execution process HEAACDECExecute is running) for bitstream memory.
  3. The user application cannot rewrite the working memory, bitstream memory, or audio data memory while this library is running (for bitstream memory, only for the range covered by decoding).
  4. Audio data memory will be allocated for each channel, and the starting address for these will be arrays. This array's start address is assigned as the fourth argument (the start address of storage location for decoding data) at the time of calling the execution process HEAACDECExecute and the completion process HEAACDECEnd.

Running Decoding

This library handles the decoding process using frames as the basic unit.

With this library, processing is performed based on the set decoding conditions (the third parameter of the open HEAACDECOpen process), but the consistency with the encoding conditions for the decode target (bitstream) is not verified. This library behaves as follows when the conditions are inconsistent.

Correspondence Between Number of Channels and Library Behavior

Condition Set in Library Channels in Bitstream Decoding Result
1 2 The decoding result is output only for the left channel.
2 1 The decoding result is output for the left channel, and silence is output for the right channel.
1 5.1 The decoding result is output only for the left channel.
2 5.1 The decoding result is output only for the left and right channels.
5.1 1 The decoding result is output for the left channel, and silence is output for the rest.
5.1 2 The decoding result is output for the left and right channels, and silence is output for the rest.

Library Features

This section provides an overview of the decoding features of the HE-AAC library.

Decoding Data Flow

The data flow for the HE-AAC decoding process is shown in the diagram below, and the inter-module data details are shown in the following table.


Figure 2: Decoding Process Data Flow


Inter-Module Data Details

Number Details
1 AAC encoding bitstream data (1 frame of bitstream data).
2 PCM RAW data (1 frame of audio data).

Decoding Process Flow

A schematic of the flow of this library's decoding process is shown in the following diagram.

This library is designed so that the execution process HEAACDECExecute outputs the results of decoding the frame that was input the previous time it was called. Because of the delay of 1 frame, input of the first frame is performed by the begin process HEAACDECBegin and output of the frame is performed by the end process HEAACDECEnd.

Decoding Process Flow


Figure 3: Decoding Process Flow

See Also

AACDEC Demo

Revision History

2014/07/16 Initial version.


CONFIDENTIAL