]> git.sesse.net Git - vlc/commitdiff
Support for webm/mkv and VP8 inside it
authorJean-Baptiste Kempf <jb@videolan.org>
Wed, 19 May 2010 16:28:25 +0000 (18:28 +0200)
committerJean-Baptiste Kempf <jb@videolan.org>
Wed, 19 May 2010 16:28:25 +0000 (18:28 +0200)
We now should wait for libvpx integration

modules/demux/mkv/demux.cpp
modules/demux/mkv/matroska_segment.cpp

index 848eecca9fd923e041f25051075d54e0a6bd1282..c5f47a6a49847136e6e8644b49b8a8245c176392 100644 (file)
@@ -66,7 +66,7 @@ matroska_stream_c *demux_sys_t::AnalyseAllSegmentsFound( demux_t *p_demux, EbmlS
     p_l0->Read(*p_estream, EbmlHead::ClassInfos.Context, i_upper_lvl, p_l0, true);
 
     EDocType doc_type = GetChild<EDocType>(*static_cast<EbmlHead*>(p_l0));
-    if (std::string(doc_type) != "matroska")
+    if (std::string(doc_type) != "matroska" && std::string(doc_type) != "webm" )
     {
         msg_Err( p_demux, "Not a Matroska file : DocType = %s ", std::string(doc_type).c_str());
         return NULL;
index 2a7d0853a24aeae41620aa3ba5c951f5bd502f46..6153183cf68f133255161d41fb11df269c268b3a 100644 (file)
@@ -858,6 +858,10 @@ bool matroska_segment_c::Select( mtime_t i_start_time )
         {
             tracks[i_track]->fmt.i_codec = VLC_CODEC_DIRAC;
         }
+        else if( !strncmp( tracks[i_track]->psz_codec, "V_VP8", 5 ) )
+        {
+            tracks[i_track]->fmt.i_codec = VLC_CODEC_VP8;
+        }
         else if( !strncmp( tracks[i_track]->psz_codec, "V_MPEG4", 7 ) )
         {
             if( !strcmp( tracks[i_track]->psz_codec, "V_MPEG4/MS/V3" ) )