[Ffmpeg-devel] retrieving asf textual info in other languages

?? c_liao
Tue May 17 12:35:52 CEST 2005


----- Original Message ----- 
From: "M?ns Rullg?rd" <mru at inprovide.com>
To: "FFMpeg development discussions and patches" <ffmpeg-devel at mplayerhq.hu>
Sent: Tuesday, May 17, 2005 6:02 PM
Subject: Re: [Ffmpeg-devel] retrieving asf textual info in other languages


Hauke Duden <H.NS.Duden at gmx.net> writes:

> M?ns Rullg?rd wrote:
>
>>Hauke Duden <H.NS.Duden at gmx.net> writes:
>>
>>
>>
>>>Sorry to intrude here, but UTF-8 is very simple. Why not simply
>>>convert it yourself? Below is a simple striaghtforward encode routine
>>>from unicode char to UTF-8, if you need one. Since UCS-2 is a subset
>>>of Unicode this should work for it as well  Use it as you like.
>>
>>This doesn't deal with nasty things like surrogate pairs.
>
> UCS-2 has no surrogate pairs. It is a fixed 2-byte encoding (which
> does not cover the whole Unicode charset). I guess you're thinking
> about UTF-16.

Right.  I keep confusing all the different terms used.

> If you wanted to handle that then the easiest approach would be do
> first decode the UTF-16 chars into plain Unicode and then re-encode
> them as UTF-8.

Yes, converting between the different utf encodings is simpler than
doing arbitrary conversions (sjis, anyone?).

I did a little catching up with these stuffs of UCS and UTF too. I assumed 
previously based on some simple tests the encoding used within asf file is 
UCS2, but since microsoft's internal representation is UTF-16, so I can no 
longer hold that assumption, anyone want to give a hand here? and sorry for 
the misinformation earlier.

Cheng Liao 





More information about the ffmpeg-devel mailing list