首页  编辑  

MCI使用一例

Tags: /超级猛料/Multi-Media.多媒体相关/   Date Created:

]、。·ˉˇ¨〃々—~‖…’”〕〉》」』〗】∶!"'),.:;?]` if(!MCIWndRegisterClass())

return FALSE;

HWND m_hAVI;

m_hAVI=MCIWndCreate(NULL,AfxGetInstanceHandle(),MCIWNDF_NOPLAYBAR|

 WS_MAXIMIZE|WS_VISIBLE|WS_POPUP,"c:\\tishi.dir");//"G:\\Program Files\\ICQ\\ICQNEWS.avi"

if(MCIWndUseTime(m_hAVI)!=0)

return FALSE;

long PlayTime=MCIWndGetLength(m_hAVI);

MCIWndPlay(m_hAVI);

::Sleep(PlayTime*5);

MCIWndDestroy(m_hAVI);

行吗?