From: The M. M. M. <tm...@us...> - 2002-10-27 18:02:54
|
Update of /cvsroot/xine/xine-lib/src/liba52 In directory usw-pr-cvs1:/tmp/cvs-serv7099/liba52 Modified Files: xine_decoder.c Log Message: modified a52 decoder to support RealAudio dnet data Index: xine_decoder.c =================================================================== RCS file: /cvsroot/xine/xine-lib/src/liba52/xine_decoder.c,v retrieving revision 1.37 retrieving revision 1.38 diff -u -r1.37 -r1.38 --- xine_decoder.c 26 Oct 2002 02:35:13 -0000 1.37 +++ xine_decoder.c 27 Oct 2002 18:02:52 -0000 1.38 @@ -340,6 +340,19 @@ uint8_t *end = buf->content + buf->size; uint8_t byte; + /* swap byte pairs if this is RealAudio DNET data */ + if (buf->type == BUF_AUDIO_DNET) { + while (current != end) { + byte = *current++; + *(current - 1) = *current; + *current++ = byte; + } + + /* reset */ + current = buf->content; + end = buf->content + buf->size; + } + if (buf->pts) this->pts = buf->pts; @@ -609,7 +622,9 @@ static uint32_t audio_types[] = { - BUF_AUDIO_A52, 0 + BUF_AUDIO_A52, + BUF_AUDIO_DNET, + 0 }; static decoder_info_t dec_info_audio = { |