From 2e2a391ae932dd72a6b499f63bbfab93eaf32752 Mon Sep 17 00:00:00 2001 From: j <0x006A@0x2620.org> Date: Tue, 19 Apr 2011 15:42:04 +0200 Subject: [PATCH] more format workarounds in avinfo --- ox/file.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ox/file.py b/ox/file.py index cecf87e..1d3e2ef 100644 --- a/ox/file.py +++ b/ox/file.py @@ -74,7 +74,7 @@ def avinfo(filename): info = json.loads(info) if 'video' in info: for v in info['video']: - if not 'display_aspect_ratio' in v: + if not 'display_aspect_ratio' in v and 'width' in v: v['display_aspect_ratio'] = '%d:%d' % (v['width'], v['height']) v['pixel_aspect_ratio'] = '1:1' return info