sender: Deplete ACLs on exit.
[paraslash.git] / wma.h
1 /** \file wma.h The asf_header structure and public wma function declarations. */
2
3 /**
4  * Information contained in an asf audio file header.
5  *
6  * Both para_filter and para_afh need to read the header.
7  */
8 struct asf_header_info {
9         /** The size of the audio file header. */
10         int header_len;
11         /** Offset of the audio stream info header. */
12         int audio_stream_info_start;
13         /** Number of channels. */
14         uint8_t channels;
15         /** One of the 5 possible sample rates. */
16         uint16_t sample_rate;
17         /** Size of one data block. */
18         uint16_t block_align;
19         /** Bits per second. */
20         uint32_t bit_rate;
21         /** Further decoding information (ignored). */
22         uint32_t flags1;
23         /** Encodes exp_vlc, bit reservoir, vbl, number of block sizes. */
24         uint16_t flags2;
25         /** Whether exponents are coded with VLC codes. */
26         bool use_exp_vlc;
27         /** If false, a frame is equal to a superframe. */
28         bool use_bit_reservoir;
29         /** Whether blocks are of variable or of constant size. */
30         bool use_variable_block_len;
31         /** Obtained from the file properties object. */
32         uint32_t packet_size;
33 };
34
35 /* wma_common.c */
36 __a_const int wma_log2(unsigned int v);
37 const char *search_pattern(const char *pattern, int pattern_len,
38                 const char *buf, int buf_size);
39 int read_asf_header(const char *buf, int loaded, struct asf_header_info *ahi);
40
41 #define WMA_FRAME_SKIP 31