When playing a song I get an exception (with code 0x80004002 which, according the SharpDX, means an Interface doesnt’ exist but I assume actually means the audio interface isn’t ready) in MediaPlayer.WMS.cs in the code
try
{
MediaFactory.GetService(_session, MRPolicyVolumeService, SimpleAudioVolumeGuid, out volumeObj);
}
catch
{
MediaFactory.GetService(_session, MRPolicyVolumeService, SimpleAudioVolumeGuid, out volumeObj);
}
Confused at first why the try and catch would have the same code I come to the conclusion that the first call spun on the service and a failure is expected and the catch is hoping that some async task has completed in time. On Windows at least, this doesn’t work.
I’m just starting to dig into this issue and stumbled upon this older thread. with a hacked work around that will block the main thread but eventually gets the job done. I want to avoid something like this though.
Is this currently a known issue that is being worked on (and I should work on something else in the meantime) or is this worth digging into and solving?