Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[d3d9] Add device import interop API #4506

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

AlpyneDreams
Copy link
Contributor

As requested by @doitsujin in #4497, I have added an API to import existing Vulkan devices. Here is an example of how it could be used to add an async compute queue when creating the device. First, all device creation info is queried with GetDeviceCreateInfo, then the device is created in userspace and passed to ImportDevice. I have tested this and can confirm that it works. Feedback or nits are welcomed!

@WinterSnowfall
Copy link
Contributor

@AlpyneDreams Not sure if you saw it, but there's a warning that's probably worth fixing:

../../../src/d3d9/d3d9_interop.cpp: In member function ‘virtual HRESULT dxvk::D3D9VkInteropInterface::GetDeviceCreateInfo(UINT, D3D9VkDeviceCreateInfo**)’:
Warning: ../../../src/d3d9/d3d9_interop.cpp:92:23: warning: comparison of integer expressions of different signedness: ‘int’ and ‘const size_t’ {aka ‘const unsigned int’} [-Wsign-compare]
   92 |     for (int i = 0; i < queueCount; i++) {
      |                     ~~^~~~~~~~~~~~

@AlpyneDreams
Copy link
Contributor Author

@WinterSnowfall Thanks, fixed!

@AlpyneDreams
Copy link
Contributor Author

Rebased.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants