Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do you get the version of the Windows video driver(s)?

On Windows, how can my user-mode program get the driver version number(s) for the video card(s) installed?

Programs like ATI's "Catalyst Control Center" can display this information to the user or include it automatically into bug reports. How do they get it?

I've been looking thru the PSDK documentation, and I can't find anything relevant.

Can a user program walk thru the database that Device Manager displays?
Is there an IOCTL call like getting disk drive geometry?
Is it in a (reliable) registry key?

like image 520
Die in Sente Avatar asked Oct 18 '25 16:10

Die in Sente


2 Answers

In PowerShell:

Get-WmiObject Win32_VideoController | format-table Name, Description,VideoProcessor,DriverVersion

The WMI objects are also available from any language that speaks COM or .Net.

ETA: You may wish to exclude records without a value for VideoProcessor, like the Live Mesh drivers. I did that by including |where {$_.VideoProcessor -ne $null } in the pipeline before the format command.

like image 121
JasonTrue Avatar answered Oct 21 '25 07:10

JasonTrue


I used "dxdiag /x output.xml", then get the video driver version by parsing "output.xml". dxdiag is slow, but it tells the one correct driver version..

I used python to do this job. Inspired by Jason's answer, I get the following code:

>>> import wmi
>>> c = wmi.WMI()
>>> for device in c.Win32_VideoController():
    if device.VideoProcessor:
        print device.DriverVersion
like image 35
Wang Dingwei Avatar answered Oct 21 '25 07:10

Wang Dingwei