Skip to content

Commit

Permalink
Also detect 3D controllers
Browse files Browse the repository at this point in the history
  • Loading branch information
gertjaap committed Feb 26, 2020
1 parent 5f6062b commit 0667ca0
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions util/gpus.go
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,11 @@ func GetGPUs() []GPU {
if vgaIdx > -1 {
gpus = append(gpus, l[vgaIdx+27:])
}

vgaIdx = strings.Index(l, "3D controller: ")
if vgaIdx > -1 {
gpus = append(gpus, l[vgaIdx+15:])
}
}
} else if runtime.GOOS == "darwin" {
Info := exec.Command("system_profiler", "SPDisplaysDataType")
Expand Down

0 comments on commit 0667ca0

Please sign in to comment.