Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Add three missing SAR values defined in the H.264 spec to H264Parser:…

…:aspectRatio() fixes incorrect display aspect ratio for some videos and recordings.
  • Loading branch information...
commit 0a56d7fe859df287437573f5035ca54cc1be19e8 1 parent 9b526cc
@stuartm stuartm authored
Showing with 12 additions and 0 deletions.
  1. +12 −0 mythtv/libs/libmythtv/mpeg/H264Parser.cpp
View
12 mythtv/libs/libmythtv/mpeg/H264Parser.cpp
@@ -1293,6 +1293,18 @@ uint H264Parser::aspectRatio(void) const
// 160:99
aspect *= 1.6161616161616161;
break;
+ case 14:
+ // 4:3
+ aspect *= 1.3333333333333333;
+ break;
+ case 15:
+ // 3:2
+ aspect *= 1.5;
+ break;
+ case 16:
+ // 2:1
+ aspect *= 2.0;
+ break;
case EXTENDED_SAR:
if (sar_height)
aspect *= sar_width / (double)sar_height;
Please sign in to comment.
Something went wrong with that request. Please try again.