changeset 5399:27b3ee661472 libavcodec

Update the dvdsub parser to be able to parse HD-DVD subtitle packets. Patch by: Ian Caulfield, ian caulfield & gmx at
author takis
date Tue, 24 Jul 2007 14:17:13 +0000
parents 392483301260
children 2433e0070455
files dvdsub_parser.c
diffstat 1 files changed, 2 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/dvdsub_parser.c	Tue Jul 24 13:05:28 2007 +0000
+++ b/dvdsub_parser.c	Tue Jul 24 14:17:13 2007 +0000
@@ -43,6 +43,8 @@
         if (buf_size < 2)
             return 0;
         pc->packet_len = AV_RB16(buf);
+        if (pc->packet_len == 0) /* HD-DVD subpicture packet */
+            pc->packet_len = AV_RB32(buf+2);
         av_freep(&pc->packet);
         pc->packet = av_malloc(pc->packet_len);
     }