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

No sound on Windows... #77

Open
moebiussurfing opened this issue Oct 24, 2022 · 0 comments
Open

No sound on Windows... #77

moebiussurfing opened this issue Oct 24, 2022 · 0 comments

Comments

@moebiussurfing
Copy link

moebiussurfing commented Oct 24, 2022

I am not getting audio when playing o Windows.
I tried to switch oF sound API to DirectSound as usual:

        ofSoundStream soundStream;

setupAudio()
{
	soundStream.printDeviceList();

	int bufferSize = 512;
	int sampleRate = 48000;

	auto deviceList = soundStream.getDeviceList(ofSoundDevice::Api::MS_DS);
	for each (auto d in deviceList)
	{
		cout << ofToString(d) << endl;
	}

	int i = 0; // select device
	
	ofSoundStreamSettings settings;
        settings.setApi(ofSoundDevice::Api::MS_WASAPI);
	settings.setOutDevice(deviceList[i]);
	settings.setOutListener(this);
	settings.sampleRate = sampleRate;
	settings.numOutputChannels = 2;
	settings.numInputChannels = 0;
	settings.bufferSize = bufferSize;

	soundStream.setup(settings);
}

Anybody knows if it should work or there's some known bug?

I must go to use a parallel sound player then?

Thanks.

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

1 participant