IMFDXGIBuffer interface not found

iz111 86 Reputation points
2020-08-17T10:17:23.413+00:00

IMFDXGIBuffer interface is missing on Windows Server 2016.
I have installed "Media Foundation" feature, but the problem still exists. Also latest DirectX is installed..

What could cause this issue?

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,656 questions
C++
C++
A high-level, general-purpose programming language, created as an extension of the C programming language, that has object-oriented, generic, and functional features in addition to facilities for low-level memory manipulation.
3,764 questions
{count} votes

Accepted answer
  1. Rita Han - MSFT 2,166 Reputation points
    2020-08-20T08:35:23.703+00:00

    Hello,

    IMFDXGIBuffer interface not found

    Make sure you create this interface in right way like this: first create the DXGIsurface. Then call MFCreateDXGISurfaceBuffer. MFCreateDXGISurfaceBuffer returns IMFMediaBuffer object support IMFDXGIBuffer interface.

    You can use this official sample: DXGIDesktopDuplication with the following edition to check if you can query IMFDXGIBuffer successfully:

    After this line: hr = CopyBuffer->QueryInterface(__uuidof(IDXGISurface), (void **)&CopySurface); add the following code piece:

     IMFMediaBuffer* mediaBuf;  
         hr = MFCreateDXGISurfaceBuffer(__uuidof(ID3D11Texture2D), CopySurface, 0, TRUE, &mediaBuf);  
         IMFDXGIBuffer* dxgiBuf;  
         hr = mediaBuf->QueryInterface(__uuidof(IMFDXGIBuffer), (void**)& dxgiBuf);  
    

    Thank you!

    1 person found this answer helpful.
    0 comments No comments

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.