--
v3: dxgi: Reset the back buffer index to zero on ResizeBuffers().
dxgi/tests: Test that ResizeBuffers() resets the back buffer index to zero.
dxgi: Always assume that a D3D12 swapchain always uses user images.
dxgi: Immediately error out when creating a D3D12 swapchain on a non-immediate queue.
dxgi/tests: Test that D3D12 swapchains can only be created on direct command queues.
https://gitlab.winehq.org/wine/wine/-/merge_requests/2296
On Tue Feb 28 12:09:51 2023 +0000, Brendan Shanks wrote:
> Thanks for this, I hadn't realized `IOPMCopyBatteryInfo` was so deprecated.
> Looking at [Chromium's use of
> `IOPSCopyPowerSources`](https://source.chromium.org/chromium/chromium/src/+/main:services/device/battery/battery_status_manager_mac.cc;drc=098756533733ea50b2dcb1c40d9a9e18d49febbe;l=127),
> they first check that the source is present and internal, which seems
> like a good idea.
I changed it so it it does similar checks to Chromium and uses the first power source that works (and removed the internal battery check on kIOPSTypeKey since that is always true in that case already)
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/2283#note_25736
On Mon Feb 27 20:50:31 2023 +0000, Brendan Shanks wrote:
> The documentation for all these keys says that the type is
> `kCFNumberIntType` (equivalent to SInt32, but it would be better to use
> the documented type)
Thanks, should be fixed now!
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/2283#note_25735
On Mon Feb 27 20:50:31 2023 +0000, Brendan Shanks wrote:
> You can `CFRelease(blob)` at this point, and then remove all the calls
> from later in the function
I believe it is still needed for `IOPSGetPowerSourceDescription`, but I released after it is no longer being called
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/2283#note_25734
The current implementation based on `IOPMCopyBatteryInfo` does not work (macOS 13.2, M2 Max, returns `kIOReturnUnsupported`) and is not recommended/supported by Apple:
> WARNING! IOPMCoyBatteryInfo is unsupported on ALL Intel CPU based systems. For PPC CPU based systems, it remains not recommended. For almost all purposes, developers should use the richer IOPowerSources API (with change notifications) instead of using IOPMCopyBatteryInfo. Keys to decipher IOPMCopyBatteryInfo's return CFArray exist in IOPM.h.
--
v8: ntdll: Use IOPowerSources API to fill battery info on macOS
https://gitlab.winehq.org/wine/wine/-/merge_requests/2283
--
v2: dxgi: Reset the back buffer index to zero on ResizeBuffers().
dxgi/tests: Test that ResizeBuffers() resets the back buffer index to zero.
dxgi: Always assume that a D3D12 swapchain always uses user images.
dxgi: Immediately error out when creating a D3D12 swapchain on a non-immediate queue.
dxgi/tests: Test that D3D12 swapchains can only be created on direct command queues.
https://gitlab.winehq.org/wine/wine/-/merge_requests/2296
It's probably worth pointing out that this has quite some potential for causing regressions in performance. swapchain_blit_gdi() is not fast, and ideally we'd work on reducing the number of cases where it's needed.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/2299#note_25724