How can I use save() function with absolute path?

p5.js 0.4.15, OS X

I'm trying to save an audio file in a specific folder (using p5.SoundFile and save() function)

Neither of these options work: save(soundFile, "/tmp/tmp.wav"); save(soundFile, "\/tmp\/tmp.wav");

It looks like the save function automatically replaces foward slashes by dashes when saving to folder (all the files end up in ~/Download/-tmp-tmp.wav)

Any idea what I should do to solve this? Thank you! S.

Tagged:

Answers

  • Answer ✓

    Browsers don't allow anything to be saved to an arbitrary path! =;

Sign In or Register to comment.