You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I tried your project, sorry for the delay. it doesn't crash for me, but the sound doesn't play, for some reason openfl finds that the asset exists and tries to load it, but fails to do so. I tried opening your sound in audacity, saving it as a new file and trying that, it also didn't work. I grabbed a sound from another project and tried that, it worked. I have no idea what's going on with that sound but lime says it exists but NativeCFFI.lime_audio_load_file(path, audioBuffer) returns null. This may be why it's crashing for you
in my case I used NativeCFFI.lime_audio_load_file, and it seemed specific to the .ogg file included in that project; this did not happen for other sound files I tried.
Seems like there should be a null check here, like so
varasset=symbol.library.getAsset(symbol.symbolName, type);
if (asset==null)
{
Log.error(type+" asset \""+id+"\" exists synchronously, but failed to load");
returnnull;
}
But ultimately I wonder why this sound can't be loaded
The text was updated successfully, but these errors were encountered:
I know almost nothing about this, but I can at least track down some relevant lines numbers.
If audio_load_file() returns null, then OGG::Decode() returned false. This can happen in one of two ways. The first of those refers to VorbisFile, which relies on ov_open_callbacks(), which calls a bunch of different functions in the same file and errors if any of them fail. The second relies on ov_info(), which can return null "in the case that the machine is not initialized." Pretty sure it's the first option, since that one depends heavily on the details of the ogg file.
Maybe it's fixable, but let's see if we can find a workaround. Try opening in Audacity and exporting as wav or mp3. Then open that file and export as ogg. This should force it to recreate the whole thing from scratch, hopefully no longer causing the bug.
If that doesn't work (or doesn't fit the user's workflow), it's also worth trying a newer version of the Ogg library by switching to 8.2.0-Dev. (This might require OpenFL 8.3.0-Dev, not sure.)
Try opening in Audacity and exporting as wav or mp3. Then open that file and export as ogg. This should force it to recreate the whole thing from scratch, hopefully no longer causing the bug.
Continued from: HaxeFlixel/flixel#2848
Project recreating the issue: https://github.com/lol4meh/flixelsoundtest
The issue is here: https://github.com/openfl/lime/blob/develop/src/lime/utils/Assets.hx#L122
symbol.library.getAsset(symbol.symbolName, type)
returns null even thoughsymbol.exists(type) && symbol.isLocal(type)
is true.in my case I used NativeCFFI.lime_audio_load_file, and it seemed specific to the .ogg file included in that project; this did not happen for other sound files I tried.
Seems like there should be a null check here, like so
But ultimately I wonder why this sound can't be loaded
The text was updated successfully, but these errors were encountered: