diff options
author | Diego 'Flameeyes' Pettenò <flameeyes@gmail.com> | 2007-12-13 19:38:53 +0100 |
---|---|---|
committer | Diego 'Flameeyes' Pettenò <flameeyes@gmail.com> | 2007-12-13 19:38:53 +0100 |
commit | 62743683e1d65889b2d0d996a763f74519a66cc0 (patch) | |
tree | 770e068eade04f0f4100bd1a96e10fd3dad58f6b | |
parent | db7b2f331d5bc140dfa062fae11b52bdd3583659 (diff) | |
download | xine-lib-62743683e1d65889b2d0d996a763f74519a66cc0.tar.gz xine-lib-62743683e1d65889b2d0d996a763f74519a66cc0.tar.bz2 |
Set stream information only when reading a streaminfo FLAC block.
-rw-r--r-- | src/combined/xine_ogg_demuxer.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/combined/xine_ogg_demuxer.c b/src/combined/xine_ogg_demuxer.c index 30a8789df..ff293ee00 100644 --- a/src/combined/xine_ogg_demuxer.c +++ b/src/combined/xine_ogg_demuxer.c @@ -1230,16 +1230,17 @@ static void decode_flac_header (demux_ogg_t *this, const int stream_num, ogg_pac case FLAC_BLOCKTYPE_STREAMINFO: _x_assert(header.length == FLAC_STREAMINFO_SIZE); _x_parse_flac_streaminfo_block(&op->packet[17], &streaminfo); + + _x_stream_info_set(this->stream, XINE_STREAM_INFO_AUDIO_SAMPLERATE, streaminfo.samplerate); + _x_stream_info_set(this->stream, XINE_STREAM_INFO_AUDIO_CHANNELS, streaminfo.channels); + _x_stream_info_set(this->stream, XINE_STREAM_INFO_AUDIO_BITS, streaminfo.bits_per_sample); + break; } this->si[stream_num]->buf_types = BUF_AUDIO_FLAC +this->num_audio_streams++; - _x_stream_info_set(this->stream, XINE_STREAM_INFO_AUDIO_SAMPLERATE, streaminfo.samplerate); - _x_stream_info_set(this->stream, XINE_STREAM_INFO_AUDIO_CHANNELS, streaminfo.channels); - _x_stream_info_set(this->stream, XINE_STREAM_INFO_AUDIO_BITS, streaminfo.bits_per_sample); - this->si[stream_num]->factor = 90000; buf = this->audio_fifo->buffer_pool_alloc(this->audio_fifo); |