mirror of
https://github.com/doitsujin/dxvk.git
synced 2025-01-18 20:52:10 +01:00
[dxvk] Provide way to access queue properties from device
This commit is contained in:
parent
1c39765b86
commit
191bba660b
@ -60,7 +60,7 @@ namespace dxvk {
|
||||
VkQueue* pQueue,
|
||||
uint32_t* pQueueFamilyIndex) {
|
||||
auto device = static_cast<D3D11Device*>(m_device)->GetDXVKDevice();
|
||||
DxvkDeviceQueue queue = device->graphicsQueue();
|
||||
DxvkDeviceQueue queue = device->queues().graphics;
|
||||
|
||||
if (pQueue != nullptr)
|
||||
*pQueue = queue.queueHandle;
|
||||
|
@ -330,7 +330,7 @@ namespace dxvk {
|
||||
|
||||
|
||||
void D3D11SwapChain::CreatePresenter() {
|
||||
DxvkDeviceQueue graphicsQueue = m_device->graphicsQueue();
|
||||
DxvkDeviceQueue graphicsQueue = m_device->queues().graphics;
|
||||
|
||||
vk::PresenterDevice presenterDevice;
|
||||
presenterDevice.queueFamily = graphicsQueue.queueFamily;
|
||||
|
@ -111,14 +111,23 @@ namespace dxvk {
|
||||
}
|
||||
|
||||
/**
|
||||
* \brief Graphics queue properties
|
||||
* \brief Queue handles
|
||||
*
|
||||
* Handle and queue family index of
|
||||
* the queue used for rendering.
|
||||
* \returns Graphics queue info
|
||||
* Handles and queue family indices
|
||||
* of all known device queues.
|
||||
* \returns Device queue infos
|
||||
*/
|
||||
DxvkDeviceQueue graphicsQueue() const {
|
||||
return m_queues.graphics;
|
||||
const DxvkDeviceQueueSet& queues() const {
|
||||
return m_queues;
|
||||
}
|
||||
|
||||
/**
|
||||
* \brief Tests whether a dedicated transfer queue is available
|
||||
* \returns \c true if an SDMA queue is supported by the device
|
||||
*/
|
||||
bool hasDedicatedTransferQueue() const {
|
||||
return m_queues.transfer.queueHandle
|
||||
!= m_queues.graphics.queueHandle;
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
x
Reference in New Issue
Block a user