Newer versions of C++/WinRT have changed the way coroutine support is handled. I've already had to put together at least one workaround for Win32CaptureSample.
The other header that needs to be fixed is imaging, since it (sloppily) uses std::future to return a winrt::com_ptr. Replacing this will also solve the issue of burning a thread for each of those calls. Unfortunately, IAsyncOperation only works for WinRT interfaces, and not for interfaces that only inherit from IUnknown.
Newer versions of C++/WinRT have changed the way coroutine support is handled. I've already had to put together at least one workaround for Win32CaptureSample.
The other header that needs to be fixed is imaging, since it (sloppily) uses std::future to return a winrt::com_ptr. Replacing this will also solve the issue of burning a thread for each of those calls. Unfortunately, IAsyncOperation only works for WinRT interfaces, and not for interfaces that only inherit from IUnknown.
Related: https://github.com/robmikh/Win32CaptureSample/issues/67