Occasional crash on starting

I recently updated to the devel Panda3d version to fix that manifoldpoint bug in Bullet, and have run into a problem. Occasionally, the game will crash when I start it with the following output:

Known pipe types:
  wglGraphicsPipe
(all display modules loaded.)
AL lib: MMDevApiOpenPlayback: Device init failed: 0x80004005
:audio(error): OpenALAudioManager: alcOpenDevice(NULL): ALC couldn't open device

:audio(error): OpenALAudioManager: No open device or context

I’m not sure, but I think it happens even when I don’t try to start any audio modules. It’s kind of hard to test because it only happens sometimes.

Hi, I posted about this issue in the 1.8.1 release thread. Do you use an external sound card? I get that exact crash unless I have my external sound card (Edirol UA-101) on while panda is running. For me it’s not random: off always equals crash; on always works.

I don’t have any sound cards.

Still I’m guessing that this is related to some (internal) audio setting that is perhaps getting changed by other applications in between your uses of Panda. Either way I’m pretty sure this is a bug in the 1.8.1 build and not something on your end.

I upgraded the OpenALSoft version for 1.8.1. I’ll have to contact the guy who wrote it.

Can you guys try removing OpenAL32.dll from C:/Panda3D-1.8.1/bin and then renaming soft_oal.dll to OpenAL32.dll, and see if that fixes the issue?

Also, please try putting “notify-level-audio debug” in Config.prc and tell me what it says about the ALC_ and AL_ parameters when it’s not crashing.

I couldn’t find any file named “soft_oal.dll” in bin. This is the “notify-level-audio-debug” output when my soundcard is on and it’s not crashing:

:audio(debug): create_AudioManager()
  audio_library_name="p3openal_audio"
:audio(debug):   dl_name="libp3openal_audio.so"
:audio(debug): symbol of get_audio_manager_func_openal_audio = 09641C50
:audio(debug): Create_OpenALAudioManager()
:audio(debug): ALC_DEVICE_SPECIFIER:OpenAL Soft
:audio(debug): AL_RENDERER:OpenAL Soft
:audio(debug): AL_VENDOR:OpenAL Community
:audio(debug): AL_VERSION:1.1 ALSOFT 1.14
:audio(debug): create_AudioManager()
  audio_library_name="p3openal_audio"
:audio(debug): Create_OpenALAudioManager()
:audio(debug): ALC_DEVICE_SPECIFIER:OpenAL Soft
:audio(debug): AL_RENDERER:OpenAL Soft
:audio(debug): AL_VENDOR:OpenAL Community
:audio(debug): AL_VERSION:1.1 ALSOFT 1.14

I can’t find soft_oal.dll either. This is the output when it doesn’t crash.

Known pipe types:
  wglGraphicsPipe
(all display modules loaded.)
:audio(debug): create_AudioManager()
  audio_library_name="p3openal_audio"
:audio(debug):   dl_name="libp3openal_audio.so"
:audio(debug): symbol of get_audio_manager_func_openal_audio = 093C1C50
:audio(debug): Create_OpenALAudioManager()
:audio(debug): ALC_DEVICE_SPECIFIER:OpenAL Soft
:audio(debug): AL_RENDERER:OpenAL Soft
:audio(debug): AL_VENDOR:OpenAL Community
:audio(debug): AL_VERSION:1.1 ALSOFT 1.14
:audio(debug): create_AudioManager()
  audio_library_name="p3openal_audio"
:audio(debug): Create_OpenALAudioManager()
:audio(debug): ALC_DEVICE_SPECIFIER:OpenAL Soft
:audio(debug): AL_RENDERER:OpenAL Soft
:audio(debug): AL_VENDOR:OpenAL Community
:audio(debug): AL_VERSION:1.1 ALSOFT 1.14

Really? Hmm, looks like I messed up somewhere then. What happens if you download OpenAL Soft from here:
openal-soft.org/openal-soft-1.15.1-bin.zip
And replace OpenAL32.dll in the Panda3D bin directory with the 32-bits soft_oal.dll from OpenAL Soft?

This fixed the problem for me.

Edit: Actually, it didn’t seem to fix the issue. I must have just had a good run.

Well, here is the OpenAL that should have been in 1.8.1: (simply extract in the ‘bin’ directory)
rdb.name/openal-bin.zip

But if you say that even overwriting OpenAL32.dll with soft_oal.dll didn’t work, then perhaps there is something different that’s going on. My only other guess is that you have a different OpenAL32.dll somewhere on your system and it’s sometimes getting chosen before our version.

It changes the behavior. By now, I have this message:

:audio(error):   load_dso(libp3openal_audio.so) failed, will use NullAudioManager
:audio(error):     Not a valid Win32 application

OK, this issue was twofold: (1) bug in Open AL Soft, and (2) poor handling in Panda of audio errors, causing the crash.
The bug in OpenAL Soft seems to be fixed in OpenAL Soft 1.16, and the poor handling in Panda has been fixed as well.

Tried openAL 1.16 but still get the same error.

You mean you downloaded the soft_oal.dll from the site, renamed it to OpenAL32.dll, and put it in Panda3D’s “bin” directory?

Or did you just put “soft.oal.dll” in the “bin” directory?

Renamed soft_oal.dll to OpenAL32.dll copied it to bin directory.I started getting this error only after I switched to windows 8.1.Used to work perfectly in xp sp3.

Hi.

I just installed Panda3D 1.8.1 on a Windows7 machine & I got the same error as described above …
Can someone tell me if I should fix this by downloading & renaming that library from the previous posts ?

Thanks !

Yes, it’d be great if you could try that. Rename soft_oal.dll to OpenAL32.dll, replacing the previous version of OpenAL32.dll in the bin directory.