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

Audio optimize & default input/output bugfix #2038

Merged
merged 3 commits into from Mar 30, 2024
Merged

Conversation

mxi-box
Copy link
Contributor

@mxi-box mxi-box commented Mar 30, 2024

Makes every AudioDeviceInfo singleton to reduce QAudioDeviceInfo calls. frequently calling WASAPI enumerate when startup will lead to crash on my PC... not really know why but it's an optimization anyway.

Fix things about m_defaultInputStarted and m_defaultOutputStarted. It creates default devices multiple times, causing totally broken and noncontinuous audio.

@f4exb f4exb merged commit aa95a5b into f4exb:master Mar 30, 2024
2 of 3 checks passed
@srcejon
Copy link
Collaborator

srcejon commented Mar 30, 2024

Is this going to prevent new audio devices from being discovered after the initial enumeration?

@mxi-box
Copy link
Contributor Author

mxi-box commented Mar 30, 2024

Is this going to prevent new audio devices from being discovered after the initial enumeration?

As far as Im concerned, there's no way to refresh the device list before. The AudioSelectDialog uses the cached list of AudioDeviceManager, which is not refreshable.
Implementing this feature also involve reindex audio device IDs

@srcejon
Copy link
Collaborator

srcejon commented Mar 30, 2024

As far as Im concerned, there's no way to refresh the device list before.

Yeah.

The problem with this, is the audio devices can change at runtime. For example, on Windows when you connect via RDP. It would be useful to be able to refresh the audio devices so audio can be redirected to the client.

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

Successfully merging this pull request may close these issues.

None yet

3 participants