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

Allow application to set ALSA devices manually #4133

Merged
merged 3 commits into from
Nov 7, 2024
Merged

Conversation

nanangizz
Copy link
Member

Currently the library will automatically enumerate ALSA devices. However, application may want to have access to the subdevices. The new API pjmedia_aud_alsa_set_devices() will allow application to manually set custom ALSA devices, e.g:

#include<pjmedia-audiodev/alsa.h>
...
// Set ALSA devices manually
const char* custom_dev_names[] = {"dev1", "dev2"};
status = pjmedia_aud_alsa_set_devices(NULL, 2, custom_dev_names);

// Let the driver to enumerate the devices
status = pjmedia_aud_alsa_set_devices(NULL, 0, NULL);

@nanangizz nanangizz merged commit b209c98 into master Nov 7, 2024
36 checks passed
@nanangizz nanangizz deleted the alsa-custom-dev branch November 7, 2024 03:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants