Quantcast
Channel: GameDev.net
Viewing all articles
Browse latest Browse all 17925

how to know if CLSID_CColorConvertDMO supports hardware acceleration

$
0
0

So i created CLSID_CColorConvertDMO using:

IMediaObject pMediaObject;

pMediaObject.CoCreateInstance(CLSID_CColorConvertDMO);

Now I want to check if it will do that using Hardware (GPU) or not. If it will not do that using GPU then i do not want to use it. I read about MF_SA_D3D11_AWARE and on MFT_ENUM_HARDWARE_URL_Attribute They should tell if it is Hardware accelerated supported. But to check that I need access to IMFAttributes. So I tried this:

   IMFTransform* oIMFTransform = NULL;

   IMFAttributes* pAttributes = NULL;

   HRESULT  hr = pMediaObject->QueryInterface(IID_IMFTransform, (void**)&oIMFTransform);

   hr = oIMFTransform->GetAttributes(0, &pAttributes);

   if (SUCCEEDED(hr))

   {

       UINT32 …


Viewing all articles
Browse latest Browse all 17925

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>