Does DirectX9 define something to differentiate versions at preprocessor?

StackOverflow https://stackoverflow.com/questions/22926778

  •  29-06-2023
  •  | 
  •  

سؤال

As Visual Studio defined _MSC_VER, 1700 stands for VS2012 while 1800 stands for VS2013.

Does DirectX9 define something to differentiate between (December 2004) and (June 2010)?

هل كانت مفيدة؟

المحلول

Not sure, but I guess that D3D_SDK_VERSION and D3DX_SDK_VERSION defines is that you are looking for. At least in this example it's used to check a runtime vs. build versions:

HRESULT CD3DXMyApplication::Initialize(HINSTANCE hInstance, 
  LPCSTR szWindowName, LPCSTR szClassName, UINT uWidth, UINT uHeight)
{
    HRESULT hr;

    if (!D3DXCheckVersion(D3D_SDK_VERSION, D3DX_SDK_VERSION))
        return E_FAIL;

    //...
}
مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top