You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* fix array lookup
* calculate pixel aspect ratio from display aspect ratios
* delay calc of aspect ratio until after extended size is known
* mirror the updated pixel aspect ratio up to the 'video' section
Fixes remaining issues with #148
Copy file name to clipboardexpand all lines: src/Module/AudioVideo/Mpeg.php
+19-10
Original file line number
Diff line number
Diff line change
@@ -152,12 +152,6 @@ public function Analyze() {
152
152
case0xB5: // extension_start_code
153
153
$info['video']['codec'] = 'MPEG-2';
154
154
155
-
if (isset($info['mpeg']['video']['raw']['aspect_ratio_information'])) {
156
-
// MPEG-2 defines the aspect ratio flag differently from MPEG-1, but the MPEG-2 extension start code may occur after we've already looked up the aspect ratio assuming it was MPEG-1, so re-lookup assuming MPEG-2
if (isset($info['mpeg']['video']['raw']['aspect_ratio_information'])) {
181
+
// MPEG-2 defines the aspect ratio flag differently from MPEG-1, but the MPEG-2 extension start code may occur after we've already looked up the aspect ratio assuming it was MPEG-1, so re-lookup assuming MPEG-2
182
+
// This must be done after the extended size is known, so the display aspect ratios can be converted to pixel aspect ratios.
0 commit comments