[vlc-commits] [Git][videolan/vlc][master] demux: adaptive: always restart if declared fourcc differs

Jean-Baptiste Kempf gitlab at videolan.org
Thu Jun 17 08:13:49 UTC 2021



Jean-Baptiste Kempf pushed to branch master at VideoLAN / VLC


Commits:
0657b84e by Francois Cartegnie at 2021-06-17T06:43:51+00:00
demux: adaptive: always restart if declared fourcc differs

es_format_IsSimilar compares tranlated fourcc, ending matching AVC1 &
H264

avcodec then truncates NAL and glitches hard from wrong format

refs #25606

- - - - -


1 changed file:

- modules/demux/adaptive/plumbing/FakeESOutID.cpp


Changes:

=====================================
modules/demux/adaptive/plumbing/FakeESOutID.cpp
=====================================
@@ -82,11 +82,11 @@ const es_format_t *FakeESOutID::getFmt() const
 
 bool FakeESOutID::isCompatible( const FakeESOutID *p_other ) const
 {
-    if( p_other->fmt.i_cat != fmt.i_cat )
+    if( p_other->fmt.i_cat != fmt.i_cat ||
+        fmt.i_codec != p_other->fmt.i_codec ||
+        fmt.i_original_fourcc != p_other->fmt.i_original_fourcc )
         return false;
 
-    if(fmt.i_original_fourcc != p_other->fmt.i_original_fourcc)
-        return false;
     if((fmt.i_extra > 0) ^ (p_other->fmt.i_extra > 0))
         return false;
 
@@ -101,8 +101,7 @@ bool FakeESOutID::isCompatible( const FakeESOutID *p_other ) const
         case VLC_CODEC_VC1:
         case VLC_CODEC_AV1:
         {
-            if(fmt.i_codec == p_other->fmt.i_codec &&
-               fmt.i_extra && p_other->fmt.i_extra &&
+            if(fmt.i_extra && p_other->fmt.i_extra &&
                fmt.i_extra == p_other->fmt.i_extra)
             {
                return !!memcmp(fmt.p_extra, p_other->fmt.p_extra, fmt.i_extra);



View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/0657b84ec8d64b07b80eeafd8512f8fd32dc55ea

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/0657b84ec8d64b07b80eeafd8512f8fd32dc55ea
You're receiving this email because of your account on code.videolan.org.




More information about the vlc-commits mailing list