Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fail gracefully if XAudio2_8.dll is not present. #9

Open
rhdunn opened this issue Jan 31, 2017 · 1 comment
Open

Fail gracefully if XAudio2_8.dll is not present. #9

rhdunn opened this issue Jan 31, 2017 · 1 comment

Comments

@rhdunn
Copy link
Owner

rhdunn commented Jan 31, 2017

Use LoadLibrary/GetProcAddress instead of linking to xaudio2.lib in create_xaudio2_object to support returning NULL if the XAudio2 DLL is not present.

See rhdunn/espeak#98.

References:

  1. https://msdn.microsoft.com/en-us/library/windows/desktop/ee415802(v=vs.85).aspx -- XAudio2 versions
  2. https://blogs.msdn.microsoft.com/chuckw/2012/04/02/xaudio2-and-windows-8/
@mse2
Copy link
Contributor

mse2 commented Mar 2, 2018

Another option is to use the waveOUT API which is available on older Windows versions too.
https://gitlab.com/mseide-msegui/pcaudiolib/blob/mse/src/waveout.c
https://gitlab.com/mseide-msegui/pcaudiolib/blob/mse/src/audio.c
It will be activated by the NO_XAUDIO2 define.
Binaries are here:
https://sourceforge.net/projects/mseuniverse/files/eSpeakNG/
rename "libespeak-ngwo.dll" to "libespeak-ng.dll" if you want to use it with "espeak-ng.exe".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants