cosmetics: Fix ATRAC codec name spelling
[libav.git] / libavcodec / atrac1data.h
CommitLineData
dbb0f96f 1/*
7df9e693 2 * ATRAC 1 compatible decoder data
dbb0f96f
BL
3 * Copyright (c) 2009 Maxim Poliakovski
4 * Copyright (c) 2009 Benjamin Larsson
5 *
2912e87a 6 * This file is part of Libav.
dbb0f96f 7 *
2912e87a 8 * Libav is free software; you can redistribute it and/or
dbb0f96f
BL
9 * modify it under the terms of the GNU Lesser General Public
10 * License as published by the Free Software Foundation; either
11 * version 2.1 of the License, or (at your option) any later version.
12 *
2912e87a 13 * Libav is distributed in the hope that it will be useful,
dbb0f96f
BL
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 * Lesser General Public License for more details.
17 *
18 * You should have received a copy of the GNU Lesser General Public
2912e87a 19 * License along with Libav; if not, write to the Free Software
dbb0f96f
BL
20 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
21 */
22
23/**
ba87f080 24 * @file
7df9e693 25 * ATRAC1 compatible decoder data
dbb0f96f
BL
26 */
27
28#ifndef AVCODEC_ATRAC1DATA_H
29#define AVCODEC_ATRAC1DATA_H
30
27666c31
DB
31#include <stdint.h>
32
dbb0f96f
BL
33static const uint8_t bfu_amount_tab1[8] = {20, 28, 32, 36, 40, 44, 48, 52};
34static const uint8_t bfu_amount_tab2[4] = { 0, 112, 176, 208};
35static const uint8_t bfu_amount_tab3[8] = { 0, 24, 36, 48, 72, 108, 132, 156};
36
37/** number of BFUs in each QMF band */
38static const uint8_t bfu_bands_t[4] = {0, 20, 36, 52};
39
40/** number of spectral lines in each BFU
41 * block floating unit = group of spectral frequencies having the
42 * same quantization parameters like word length and scale factor
43 */
44static const uint8_t specs_per_bfu[52] = {
45 8, 8, 8, 8, 4, 4, 4, 4, 8, 8, 8, 8, 6, 6, 6, 6, 6, 6, 6, 6, // low band
46 6, 6, 6, 6, 7, 7, 7, 7, 9, 9, 9, 9, 10, 10, 10, 10, // midle band
47 12, 12, 12, 12, 12, 12, 12, 12, 20, 20, 20, 20, 20, 20, 20, 20 // high band
48};
49
50/** start position of each BFU in the MDCT spectrum for the long mode */
51static const uint16_t bfu_start_long[52] = {
52 0, 8, 16, 24, 32, 36, 40, 44, 48, 56, 64, 72, 80, 86, 92, 98, 104, 110, 116, 122,
53 128, 134, 140, 146, 152, 159, 166, 173, 180, 189, 198, 207, 216, 226, 236, 246,
54 256, 268, 280, 292, 304, 316, 328, 340, 352, 372, 392, 412, 432, 452, 472, 492,
55};
56
57/** start position of each BFU in the MDCT spectrum for the short mode */
58static const uint16_t bfu_start_short[52] = {
59 0, 32, 64, 96, 8, 40, 72, 104, 12, 44, 76, 108, 20, 52, 84, 116, 26, 58, 90, 122,
60 128, 160, 192, 224, 134, 166, 198, 230, 141, 173, 205, 237, 150, 182, 214, 246,
61 256, 288, 320, 352, 384, 416, 448, 480, 268, 300, 332, 364, 396, 428, 460, 492
62};
63
64#endif /* AVCODEC_ATRAC1DATA_H */