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
13 changes: 10 additions & 3 deletions src/main/java/net/vulkanmod/vulkan/device/Device.java
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,15 @@ public Device(VkPhysicalDevice device) {
private static String decodeVendor(int i) {
return switch (i) {
case (0x10DE) -> "Nvidia";
case (0x1022) -> "AMD";
case (0x1022), (0x1002) -> "AMD"; // AMD has two deviceIds, apparently
case (0x8086) -> "Intel";
case (0x1010) -> "Imagination Technologies";
case (0x13B5) -> "ARM";
case (0x5143) -> "Qualcomm";
case (0x106B) -> "Apple";
case (0x14E4) -> "Broadcom";
case (0x1AE0) -> "Google"; // Not sure about this, SwiftShader devices have this id
case (0x10005) -> "Mesa"; // Honeykrisp on Apple devices has this vendorId for some reason
default -> "undef"; //Either AMD or Unknown Driver version/vendor and.or Encoding Scheme
};
}
Expand All @@ -90,7 +97,7 @@ static String decDefVersion(int v) {
private static String decodeDvrVersion(int v, int i) {
return switch (i) {
case (0x10DE) -> decodeNvidia(v); //Nvidia
case (0x1022) -> decDefVersion(v); //AMD
case (0x1022), (0x1002) -> decDefVersion(v); //AMD
case (0x8086) -> decIntelVersion(v); //Intel
default -> decDefVersion(v); //Either AMD or Unknown Driver Encoding Scheme
};
Expand Down Expand Up @@ -149,7 +156,7 @@ public boolean isDrawIndirectSupported() {
// Added these to allow detecting GPU vendor, to allow handling vendor specific circumstances:
// (e.g. such as in case we encounter a vendor specific driver bug)
public boolean isAMD() {
return vendorId == 0x1022;
return vendorId == 0x1022 || vendorId == 0x1002;
}

public boolean isNvidia() {
Expand Down