开发者

File not found error with FMOD FMOD_OUTPUTTYPE_WAVWRITER_NRT

开发者 https://www.devze.com 2023-04-10 20:21 出处:网络
i\'m trying to run FMOD in WAVWRITER_NRT mode. I was modifying the example bundled with FMOD, but I always get an error on FMOD_System_Init. It says that the file cannot be found.

i'm trying to run FMOD in WAVWRITER_NRT mode. I was modifying the example bundled with FMOD, but I always get an error on FMOD_System_Init. It says that the file cannot be found.

I thought it would create a file to write output to. I have also tried placing开发者_运维百科 a wav file with that name into that location. Still, I always have this error.

Here is the code:

result = FMOD_System_Create(&gSystem);
CHECK_RESULT(result);

result = FMOD_System_SetOutput(gSystem, FMOD_OUTPUTTYPE_WAVWRITER_NRT);
CHECK_RESULT(result);

result = FMOD_System_Init(gSystem, 4, FMOD_INIT_NORMAL, "/sdcard/fmod/out.wav");
CHECK_RESULT(result);

result = FMOD_System_CreateSound(gSystem, "/sdcard/fmod/test1.mp3", FMOD_CREATESTREAM, 0, &gSound);
CHECK_RESULT(result);

Please help!


Add WRITE_EXTERNAL_STORAGE permission to the manifest.

0

精彩评论

暂无评论...
验证码 换一张
取 消