ap4y / OrigamiEngine

Lightweight audio engine for iOS and OSX with flac, cue, mp3, m4a, m3u support.
http://ap4y.github.com/OrigamiEngine/
MIT License
545 stars 118 forks source link

a mp3 file can not play #42

Closed hament closed 9 years ago

hament commented 9 years ago

i have a mp3 file can not play,when i debug the frame work ,i do not know why the function below OSStatus result = AudioFileOpenWithCallbacks(_source, audioFile_ReadProc, NULL, // audioFile_GetSizeProc, NULL, 0, // &_audioFile);

will always error in coreaudiodecoder.m file;

However i replace it with : result = AudioFileOpenURL((__bridge CFURLRef) [source url], kAudioFileReadPermission, 0, &_audioFile);

the mp3 file can play luckly! maybe it cause can not read the metadata of the file ,but ok , I use tablib to read the id3 tag.

The OrigamiEngine framework is Good. By the way , the framework can support ogg file next version?

ap4y commented 9 years ago

Hey @hament can you send me a file to check what can be wrong?

Regarding ogg, it is possible to add support for this format. Please create a new issue for this feature request and I will see what I can do once I have some time.

hament commented 9 years ago

ok, here is the problem mp3 file link: https://drive.google.com/file/d/0BzjdbbgYruNbZWFjaENsRExKRGM/view?usp=sharing

ap4y commented 9 years ago

This file has invalid id3v2 tag size, see issue #37. You can check it yourself, by removing 417 bytes starting from offset 1294, after this file will work.