lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: UTF-8 in MIDI Lyrics


From: karl
Subject: Re: UTF-8 in MIDI Lyrics
Date: Sat, 25 Feb 2017 21:06:24 +0100 (CET)

Joseph Austin:
> > From: Karl Hammar <address@hidden <mailto:address@hidden>>
...
> >> But if we are going to use a "private standard", we might as well
> >> imitate the "official" standard and insert something like
> >> FF 05 07 { @ U T F 8 }
> >> And lobby AMEI/MMA to adopt an official UTF8 position.
> > 
> > Could be good, but why just not capitalize on the BOM and just use
> > utf8.
...
> OK, the UTF-8 BOM is 0x EF BB BF
> But given that the MIDI file is not a "text file" but a binary
> file with text fields scattered throughout,
> normally embedded in various MIDI Meta-events, where should the BOM
> be placed?
> 
> Interpreting your suggestion, we could add a Lyric Meta-Event with
> the BOM as the text field to Track 0 Time 0.  
> That should work for lyrics, but RP-26 indicates that lyrics
> "language encoding" should not extend to other types of text events.
> For other text events, it seems we would need to prefix every UTF-8
> text field with the BOM.

Unfortunately midi-file standard and rp26 doesn't help you with that.
The only fallback we have is the notice that you can use extended
charset, but you have to check that programs at the other end of the
pipe does something reasonable with it.

And all this boils down to how do programs out there interpret any
extended char, do they support utf8 BOM, do they support rp26 ?
Well, I don't know.

>From reading rp26, it only talks about latin (latin-1 I assume),
ms-kanji and utf16* (which has the boms "FFFE", "FEFF"), so I don't
think we can expect anything more. Utf16 points to MS-Windows, what
programs makes midi files on that os, how to they do it ?

Soo in the end, I think we should just use utf8 and wait and see if
any bug reports comes in about it.

But as you suggest, we could talk to the midi assosiation to amend
the standard. The easiest would be if they replaced the word "ascii"
with "utf8".

Regards,
/Karl Hammar

-----------------------------------------------------------------------
Asp� Data
Lilla Asp� 148
S-742 94 �sthammar
Sweden
+46 173 140 57





reply via email to

[Prev in Thread] Current Thread [Next in Thread]