Lines Matching defs:substr

235                                           unsigned int substr, unsigned int ch)
237 SubStream *s = &m->substream[substr];
256 unsigned int substr, unsigned int pos)
258 SubStream *s = &m->substream[substr];
295 int substr;
298 for (substr = 0; substr < MAX_SUBSTREAMS; substr++)
299 m->substream[substr].lossless_check_data = 0xffffffff;
323 int substr, ret;
405 for (substr = 0; substr < MAX_SUBSTREAMS; substr++)
406 m->substream[substr].restart_seen = 0;
418 if ((substr = (mh.num_substreams > 1)))
420 m->substream[substr].mask = mh.channel_layout_mlp;
432 if ((substr = (mh.num_substreams > 1)))
443 m->substream[substr].mask == AV_CH_LAYOUT_MONO && m->max_decoded_substream == 1) {
467 for (substr = 0; substr < MAX_SUBSTREAMS; substr++)
468 m->substream[substr].matrix_encoding = AV_MATRIX_ENCODING_NONE;
503 const uint8_t *buf, unsigned int substr)
505 SubStream *s = &m->substream[substr];
572 m->max_decoded_substream > substr) {
576 s->max_channel + 1, s->mask, substr);
577 m->max_decoded_substream = substr;
587 if (substr == m->max_decoded_substream
646 if (substr == m->max_decoded_substream) {
675 unsigned int substr, unsigned int channel,
678 SubStream *s = &m->substream[substr];
749 static int read_matrix_params(MLPDecodeContext *m, unsigned int substr, GetBitContext *gbp)
751 SubStream *s = &m->substream[substr];
817 static int read_channel_params(MLPDecodeContext *m, unsigned int substr,
820 SubStream *s = &m->substream[substr];
828 if ((ret = read_filter_params(m, gbp, substr, ch, FIR)) < 0)
833 if ((ret = read_filter_params(m, gbp, substr, ch, IIR)) < 0)
875 unsigned int substr)
877 SubStream *s = &m->substream[substr];
898 if ((ret = read_matrix_params(m, substr, gbp)) < 0)
910 if (substr == m->max_decoded_substream)
928 if ((ret = read_channel_params(m, substr, gbp, ch)) < 0)
946 cp->sign_huff_offset = calculate_sign_huff(m, substr, ch);
957 static void filter_channel(MLPDecodeContext *m, unsigned int substr,
960 SubStream *s = &m->substream[substr];
985 unsigned int substr)
987 SubStream *s = &m->substream[substr];
1007 if ((ret = read_huff_channels(m, gbp, substr, i)) < 0)
1011 filter_channel(m, substr, ch);
1055 static void generate_2_noise_channels(MLPDecodeContext *m, unsigned int substr)
1057 SubStream *s = &m->substream[substr];
1075 static void fill_noise_buffer(MLPDecodeContext *m, unsigned int substr)
1077 SubStream *s = &m->substream[substr];
1092 static int output_data(MLPDecodeContext *m, unsigned int substr,
1096 SubStream *s = &m->substream[substr];
1114 generate_2_noise_channels(m, substr);
1117 fill_noise_buffer(m, substr);
1174 unsigned int length, substr;
1210 for (substr = 0; substr < m->num_substreams; substr++) {
1244 "packet.\n", substr);
1252 substr);
1256 if (substr > m->max_decoded_substream)
1259 substream_parity_present[substr] = checkdata_present;
1260 substream_data_len[substr] = end - substream_start;
1274 for (substr = 0; substr <= m->max_decoded_substream; substr++) {
1275 SubStream *s = &m->substream[substr];
1277 if (substr != m->max_decoded_substream &&
1282 init_get_bits(&gb, buf, substream_data_len[substr] * 8);
1292 if (read_restart_header(m, &gb, buf, substr) < 0)
1299 if (read_decoding_params(m, &gb, substr) < 0)
1306 if ((ret = read_block_data(m, &gb, substr)) < 0)
1309 if (get_bits_count(&gb) >= substream_data_len[substr] * 8)
1316 if (substream_data_len[substr] * 8 - get_bits_count(&gb) >= 32) {
1332 if (substream_parity_present[substr]) {
1335 if (substream_data_len[substr] * 8 - get_bits_count(&gb) != 16)
1338 parity = ff_mlp_calculate_parity(buf, substream_data_len[substr] - 2);
1339 checksum = ff_mlp_checksum8 (buf, substream_data_len[substr] - 2);
1342 av_log(m->avctx, AV_LOG_ERROR, "Substream %d parity check failed.\n", substr);
1344 av_log(m->avctx, AV_LOG_ERROR, "Substream %d checksum failed.\n" , substr);
1347 if (substream_data_len[substr] * 8 != get_bits_count(&gb))
1353 "No restart header present in substream %d.\n", substr);
1356 buf += substream_data_len[substr];
1362 for (substr = 0; substr <= m->max_decoded_substream; substr++){
1363 SubStream *s = &m->substream[substr];
1375 av_log(m->avctx, AV_LOG_ERROR, "substream %d length mismatch\n", substr);
1388 for (int substr = 0; substr <= m->max_decoded_substream; substr++){
1389 SubStream *s = &m->substream[substr];