Visual Studio 2008标头路径问题

时间:2011-05-25 13:21:12

标签: visual-studio-2008 windows-7 multimedia

  

可能重复:
  Visual Studio 2008 header path problem

大家好, 我在我的电脑上安装了Windows 7和visual studio 2008。还有两个v6.0和v7.1的Windows SDK。我正在尝试使用Microsoft Media Foundation创建一个小应用程序,但发现编译错误,即使我添加了所有需要的头文件。我包含在项目中的所有头文件都来自以下路径

c:\ program files \ microsoft sdks \ windows \ v7.1 \ include \

还添加了库, c:\ program files \ microsoft sdks \ windows \ v7.1 \ Lib \

虽然我添加了上面的libs和头文件,如果我尝试编译我从这里下载的程序(http://msdn.microsoft.com/en-us/library/ff728866(v=VS.85).aspx),我会遇到以下错误,

1>------ Build started: Project: Media_Session_Sample, Configuration: Debug Win32 ------
1>Linking...
1>   Creating library D:\DCS\Microsoft_Media_Foundation\Media_Session_Sample\Debug    
\Media_Session_Sample.lib and object D:\DCS\Microsoft_Media_Foundation\Media_Session_Sample
\Debug\Media_Session_Sample.exp
1>player.obj : error LNK2019: unresolved external symbol _MFStartup@8 referenced in function  
"protected: long __thiscall CPlayer::Initialize(void)" (?Initialize@CPlayer@@IAEJXZ)
1>player.obj : error LNK2019: unresolved external symbol _MFShutdown@0 referenced in function   
"public: long __thiscall CPlayer::Shutdown(void)" (?Shutdown@CPlayer@@QAEJXZ)
1>player.obj : error LNK2019: unresolved external symbol _MFGetService@16 referenced in   
function "protected: virtual long __thiscall CPlayer::OnTopologyStatus(struct IMFMediaEvent   
*)"  (?OnTopologyStatus@CPlayer@@MAEJPAUIMFMediaEvent@@@Z)
1>player.obj : error LNK2001: unresolved external symbol _MR_VIDEO_RENDER_SERVICE
1>player.obj : error LNK2001: unresolved external symbol _MF_EVENT_TOPOLOGY_STATUS
1>player.obj : error LNK2019: unresolved external symbol _MFCreateMediaSession@8 referenced in 
function "protected: long __thiscall CPlayer::CreateSession(void)" 
(?CreateSession@CPlayer@@IAEJXZ)
1>player.obj : error LNK2019: unresolved external symbol _MFCreateSourceResolver@4 referenced   
in function "long __cdecl CreateMediaSource(wchar_t const *,struct IMFMediaSource * *)"   
(?CreateMediaSource@@YAJPB_WPAPAUIMFMediaSource@@@Z)
1>player.obj : error LNK2019: unresolved external symbol _MFCreateVideoRendererActivate@8  
referenced in function "long __cdecl CreateMediaSinkActivate(struct IMFStreamDescriptor 
*,struct HWND__ *,struct IMFActivate * *)"  
(?CreateMediaSinkActivate@@YAJPAUIMFStreamDescriptor@@PAUHWND__@@PAPAUIMFActivate@@@Z)
1>player.obj : error LNK2001: unresolved external symbol _MFMediaType_Video
1>player.obj : error LNK2019: unresolved external symbol _MFCreateAudioRendererActivate@4  
referenced in function "long __cdecl CreateMediaSinkActivate(struct IMFStreamDescriptor  
*,struct HWND__ *,struct IMFActivate * *)"  
(?CreateMediaSinkActivate@@YAJPAUIMFStreamDescriptor@@PAUHWND__@@PAPAUIMFActivate@@@Z)
1>player.obj : error LNK2001: unresolved external symbol _MFMediaType_Audio

有人可以告诉我是否有任何解决方案?

提前致谢,

0 个答案:

没有答案