Click here to Skip to main content
15,891,951 members
Please Sign up or sign in to vote.
2.00/5 (2 votes)
See more:
I want to capture video using Media Foundation transform library.
I have used

C++
HRESULT hr = S_OK;
D3D_FEATURE_LEVEL FeatureLevel;
ID3D11DeviceContext* pDX11DeviceContext;

hr = CreateDX11Device(&g_pDX11Device, &pDX11DeviceContext, &FeatureLevel);

if (SUCCEEDED(hr))
{
    hr = MFCreateDXGIDeviceManager(&g_ResetToken, &g_pDXGIMan);
}



On building the vcpp application I received error:
unresolved external symbol MFCreateDXGIDeviceManagerv

For this, I used

C++
<pre lang="cs">#pragma comment(lib, "mf") // For MFEnumDevices
#pragma comment(lib, "mfplat")
#pragma comment(lib, "mfreadwrite")
#pragma comment(lib, "dxva2")
#pragma comment(lib, "d3d11")
#pragma comment(lib, "mfuuid")</pre>
Posted
Updated 13-Oct-14 2:48am
v2

You could had google it: MFCreateDXGIDeviceManager needs Mfplat.lib to be included.

...
 
Share this answer
 
Thanks KarstenK
I googled it and included Mfplat.lib but it didnt work.
 
Share this answer
 
Solved issue. I need to add path in Library directory in project properties under VC++ Directories section.
 
Share this answer
 
v3

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900