Page 1 of 1

Decomposed Encoding of Meta Information

Posted: Sat Mar 13, 2010 3:20 pm
by Horus

I've just noticed that Rip seems (in contrast to Max) use the decomposed form of unicode for the FLAC metatags. That seem to confuse some tools, for example metaflac

comment[0]: TITLE=Konig der Narren

should be "K├Ânig". Is this by design? I don't know if the spec gives information on how to handle that. Personally I consider decomposed the worse form of encoding umlauts and other letters with diacritics.


Re: Decomposed Encoding of Meta Information

Posted: Sat Mar 13, 2010 9:35 pm
by sbooth
Rip uses the flac command line executable to perform the actual FLAC encoding. This is a problem as you've noticed because all characters are not correctly passed to the shell. Right now this is a shortcoming in Rip, but the root cause of the problem is the way that Apple's NSTask works. Here is the documentation:
The NSTask object converts both path and the strings in arguments to appropriate C-style strings (using fileSystemRepresentation) before passing them to the task via argv[]) . The strings in arguments do not undergo shell expansion, so you do not need to do special quoting, and shell variables, such as $PWD, are not resolved.
I believe this can be worked around by saving the tags to a file, and telling flac the path to the file containing the tags.