[MPlayer-dev-eng] What's the use of '-unicode'?

Evgeniy Stepanov eugeni.stepanov at gmail.com
Tue Aug 22 02:43:29 CEST 2006


On Tuesday 22 August 2006 04:19, Gianluigi Tiesi wrote:
> On Mon, Aug 21, 2006 at 11:40:50AM +0200, Diego Biurrun wrote:
> > On Sat, Aug 19, 2006 at 03:49:18PM +0800, Zuxy Meng wrote:
> > > Seems that only the libvo/ staff makes use of sub_unicode, so even the
> > > user provides -unicode in the command line, his ucs-2 encoded
> > > subtitles won't be recognized by subread.c. So what's the point
> > > exactly is here? Do we support ucs-2 encoded subtitles anyway?
> > >
> > > We may need some clarification in documenting the usage of -unicode,
> > > -utf-8 and -subcp, too.
> >
> > Yes, this is definitely very confusing.  Anyone?
>
> I think that no all ucs-2 char can be converted to "one-char" utf-8
> iirc most foreign chars become 3-bytes utf-8, and doesn't fit in a
> 8-bit charset, mplayer should handle non ansi chars everwhere,
> but it's really a big work.

SUB: Could not determine file format
ENCA detected charset: UCS-2
LIBASS: added subtitle file: 2.ssa (7 styles, 9850 events)
SUB: Added subtitle file (1): 2.ssa

The first line here is from subreader. It failes trying to parse ucs-2 encoded 
file as a text file. On the other hand, libass reads the whole file to memory 
and converts it before parsing.

The same approach can be used in subreader with little effort.



More information about the MPlayer-dev-eng mailing list