annotate tremor/codec_internal.h @ 15291:21e7332ea44e

macosx core video module
author nplourde
date Fri, 29 Apr 2005 11:41:07 +0000
parents 8631a3803289
children cd6b211be811
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
14280
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
1 /********************************************************************
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
2 * *
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
3 * THIS FILE IS PART OF THE OggVorbis 'TREMOR' CODEC SOURCE CODE. *
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
4 * *
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
5 * THE OggVorbis 'TREMOR' SOURCE CODE IS (C) COPYRIGHT 1994-2002 *
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
6 * BY THE Xiph.Org FOUNDATION http://www.xiph.org/ *
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
7 * ALL REDISTRIBUTION RIGHTS RESERVED. *
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
8 * *
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
9 ********************************************************************
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
10
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
11 function: libvorbis codec headers
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
12
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
13 ********************************************************************/
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
14
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
15 #ifndef _V_CODECI_H_
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
16 #define _V_CODECI_H_
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
17
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
18 #include "codebook.h"
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
19
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
20 typedef void vorbis_look_mapping;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
21 typedef void vorbis_look_floor;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
22 typedef void vorbis_look_residue;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
23 typedef void vorbis_look_transform;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
24
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
25 /* mode ************************************************************/
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
26 typedef struct {
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
27 int blockflag;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
28 int windowtype;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
29 int transformtype;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
30 int mapping;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
31 } vorbis_info_mode;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
32
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
33 typedef void vorbis_info_floor;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
34 typedef void vorbis_info_residue;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
35 typedef void vorbis_info_mapping;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
36
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
37 typedef struct backend_lookup_state {
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
38 /* local lookup storage */
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
39 ogg_int32_t *window[2];
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
40
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
41 /* backend lookups are tied to the mode, not the backend or naked mapping */
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
42 int modebits;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
43 vorbis_look_mapping **mode;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
44
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
45 } backend_lookup_state;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
46
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
47 /* codec_setup_info contains all the setup information specific to the
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
48 specific compression/decompression mode in progress (eg,
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
49 psychoacoustic settings, channel setup, options, codebook
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
50 etc).
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
51 *********************************************************************/
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
52
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
53 typedef struct codec_setup_info {
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
54
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
55 /* Vorbis supports only short and long blocks, but allows the
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
56 encoder to choose the sizes */
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
57
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
58 long blocksizes[2];
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
59
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
60 /* modes are the primary means of supporting on-the-fly different
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
61 blocksizes, different channel mappings (LR or M/A),
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
62 different residue backends, etc. Each mode consists of a
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
63 blocksize flag and a mapping (along with the mapping setup */
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
64
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
65 int modes;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
66 int maps;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
67 int times;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
68 int floors;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
69 int residues;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
70 int books;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
71
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
72 vorbis_info_mode *mode_param[64];
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
73 int map_type[64];
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
74 vorbis_info_mapping *map_param[64];
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
75 int time_type[64];
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
76 int floor_type[64];
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
77 vorbis_info_floor *floor_param[64];
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
78 int residue_type[64];
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
79 vorbis_info_residue *residue_param[64];
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
80 static_codebook *book_param[256];
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
81 codebook *fullbooks;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
82
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
83 int passlimit[32]; /* iteration limit per couple/quant pass */
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
84 int coupling_passes;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
85 } codec_setup_info;
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
86
8631a3803289 internal Tremor decoder for Ogg/Vorbis
henry
parents:
diff changeset
87 #endif