MegaGlest Forum

Archives (read only) => Vanilla Glest => Bug report => Topic started by: Alphaman1990 on 16 February 2009, 16:09:13

Title: Annoying error
Post by: Alphaman1990 on 16 February 2009, 16:09:13
I start a game normally and sometimes it will start, actually most times. but in the rare chance it will say (X) Error: unhandled exception  failed to lock direct sound buffer.

and because of this error if i do get in the game with no problems i will start a scenario, tutorial, custom game but maybe 5/7 minutes ( max ) later this error will pop up and i will not be able to continue my game.

please does anyone have awnsers for me?
Title: Re: Annoying error
Post by: hailstone on 17 February 2009, 01:42:30
I'm not sure how to fix it but I can provide some information.

The exception is thrown in shared_lib/sources/sound/ds8/sound_player_ds8.cpp , StrSoundBuffer::fillDsBuffer()

Some information on the method that failed: http://msdn.microsoft.com/en-us/library/ms897826.aspx

I think Glest should have also specified the error that is returned but doesn't, here are possible errors:
DSERR_BUFFERLOST     The buffer memory has been lost and must be restored.
DSERR_INVALIDCALL     This function is not valid for the current state of this object.
DSERR_INVALIDPARAM     An invalid parameter was passed to the returning function.
DSERR_PRIOLEVELNEEDED     The caller does not have the priority level required for the function to succeed.
Title: Re: Annoying error
Post by: martiƱo on 17 February 2009, 18:03:34
This is a know error. Update your sound card drivers, update to the latest directx and if needed disable sound hardware acceleration.
Title: Re: Annoying error
Post by: hailstone on 18 February 2009, 05:25:12
I did record this on the wiki but the FAQ page link was removed from the front page and I had forgotten.

https://docs.megaglest.org/FAQ