annotate DOCS/tech/subcp.txt @ 16784:7a6e909c223e

minor typo
author diego
date Mon, 17 Oct 2005 08:50:04 +0000
parents ef3af71f0113
children 0f1b5b68af32
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
6006
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
1 Ascii Subtitle / Font CODEPAGEs
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
2 ===============================
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
3
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
4 The subtitle encoding issue seems a bit confusing, so I'll try to
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
5 summarize it here.
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
6
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
7 There are 2 approaches:
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
8
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
9 1. (preferred) You can generate Unicode subtitles with:
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
10 subfont --unicode <signle-byte encoding known by iconv> ...
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
11 or
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
12 subfont --unicode <path to custom encoding file> ...
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
13 (this custom encoding file could list all iso-8859-* characters to create
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
14 single font file for common encodings)
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
15
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
16 and then run mplayer this way (-subcp and -utf8 expect Unicode font!):
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
17 mplayer -subcp <any encoding known by iconv> ...
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
18 or
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
19 mplayer -utf8 ...
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
20
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
21 2. (current) Generate subtitles for some specific encoding with:
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
22 subfont <signle-byte encoding known by iconv> ...
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
23 or
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
24 subfont <path to custom signle-byte or EUC encoding file> ...
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
25
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
26 and then run mplayer without any encoding options for signle-byte
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
27 encodings, or with -unicode option for EUC (and the like) encodings
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
28 (which is only partially implemented in mplayer).
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
29
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
30 AFAIK, CJK encodings: EUC-*, BIG5 and GB2312 work more or less this way:
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
31 - 0x8e (SINGLE-SHIFT TWO, SS2) begins a 2-byte character,
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
32 - 0x8f (SINGLE-SHIFT THREE, SS3) begins a 3-byte character,
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
33 - 0xa0-0xff begin 2-byte characters,
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
34 - other characters are single-byte.
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
35
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
36
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
37 I tested charmap2enc script only with /usr/share/i18n/charmaps/EUC-KR.gz
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
38 (on RedHat). It wasn't intended to be perfect.
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
39
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
40
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
41 --
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
42 Artur Zaprzala
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
43
ef3af71f0113 usefull dox
arpi
parents:
diff changeset
44