17
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-10-17 01:39:20 +02:00

Merge branch 'master' into feat/modern-editor

This commit is contained in:
2026-10-08 17:44:58 +02:00
41 changed files with 479 additions and 319 deletions

View File

@@ -573,15 +573,12 @@ openal_renderer::init_caps() {
if( ::alcIsExtensionPresent( nullptr, "ALC_ENUMERATION_EXT" ) == AL_TRUE ) {
// enumeration supported
WriteLog( "available audio devices:" );
auto const *devices { ::alcGetString( nullptr, ALC_DEVICE_SPECIFIER ) };
auto const
*device { devices },
*next { devices + 1 };
while( device && *device != '\0' && next && *next != '\0' ) {
WriteLog( { device } );
auto const len { std::strlen( device ) };
device += len + 1;
next += len + 2;
// device list is a sequence of null-terminated names, ending with an empty name
auto const *device { ::alcGetString( nullptr, ALC_DEVICE_SPECIFIER ) };
while( device != nullptr && *device != '\0' ) {
std::string const devicename { device };
WriteLog( devicename );
device += devicename.size() + 1;
}
}