WMA Voice decoding context. More...
A packet is considered to be a single unit of data provided to this decoder by the demuxer.
Superframe and frame data - these can change from frame to frame, although some of them do in that case serve as a cache / history for the next frame or superframe.
Variables used for postfilter implementation, mostly history for smoothing and so on, and context variables for FFT/iFFT.
WMA Voice decoding context.
Definition at line 132 of file wmavoice.c.
packet bitreader.
During decoder init, it contains the extradata from the demuxer. During decoding, it contains packet data.
Definition at line 137 of file wmavoice.c.
Referenced by parse_packet_header(), synth_superframe(), wmavoice_decode_init(), and wmavoice_decode_packet().
converts VLC codes to frame type
Definition at line 141 of file wmavoice.c.
Referenced by check_bits_for_superframe(), synth_frame(), and wmavoice_decode_init().
number of bits used to specify spillover_nbits in the packet header = ceil(log2(ctx->block_align << 3))
Definition at line 143 of file wmavoice.c.
Referenced by parse_packet_header(), and wmavoice_decode_init().
number of samples in history for signal prediction (through ACB)
Definition at line 146 of file wmavoice.c.
Referenced by synth_frame(), synth_superframe(), wmavoice_decode_init(), and wmavoice_flush().
whether to apply the averaged projection filter (APF)
Definition at line 150 of file wmavoice.c.
Referenced by synth_frame(), synth_superframe(), wmavoice_decode_end(), wmavoice_decode_init(), and wmavoice_flush().
strength of denoising in Wiener filter [0-11]
Definition at line 152 of file wmavoice.c.
Referenced by calc_input_response(), and wmavoice_decode_init().
Whether to apply tilt correction to the Wiener filter coefficients (postfilter)
Definition at line 154 of file wmavoice.c.
Referenced by calc_input_response(), and wmavoice_decode_init().
Predicted amount of DC noise, based on which a DC removal filter is used.
Definition at line 156 of file wmavoice.c.
Referenced by postfilter(), and wmavoice_decode_init().
number of LSPs per frame [10 or 16]
Definition at line 159 of file wmavoice.c.
Referenced by postfilter(), synth_block(), synth_frame(), synth_superframe(), wiener_denoise(), wmavoice_decode_init(), and wmavoice_flush().
defines quantizer defaults [0, 1]
Definition at line 160 of file wmavoice.c.
Referenced by synth_superframe(), and wmavoice_decode_init().
defines different sets of LSP defaults [0, 1]
Definition at line 161 of file wmavoice.c.
Referenced by synth_superframe(), and wmavoice_decode_init().
size (in bits) of LSPs, when encoded per-frame (independent coding)
Definition at line 163 of file wmavoice.c.
Referenced by check_bits_for_superframe(), and wmavoice_decode_init().
size (in bits) of LSPs, when encoded per superframe (residual coding)
Definition at line 165 of file wmavoice.c.
Referenced by check_bits_for_superframe(), and wmavoice_decode_init().
base value for pitch parsing code
Definition at line 168 of file wmavoice.c.
Referenced by kalman_smoothen(), synth_frame(), and wmavoice_decode_init().
max value + 1 for pitch parsing
Definition at line 169 of file wmavoice.c.
Referenced by kalman_smoothen(), synth_frame(), and wmavoice_decode_init().
number of bits used to specify the pitch value in the frame header
Definition at line 170 of file wmavoice.c.
Referenced by check_bits_for_superframe(), synth_frame(), and wmavoice_decode_init().
number of bits used to specify the first block's pitch value
Definition at line 172 of file wmavoice.c.
Referenced by check_bits_for_superframe(), synth_frame(), and wmavoice_decode_init().
range of the block pitch
Definition at line 174 of file wmavoice.c.
Referenced by synth_frame(), and wmavoice_decode_init().
number of bits used to specify the delta pitch between this and the last block's pitch value, used in all but first block
Definition at line 175 of file wmavoice.c.
Referenced by check_bits_for_superframe(), synth_frame(), and wmavoice_decode_init().
1/2 range of the delta (full range is from -this to +this-1)
Definition at line 179 of file wmavoice.c.
Referenced by synth_frame(), and wmavoice_decode_init().
boundaries for block pitch unit/scale conversion
Definition at line 181 of file wmavoice.c.
Referenced by synth_frame(), and wmavoice_decode_init().
number of bits of the previous packet's last superframe preceding this packet's first full superframe (useful for re-synchronization also)
Definition at line 193 of file wmavoice.c.
Referenced by parse_packet_header(), and wmavoice_decode_packet().
if set, superframes contain one set of LSPs that cover all frames, encoded as independent and residual LSPs; if not set, each frame contains its own, fully independent, LSPs
Definition at line 197 of file wmavoice.c.
Referenced by check_bits_for_superframe(), parse_packet_header(), and synth_superframe().
number of bits to skip at the next call to wmavoice_decode_packet() (since they're part of the previous superframe)
Definition at line 202 of file wmavoice.c.
Referenced by wmavoice_decode_packet(), and wmavoice_flush().
cache for superframe data split over multiple packets
Definition at line 206 of file wmavoice.c.
Referenced by synth_superframe(), and wmavoice_decode_packet().
set to >0 if we have data from an (incomplete) superframe from a previous packet that spilled over in the current packet; specifies the amount of bits in sframe_cache
Definition at line 209 of file wmavoice.c.
Referenced by synth_superframe(), wmavoice_decode_packet(), and wmavoice_flush().
bitstream writer for sframe_cache
Definition at line 214 of file wmavoice.c.
Referenced by wmavoice_decode_packet().
LSPs of the last frame of the previous superframe.
Definition at line 225 of file wmavoice.c.
Referenced by synth_superframe(), wmavoice_decode_init(), and wmavoice_flush().
pitch value of the previous frame
Definition at line 227 of file wmavoice.c.
Referenced by synth_block_fcb_acb(), synth_frame(), and wmavoice_decode_init().
frame type [0-2] of the previous frame
Definition at line 228 of file wmavoice.c.
Referenced by synth_frame(), and wmavoice_decode_init().
((cur_pitch_val - last_pitch_val) << 16) / MAX_FRAMESIZE
Definition at line 229 of file wmavoice.c.
Referenced by synth_block_fcb_acb(), and synth_frame().
set for use in blocks if ACB_TYPE_NONE
Definition at line 231 of file wmavoice.c.
Referenced by synth_block_fcb_acb(), synth_block_hardcoded(), and synth_frame().
whether the AW index was encoded in 8 bits (instead of 6)
Definition at line 233 of file wmavoice.c.
Referenced by aw_parse_coords(), and aw_pulse_set1().
the range over which aw_pulse_set1() can apply the pulse, relative to the value in aw_first_pulse_off.
The exact position of the first AW-pulse is within [pulse_off, pulse_off + this], and depends on bitstream values; [16 or 24]
Definition at line 235 of file wmavoice.c.
Referenced by aw_parse_coords(), aw_pulse_set1(), and aw_pulse_set2().
number of AW-pulses in each block; note that this number can be negative (in which case it basically means "zero")
Definition at line 241 of file wmavoice.c.
Referenced by aw_parse_coords(), aw_pulse_set1(), and aw_pulse_set2().
index of first sample to which to apply AW-pulses, or -0xff if unset
Definition at line 244 of file wmavoice.c.
Referenced by aw_parse_coords(), aw_pulse_set1(), and aw_pulse_set2().
the position (relative to start of the second block) at which pulses should start to be positioned, serves as a cache for pitch-adaptive window pulses between blocks
Definition at line 246 of file wmavoice.c.
Referenced by aw_pulse_set2().
current frame index [0 - 0xFFFE]; is only used for comfort noise in pRNG()
Definition at line 252 of file wmavoice.c.
Referenced by synth_block_fcb_acb(), synth_block_hardcoded(), and synth_frame().
cache for gain prediction
Definition at line 254 of file wmavoice.c.
Referenced by synth_block_fcb_acb(), synth_block_hardcoded(), and wmavoice_flush().
cache of the signal of previous superframes, used as a history for signal generation
Definition at line 255 of file wmavoice.c.
Referenced by synth_superframe(), and wmavoice_flush().
Definition at line 259 of file wmavoice.c.
Referenced by synth_superframe(), and wmavoice_flush().
Definition at line 269 of file wmavoice.c.
Referenced by calc_input_response(), wiener_denoise(), wmavoice_decode_end(), and wmavoice_decode_init().
contexts for FFT-calculation in the postfilter (for denoise filter)
Definition at line 269 of file wmavoice.c.
Referenced by calc_input_response(), wiener_denoise(), wmavoice_decode_end(), and wmavoice_decode_init().
Definition at line 271 of file wmavoice.c.
Referenced by calc_input_response(), wmavoice_decode_end(), and wmavoice_decode_init().
contexts for phase shift (in Hilbert transform, part of postfilter)
Definition at line 271 of file wmavoice.c.
Referenced by calc_input_response(), wmavoice_decode_end(), and wmavoice_decode_init().
Definition at line 273 of file wmavoice.c.
Referenced by calc_input_response(), and wmavoice_decode_init().
8-bit cosine/sine windows over [-pi,pi] range
Definition at line 273 of file wmavoice.c.
Referenced by calc_input_response(), and wmavoice_decode_init().
gain control memory, used in adaptive_gain_control()
Definition at line 275 of file wmavoice.c.
Referenced by postfilter(), and wmavoice_flush().
DC filter history.
Definition at line 277 of file wmavoice.c.
Referenced by postfilter(), and wmavoice_flush().
zero filter output (i.e.
excitation) by postfilter
Definition at line 278 of file wmavoice.c.
Referenced by synth_frame(), synth_superframe(), and wmavoice_flush().
Definition at line 281 of file wmavoice.c.
Referenced by wiener_denoise(), and wmavoice_flush().
samples in denoise_filter_cache
Definition at line 282 of file wmavoice.c.
Referenced by wiener_denoise().
aligned buffer for LPC tilting
Definition at line 283 of file wmavoice.c.
Referenced by wiener_denoise().
aligned buffer for denoise coefficients
Definition at line 285 of file wmavoice.c.
Referenced by wiener_denoise().
aligned buffer for postfilter speech synthesis
Definition at line 287 of file wmavoice.c.
Referenced by postfilter(), and wmavoice_flush().