This commit is contained in:
Yukino Song
2025-05-26 17:33:00 +08:00
parent 1e71cc0662
commit 542c4e315b
8 changed files with 93 additions and 24 deletions

View File

@@ -4,6 +4,7 @@
*/
#define INITGUID
#include "src/utility.h"
#include "utils.h"
#include <audioclient.h>
#include <codecvt>
@@ -46,8 +47,6 @@ namespace audio {
using handle_t = util::safe_ptr_v2<void, BOOL, CloseHandle>;
static std::wstring_convert<std::codecvt_utf8_utf16<wchar_t>, wchar_t> converter;
class prop_var_t {
public:
prop_var_t() {
@@ -206,7 +205,7 @@ namespace audio {
// so we can take the first match as the current format to display.
auto audio_client = make_audio_client(device, format);
if (audio_client) {
current_format = converter.from_bytes(format.name.data());
current_format = from_utf8(format.name);
break;
}
}