5

I'm using aubio to analyse an audio file, but when I try to use the function new_aubio_source like this:

let source = new_aubio_source(StringToUnsafeMutablePointerChar_t(url.absoluteString), 0, 512)

I always get these errors.

AUBIO ERROR: source_apple_audio: Failed opening file:///var/mobile/Containers/Data/Application/C11B42E5-02B5-4373-8302-0728B2CB2296/Documents/music.m4a, error in ExtAudioFileOpenURL ('wht?')
AUBIO ERROR: source_wavread: Failed opening file:///var/mobile/Containers/Data/Application/C11B42E5-02B5-4373-8302-0728B2CB2296/Documents/music.m4a (System error: No such file or directory)
AUBIO ERROR: source: failed creating aubio source with file:///var/mobile/Containers/Data/Application/C11B42E5-02B5-4373-8302-0728B2CB2296/Documents/music.m4a at samplerate 0 with hop_size 512

I am 100% sure that the path is correct, but I just can't find out why these errors occur. I think the problem is in the first error message (source_apple_audio).

source_apple_audio is defined here:

source_apple_audio

which used this function: ExtAudioFileOpenURL, and got the error code ('wht?')

Thank you very much for your help!

desperado
  • 213
  • 1
  • 11
  • 2
    Although the question is quite old, the path of a file system url is `url.path` rather than `url.absoluteString`. – vadian Jan 09 '17 at 11:28

1 Answers1

3

Do you also have this problem when removing the leading file:// ?

Please open a new issue.

piem
  • 390
  • 2
  • 11