Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -111,8 +111,10 @@ bool isDeviceSuitable(vk::raii::PhysicalDevice const & physicalDevice)
Instead of just checking if a device is suitable or not and going with the first
one, you could also give each device a score and pick the highest one. That way
you could favor a dedicated graphics card by giving it a higher score, but fall
back to an integrated GPU if that's the only available one. You could implement
something like that as follows:
back to an integrated GPU if that's the only available one. This needs a
`std::multimap` to keep the candidates sorted by score as we go, so that means a
new header at the top of the file. You could implement something like that as
follows:

[,c++]
----
Expand Down
Loading