]> git.sesse.net Git - vlc/commitdiff
* ./modules/demux/mpeg: DTS support.
authorJon Lech Johansen <jlj@videolan.org>
Sun, 9 Mar 2003 23:39:05 +0000 (23:39 +0000)
committerJon Lech Johansen <jlj@videolan.org>
Sun, 9 Mar 2003 23:39:05 +0000 (23:39 +0000)
include/input_ext-intf.h
modules/demux/mpeg/ps.c
modules/demux/mpeg/system.c

index 9ed9923b23c610560afeae86af2601bf33b12726..99e37b93c43085a1c3ff380c4ef44c14bbb6d316 100644 (file)
@@ -4,7 +4,7 @@
  * control the pace of reading.
  *****************************************************************************
  * Copyright (C) 1999, 2000 VideoLAN
- * $Id: input_ext-intf.h,v 1.85 2003/02/08 22:20:28 massiot Exp $
+ * $Id: input_ext-intf.h,v 1.86 2003/03/09 23:39:05 jlj Exp $
  *
  * Authors: Christophe Massiot <massiot@via.ecp.fr>
  *
@@ -33,6 +33,7 @@
 #define REQUESTED_MPEG         1
 #define REQUESTED_A52          2
 #define REQUESTED_LPCM         3
+#define REQUESTED_DTS          4
 #define REQUESTED_NOAUDIO    255
 
 #define OFFSETTOTIME_MAX_SIZE       10
index 28fe71fe8f649e405dc6545cd1b05a186ee8a108..dd5dd8c6582a0cce24a2ed80766a9b90a48c43b3 100644 (file)
@@ -2,7 +2,7 @@
  * ps.c : Program Stream input module for vlc
  *****************************************************************************
  * Copyright (C) 2000-2001 VideoLAN
- * $Id: ps.c,v 1.8 2003/03/03 14:19:09 massiot Exp $
+ * $Id: ps.c,v 1.9 2003/03/09 23:39:05 jlj Exp $
  *
  * Authors: Christophe Massiot <massiot@via.ecp.fr>
  *
@@ -223,6 +223,20 @@ static int Activate( vlc_object_t * p_this )
                         }
                         break;
 
+                    case VLC_FOURCC('d','t','s',' '):
+                    case VLC_FOURCC('d','t','s','b'):
+                        if( config_GetInt( p_input, "audio-channel" )
+                                == ((p_es->i_id & 0x700) >> 8) ||
+                           ( config_GetInt( p_input, "audio-channel" ) < 0
+                              && !((p_es->i_id & 0x700) >> 8) ) )
+                        switch( config_GetInt( p_input, "audio-type" ) )
+                        {
+                        case -1:
+                        case REQUESTED_DTS:
+                            input_SelectES( p_input, p_es );
+                        }
+                        break;
+
                     case VLC_FOURCC('a','5','2',' '):
                     case VLC_FOURCC('a','5','2','b'):
                         if( config_GetInt( p_input, "audio-channel" )
index e437eea15d621db2b06191b87daa1367f6d8c2ec..c49966cca927526e258b08ae44ee4889842c6e5b 100644 (file)
@@ -2,7 +2,7 @@
  * system.c: helper module for TS, PS and PES management
  *****************************************************************************
  * Copyright (C) 1998-2002 VideoLAN
- * $Id: system.c,v 1.10 2003/02/08 19:10:21 massiot Exp $
+ * $Id: system.c,v 1.11 2003/03/09 23:39:05 jlj Exp $
  *
  * Authors: Christophe Massiot <massiot@via.ecp.fr>
  *          Michel Lespinasse <walken@via.ecp.fr>
@@ -875,6 +875,24 @@ static es_descriptor_t * ParsePS( input_thread_t * p_input,
                         case REQUESTED_MPEG:
                             input_SelectES( p_input, p_es );
                         }
+#endif
+                    }
+                    else if( (i_id & 0xF8FF) == 0x88BD )
+                    {
+                        p_es->i_fourcc = VLC_FOURCC('d','t','s','b');
+                        p_es->i_cat = AUDIO_ES;
+#ifdef AUTO_SPAWN
+                        if( !p_input->stream.b_seekable )
+                        if( config_GetInt( p_input, "audio-channel" )
+                                == ((p_es->i_id & 0x700) >> 8) ||
+                            ( config_GetInt( p_input, "audio-channel" ) < 0
+                              && !((p_es->i_id & 0x700) >> 8)) )
+                        switch( config_GetInt( p_input, "audio-type" ) )
+                        {
+                        case -1:
+                        case REQUESTED_DTS:
+                            input_SelectES( p_input, p_es );
+                        }
 #endif
                     }
                     else if( (i_id & 0xF0FF) == 0x80BD )