From: James S. <jst...@us...> - 2005-05-28 10:41:27
|
Update of /cvsroot/xine/xine-lib/src/libdts In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv16787 Modified Files: xine_decoder.c Log Message: Fix channel flag handling Index: xine_decoder.c =================================================================== RCS file: /cvsroot/xine/xine-lib/src/libdts/xine_decoder.c,v retrieving revision 1.60 retrieving revision 1.61 diff -u -r1.60 -r1.61 --- xine_decoder.c 16 Dec 2004 13:59:10 -0000 1.60 +++ xine_decoder.c 28 May 2005 10:41:17 -0000 1.61 @@ -1,5 +1,5 @@ /* - * Copyright (C) 2000-2004 the xine project + * Copyright (C) 2000-2005 the xine project * * This file is part of xine, a unix video player. * @@ -225,33 +225,33 @@ } } else { /* Software decode */ - int i, dts_flags; + int i, dts_output_flags; int16_t *int_samples = audio_buffer->mem; int number_of_dts_blocks; level_t level = 1.0; sample_t *samples; - this->have_lfe = this->dts_flags & DTS_LFE; - dts_flags = this->dts_flags_map[this->dts_flags & DTS_CHANNEL_MASK]; + dts_output_flags = this->dts_flags_map[this->dts_flags & DTS_CHANNEL_MASK]; + + if(dts_frame(this->dts_state, data_in, &dts_output_flags, &level, 0)) { + xprintf (this->stream->xine, XINE_VERBOSITY_DEBUG, "libdts: dts_frame error\n"); + return; + } + + this->have_lfe = dts_output_flags & DTS_LFE; if (this->have_lfe) if (this->audio_caps & AO_CAP_MODE_5_1CHANNEL) { output_mode = AO_CAP_MODE_5_1CHANNEL; - dts_flags |= DTS_LFE; } else if (this->audio_caps & AO_CAP_MODE_4_1CHANNEL) { output_mode = AO_CAP_MODE_4_1CHANNEL; - dts_flags |= DTS_LFE; } else { xprintf(this->stream->xine, XINE_VERBOSITY_DEBUG, "libdts: WHAT DO I DO!!!\n"); - output_mode = this->ao_flags_map[dts_flags & DTS_CHANNEL_MASK]; + output_mode = this->ao_flags_map[dts_output_flags & DTS_CHANNEL_MASK]; } else - output_mode = this->ao_flags_map[dts_flags & DTS_CHANNEL_MASK]; + output_mode = this->ao_flags_map[dts_output_flags & DTS_CHANNEL_MASK]; - if(dts_frame(this->dts_state, data_in, &dts_flags, &level, 0)) { - xprintf (this->stream->xine, XINE_VERBOSITY_DEBUG, "libdts: dts_frame error\n"); - return; - } if (!this->output_open) { this->output_open = (this->stream->audio_out->open (this->stream->audio_out, this->stream, this->bits_per_sample, |