?
Solved

How to get correct installed directX version?

Posted on 2013-10-22
3
Medium Priority
?
846 Views
Last Modified: 2013-11-06
Dear experts,

I need to find installed directX version by source code.
I read this question already http://www.experts-exchange.com/Programming/Game/Q_26747833.html

I use [HKEY_LOCAL_MACHINE\Software\Microsoft\DirectX] registry.
But it seems not correct for DirectX 11:
-  My system uses Windows 8
-  I use dxdiag, it show [DirectX Version: DirectX 11]
-  But [Version] key in [HKEY_LOCAL_MACHINE\Software\Microsoft\DirectX] is "4.09.00.0904"

So, please help me the way for getting the correct installed directX in system.

Regards,
0
Comment
Question by:FSOFT-SA
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 29

Assisted Solution

by:chilternPC
chilternPC earned 500 total points
ID: 39590555
Check out this note:
http://msdn.microsoft.com/en-us/library/windows/desktop/ms724451%28v=vs.85%29.aspx

it says - may be altered or unavailable for releases after Windows 8.1.

You can use the D3D11 API. When you initialize D3D11, you can specify and/or query for the feature levels supported. You could  just attempt to initialize D3D10 and see if it fails.
0
 
LVL 63

Accepted Solution

by:
☠ MASQ ☠ earned 500 total points
ID: 39590665
From DX 10 Microsoft stopped using the registry to store the version number - you can still quiz that location if you think the system has 9.0c or older but you'll need to decode the output string.

From DX10 onward the version is held in dxgi.dll (dxv.xml) and this is where DXDiag pulls the info from.

Programmatically (insert disclaimer here - I am not a programmer!) it seems it's difficult to extract it directly into anything usable.

The API for the D3D helper suggested above is a good compromise and includes source code for C++
0
 
LVL 63

Expert Comment

by:☠ MASQ ☠
ID: 39627065
Thanks for closing this - sorry you felt the quality of the answer deserved the lowest grade available to you.

Without feedback from you though it is difficult to help you further.
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction This article is a continuation of the C/C++ Visual Studio Express debugger series. Part 1 provided a quick start guide in using the debugger. Part 2 focused on additional topics in breakpoints. As your assignments become a little more …
Basic understanding on "OO- Object Orientation" is needed for designing a logical solution to solve a problem. Basic OOAD is a prerequisite for a coder to ensure that they follow the basic design of OO. This would help developers to understand the b…
The goal of the video will be to teach the user the concept of local variables and scope. An example of a locally defined variable will be given as well as an explanation of what scope is in C++. The local variable and concept of scope will be relat…
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question