Filter all H.246 high profile codecs v1.2.0
authorChristian Weiske <cweiske@cweiske.de>
Wed, 14 Dec 2022 21:22:32 +0000 (22:22 +0100)
committerChristian Weiske <cweiske@cweiske.de>
Wed, 14 Dec 2022 21:22:32 +0000 (22:22 +0100)
.. instead of hard-coding the list

www/functions.php

index 3e4e2beeeda9aa1d8c9fe76e27bc294f595d3bd0..ca64ed566a1b5da800dba18ea5a30bded0feab89 100644 (file)
@@ -118,6 +118,10 @@ function extractVideoUrlFromJson($json)
             //dreambox 7080hd does not play VP9 video streams
             continue;
         }
+        if (strtolower(substr($format->vcodec, 0, 6)) == 'avc1.6') {
+            //dreambox DM7080 does not play H.264 High Profile
+            continue;
+        }
         if ($format->protocol == 'http_dash_segments') {
             //split up into multiple small files
             continue;
@@ -139,6 +143,7 @@ function extractVideoUrlFromJson($json)
         return ($b->quality ?? 0) - ($a->quality ?? 0);
     });
     foreach ($safeFormats as $format) {
+        //echo $format->format . ' | ' . $format->vcodec . ' | ' . $format->acodec . "\n";
         $url = $format->url;
         break;
     }