summaryrefslogtreecommitdiffstats
path: root/sub_cc.c
diff options
context:
space:
mode:
authorreimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2>2010-11-08 20:09:02 +0000
committerUoti Urpala <uau@glyph.nonexistent.invalid>2010-11-14 12:23:56 +0200
commitba0fef3f06ae9aea03b64ac2a260aadf8ed1324f (patch)
treea31921657364de174063dce5f167b57282372269 /sub_cc.c
parent41e04522af62fe0140da71d4fac9088c052c4d87 (diff)
downloadmpv-ba0fef3f06ae9aea03b64ac2a260aadf8ed1324f.tar.bz2
mpv-ba0fef3f06ae9aea03b64ac2a260aadf8ed1324f.tar.xz
sub_cc: modify parsing to fix problem with one sample
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32609 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'sub_cc.c')
-rw-r--r--sub_cc.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/sub_cc.c b/sub_cc.c
index a83ac6944d..c64c2850a6 100644
--- a/sub_cc.c
+++ b/sub_cc.c
@@ -263,8 +263,9 @@ static void subcc_decode(unsigned char *inputbuffer, unsigned int inputlength)
* repeat
*
* 0xfe starts 2 byte sequence of unknown purpose. It might denote
- * field #2 in line 21 of the VBI. We'll ignore it for the
- * time being.
+ * field #2 in line 21 of the VBI.
+ * Treating it identical of 0xff fixes
+ * http://samples.mplayerhq.hu/MPEG-VOB/ClosedCaptions/Starship_Troopers.vob
*
* 0xff starts 2 byte EIA-608 sequence, field #1 in line 21 of the VBI.
* Followed by a 3-code triplet that starts either with 0xff or
@@ -308,10 +309,6 @@ static void subcc_decode(unsigned char *inputbuffer, unsigned int inputlength)
switch (cc_code) {
case 0xfe:
- /* expect 2 byte encoding (perhaps CC3, CC4?) */
- /* ignore for time being */
- break;
-
case 0xff:
odd_offset ^= 1;
if (odd_offset != selected_channel() >> 1)