Closed Saancreed closed 2 weeks ago
Changed it a bit, now there are separate methods with overloads for IUnknown
which is presumed to be some kind of ID3D1[12]Device
and ID3D12CommandQueue
where appropriate instead of a single one that blindly tries to handle both, which should limit the amount of weird DXVK and vkd3d-proton logs about unsupported QueryInterface
calls.
This lets us avoid having to
QueryInterface
on every call toNvAPI_D3D12_SetAsyncFrameMarker
. The consequence of doing it like this is that now there might be multiple entries inm_lowLatencyDeviceMap
pointing to the sameID3DLowLatencyDevice
so in order to still correctly have a single frame ID generator perID3DLowLatencyDevice
, their map is now keyed on low latency devices which we have to retrieve on every call anyway.We could further reduce the lookups if we either returned intermediate
ID3DLowLatencyDevice
fromSupportsLowLatency
and then acted on it in the following call or if we just got rid of explicitSupportsLowLatency
and had methods likeSetFrameMarker
returned more detailed error codes (or justNvAPI_Status
directly). But that's an idea for another day.