diff options
author | Guenter Bartsch <guenter@users.sourceforge.net> | 2002-12-06 23:40:26 +0000 |
---|---|---|
committer | Guenter Bartsch <guenter@users.sourceforge.net> | 2002-12-06 23:40:26 +0000 |
commit | 6467ce298a109183ba051b10e4be620c8b59e2bf (patch) | |
tree | d584ee8bd37eb4a0cb952162def623b8c2bf37b7 /src/libreal/xine_decoder.c | |
parent | ba79b3caec8390efc4ca1192f129e8de9fd72902 (diff) | |
download | xine-lib-6467ce298a109183ba051b10e4be620c8b59e2bf.tar.gz xine-lib-6467ce298a109183ba051b10e4be620c8b59e2bf.tar.bz2 |
real bugfixes, improved discontinuity/live stream handling, handling of audio-only streams - still experimental
CVS patchset: 3453
CVS date: 2002/12/06 23:40:26
Diffstat (limited to 'src/libreal/xine_decoder.c')
-rw-r--r-- | src/libreal/xine_decoder.c | 28 |
1 files changed, 19 insertions, 9 deletions
diff --git a/src/libreal/xine_decoder.c b/src/libreal/xine_decoder.c index 838e7b7a2..9db45e6e0 100644 --- a/src/libreal/xine_decoder.c +++ b/src/libreal/xine_decoder.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: xine_decoder.c,v 1.10 2002/12/06 01:44:06 miguelfreitas Exp $ + * $Id: xine_decoder.c,v 1.11 2002/12/06 23:40:26 guenter Exp $ * * thin layer to use real binary-only codecs in xine * @@ -204,9 +204,12 @@ static int init_codec (realdec_decoder_t *this, buf_element_t *buf) { init_data.format = BE_32(&buf->content[30]); #ifdef LOG + printf ("libreal: init_data for rvyuv_init:\n"); hexdump (&init_data, sizeof (init_data)); + printf ("libreal: buf->content\n"); hexdump (buf->content, 32); + printf ("libreal: extrahdr\n"); hexdump (extrahdr, 10); printf ("libreal: init codec %dx%d... %x %x\n", @@ -328,6 +331,10 @@ static void realdec_decode_data (video_decoder_t *this_gen, buf_element_t *buf) transform_out, this->context); +#ifdef LOG + printf ("libreal: transform result: %d\n", result); +#endif + xine_fast_memcpy (img->base[0], this->frame_buffer, this->frame_size); xine_fast_memcpy (img->base[1], this->frame_buffer+this->frame_size, this->frame_size/4); @@ -365,16 +372,19 @@ static void realdec_decode_data (video_decoder_t *this_gen, buf_element_t *buf) printf ("libreal: another fragment (%d chunks in buffer)\n", this->num_chunks); #endif - - memcpy (this->chunk_buffer+this->chunk_buffer_size, buf->content, buf->size); - this->chunk_tab[2*this->num_chunks] = 1; - this->chunk_tab[2*this->num_chunks+1] = this->chunk_buffer_size; - this->num_chunks++; - this->chunk_buffer_size += buf->size; + if ( (buf->content[0] & 0x20) == 0) { - if (buf->pts) - this->pts = buf->pts; + memcpy (this->chunk_buffer+this->chunk_buffer_size, buf->content, buf->size); + + this->chunk_tab[2*this->num_chunks] = 1; + this->chunk_tab[2*this->num_chunks+1] = this->chunk_buffer_size; + this->num_chunks++; + this->chunk_buffer_size += buf->size; + + if (buf->pts) + this->pts = buf->pts; + } } } |