Answer the question
In order to leave comments, you need to log in
How to get ID3 in correct encoding?
I use MediaMetadataRetriever to get tags, but Russian tags are sometimes in ISO-8859-1, which should be read when translated into Windows-1251, but this doesn’t happen for me and it displays hieroglyphs all the time
.
Must be: I want to be with you
String TEXT = META.extractMetadata( MediaMetadataRetriever.METADATA_KEY_TITLE );
new String( TEXT.getBytes( "ISO-8859-1" ), "Windows-1251" ); // Практически всегда выводит иероглифы
mp3file = new MP3File( FILE );
new String( mp3file.getID3v1Tag().getSongTitle().getBytes( "ISO-8859-1" ), "Windows-1251" ) // Выводит текст как надо, но иногда вместо кириллических символов проскальзывают латинские
Answer the question
In order to leave comments, you need to log in
This is the problem with the standard itself. Tags should always be in ISO-8859-1, but in reality they are usually in national encodings.
I think the best solution is to let the user choose their own encoding.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question