diff options
| author | Marijn Suijten <marijn@traverseresearch.nl> | 2023-05-22 16:02:39 +0200 |
|---|---|---|
| committer | Charles Giessen <46324611+charles-lunarg@users.noreply.github.com> | 2023-05-22 12:26:14 -0600 |
| commit | 80b010b1e1b08c1f092fb2bfa337faadf8ea1ba3 (patch) | |
| tree | de810213ba3241c430257d9cb24a1cb8ebfa7cb9 | |
| parent | 695887a994ef9cc00a7aa3f9c00b31a56ea79534 (diff) | |
| download | usermoji-80b010b1e1b08c1f092fb2bfa337faadf8ea1ba3.tar.xz | |
vulkaninfo: Reduce NVIDIA quaternary version field to 6 bits
The tertiary version field is shifted 6 bits to the right, meaning there
are only 6 bits left to for the quaternary version field, not 10. See
also:
https://github.com/SaschaWillems/vulkan.gpuinfo.org/blob/1e6ca6e3c0763daabd6a101b860ab4354a07f5d3/functions.php#L305
| -rw-r--r-- | vulkaninfo/vulkaninfo.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/vulkaninfo/vulkaninfo.h b/vulkaninfo/vulkaninfo.h index 8f3ea926..81ad3e9e 100644 --- a/vulkaninfo/vulkaninfo.h +++ b/vulkaninfo/vulkaninfo.h @@ -1796,13 +1796,13 @@ struct AppGpu { if ((found_driver_props && driver_props.driverID == VK_DRIVER_ID_NVIDIA_PROPRIETARY) || (!found_driver_props && props.deviceID == 4318)) { return std::to_string((v >> 22) & 0x3ff) + "." + std::to_string((v >> 14) & 0x0ff) + "." + - std::to_string((v >> 6) & 0x0ff) + "." + std::to_string((v)&0x003ff); + std::to_string((v >> 6) & 0x0ff) + "." + std::to_string(v & 0x003f); } else if ((found_driver_props && driver_props.driverID == VK_DRIVER_ID_INTEL_PROPRIETARY_WINDOWS) #if defined(WIN32) || (!found_driver_props && props.deviceID == 0x8086) // only do the fallback check if running in windows #endif ) { - return std::to_string((v >> 14)) + "." + std::to_string((v)&0x3fff); + return std::to_string(v >> 14) + "." + std::to_string(v & 0x3fff); } else { // AMD uses the standard vulkan scheme return VulkanVersion(v).str(); |
