File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -299,7 +299,7 @@ namespace dxvk {
299299 * and general troubleshooting.
300300 */
301301 void logAdapterInfo () const ;
302-
302+
303303 /* *
304304 * \brief Checks whether this is a UMA system
305305 *
@@ -308,9 +308,19 @@ namespace dxvk {
308308 * \returns \c true if the system has unified memory.
309309 */
310310 bool isUnifiedMemoryArchitecture () const ;
311-
312311
313312 // NV-DXVK start: Device filtering
313+
314+ /* *
315+ * \brief Checks whether a device extension is supported
316+ *
317+ * \param [in] pName Extension name
318+ * \returns \c true if the extension is supported
319+ */
320+ bool supportsExtension (const char * pName) const {
321+ return m_deviceExtensions.supports (pName) != 0 ;
322+ }
323+
314324 /* *
315325 * \brief Checks if adapter is emulated
316326 *
Original file line number Diff line number Diff line change @@ -910,7 +910,20 @@ namespace dxvk {
910910 if (b->deviceProperties ().deviceType == deviceTypes[i]) bRank = i;
911911 }
912912
913- return aRank < bRank;
913+ if (aRank != bRank)
914+ return aRank < bRank;
915+
916+ // Among adapters of the same device type, prefer ones that support
917+ // ray tracing extensions required by RTX Remix.
918+ const bool aSupportsRT = a->supportsExtension (VK_KHR_RAY_QUERY_EXTENSION_NAME )
919+ && a->supportsExtension (VK_KHR_ACCELERATION_STRUCTURE_EXTENSION_NAME );
920+ const bool bSupportsRT = b->supportsExtension (VK_KHR_RAY_QUERY_EXTENSION_NAME )
921+ && b->supportsExtension (VK_KHR_ACCELERATION_STRUCTURE_EXTENSION_NAME );
922+
923+ if (aSupportsRT != bSupportsRT)
924+ return aSupportsRT;
925+
926+ return false ;
914927 });
915928
916929 if (result.size () == 0 ) {
You can’t perform that action at this time.
0 commit comments