资源简介
vc开发的一个播放AVI文件的例子,供学习多媒体开发者参考!
代码片段和文件信息
/**
* Dispatch.cpp Copyright _ 2001 Li Zhaoming. All rights reserved.
* Implement the generic message and command dispatchers.
*/
#include “stdafx.h“
LRESULT dispatchDefault(EDWP HWND UINT WPARAM LPARAM);
/**
* Call the function associated with a message.
*
* PARAMETERS:
* lpmsdi - Structure containing the message dispatch information.
* hwnd - The window handle
* uMessage - The message number
* wparam - Message specific data
* lparam - Message specific data
*
* RETURN VALUE:
* The value returned by the message function that was called.
*
* COMMENTS:
* Runs the table of messages stored in lpmsdi->rgmsd searching
* for a message number that matches uMessage. If a match is found
* call the associated function. Otherwise call dispatchDefault to
* call the default function if any associated with the message
* structure. In either case return the value recieved from the
* message or default function.
*/
LRESULT dispatchMessage(LPMSDI lpmsdi HWND hwnd UINT uMessage WPARAM wparam LPARAM lparam)
{
int imsd = 0;
MSD *rgmsd = lpmsdi->rgmsd;
int cmsd = lpmsdi->cmsd;
for (imsd = 0; imsd < cmsd; imsd++)
{
if (rgmsd[imsd].uMessage == uMessage)
return rgmsd[imsd].pfnmsg(hwnd uMessage wparam lparam);
}
return dispatchDefault(lpmsdi->edwp hwnd uMessage wparam lparam);
}
/**
* Call the function associated with a command.
*
* PARAMETERS:
* lpcmdi - Structure containing the command dispatch information.
* hwnd - The window handle
* GET_WM_COMMAND_ID(wparam lparam) - Identifier of the menu item
* control or accelerator.
* GET_WM_COMMAND_CMD(wparam lparam) - Notification code.
* GET_WM_COMMAND_HWND(wparam lparam) - The control handle or NULL.
*
* RETURN VALUE:
* The value returned by the command function that was called.
*
* COMMENTS:
* Runs the table of commands stored in lpcmdi->rgcmd searching
* for a command number that matches wCommand. If a match is found
* call the associated function. Otherwise call dispatchDefault to
* call the default function if any associated with the command
* structure. In either case return the value recieved from the
* command or default function.
*/
LRESULT dispatchCommand(LPCMDI lpcmdi HWND hwnd WPARAM wparam LPARAM lparam)
{
LRESULT lRet = 0;
WORD wCommand = GET_WM_COMMAND_ID(wparam lparam);
int icmd;
CMD *rgcmd = lpcmdi->rgcmd;
int ccmd = lpcmdi->ccmd;
// Message packing of wparam and lparam have changed for Win32
// so use the GET_WM_COMMAND macro to unpack the commnad
for (icmd = 0; icmd < ccmd; icmd++)
{
if (rgcmd[icmd].wCommand == wCommand)
{
return rgcmd[icmd].pfncmd(hwnd
wCommand
GET_WM_COMMAND_CMD(wparam lparam)
GET_WM_COMMAND_HWND(wparam lparam));
}
}
return dispatchDefault(lpcmdi->edwp hwnd WM_COMMAND wparam lparam);
}
/**
* Call the appropriate defaul
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 3989 2001-05-06 14:35 vc播放avi的程序\miniplay\miniplay\Dispatch.cpp
文件 6065 2001-12-22 16:15 vc播放avi的程序\miniplay\miniplay\Globals.h
文件 4962 2002-04-27 12:24 vc播放avi的程序\miniplay\miniplay\MingPla
文件 543 2001-07-26 07:04 vc播放avi的程序\miniplay\miniplay\MingPla
文件 329 2001-05-21 12:51 vc播放avi的程序\miniplay\miniplay\MingPla
文件 10134 1998-06-20 11:01 vc播放avi的程序\miniplay\miniplay\MingPla
文件 91136 2007-08-12 12:05 vc播放avi的程序\miniplay\miniplay\MingPla
文件 2534 2007-08-12 11:08 vc播放avi的程序\miniplay\miniplay\MingPla
文件 2564 2001-07-27 15:13 vc播放avi的程序\miniplay\miniplay\Misc.cpp
文件 1107 2001-07-27 13:25 vc播放avi的程序\miniplay\miniplay\resource.h
文件 294 2001-05-21 12:51 vc播放avi的程序\miniplay\miniplay\StdAfx.cpp
文件 1145 2001-07-26 13:52 vc播放avi的程序\miniplay\miniplay\StdAfx.h
文件 694 2001-12-23 18:30 vc播放avi的程序\miniplay\miniplay\Toolbar.bmp
文件 4722 2001-12-22 17:41 vc播放avi的程序\miniplay\miniplay\Toolbar.cpp
文件 5702 2001-12-22 16:41 vc播放avi的程序\miniplay\miniplay\Winmain.cpp
文件 86 2007-11-07 09:07 vc播放avi的程序\miniplay\miniplay\Debug\MingPla
文件 11768 2007-08-12 11:08 vc播放avi的程序\miniplay\miniplay\Debug\MingPla
文件 123904 2007-08-12 11:08 vc播放avi的程序\miniplay\miniplay\Debug\vc60.idb
文件 241664 2007-08-12 11:08 vc播放avi的程序\miniplay\miniplay\Debug\vc60.pdb
文件 281132 2007-08-12 11:08 vc播放avi的程序\miniplay\miniplay\Debug\MingPla
文件 208983 2007-08-12 11:08 vc播放avi的程序\miniplay\miniplay\Debug\MingPla
文件 541696 2007-08-12 11:08 vc播放avi的程序\miniplay\miniplay\Debug\MingPla
文件 633066 2007-08-12 11:08 vc播放avi的程序\miniplay\miniplay\Debug\StdAfx.sbr
文件 83831 2007-08-12 11:08 vc播放avi的程序\miniplay\miniplay\Debug\StdAfx.obj
文件 0 2007-08-12 11:08 vc播放avi的程序\miniplay\miniplay\Debug\Dispatch.sbr
文件 0 2007-08-12 11:08 vc播放avi的程序\miniplay\miniplay\Debug\MingPla
文件 0 2007-08-12 11:08 vc播放avi的程序\miniplay\miniplay\Debug\Misc.sbr
文件 0 2007-08-12 11:08 vc播放avi的程序\miniplay\miniplay\Debug\Toolbar.sbr
文件 0 2007-08-12 11:08 vc播放avi的程序\miniplay\miniplay\Debug\Winmain.sbr
文件 5298 2007-08-12 11:08 vc播放avi的程序\miniplay\miniplay\Debug\Winmain.obj
............此处省略17个文件信息
- 上一篇:同步算法在分布式系统中的实现与应用
- 下一篇:网络嗅探器实验报告
相关资源
- 简单多边形的屋脊线计算算法
- 基于精确线性化算法的TCR—TSC型SVC控
- 黑蜘蛛破解红蜘蛛多媒体教学软件 亲
- qt5音乐播放器源代码
- spring mvc 项目源码 + 完整环境配置详细
- VC计算器的详细课程设计
- 八皇后问题,vc源码。小游戏。
- 24to8Colors.zip
- https VC实现的源代码
- 老版弹琴吧蛐蛐播放器 免安装绿色版
- Qt Creator+OpenCV410(vc14)开发的图片查
- MP3 播放器调用Api
- 基于VC_的OpenGL三维动画仿真及场景漫
- 用QT5写的视频播放器182732
- GnuGo 3.8 单文件,MSVC2010编译
- VC表格控件/开源/GridCtrl
- Lotus ScreenCam 97播放器
- serialport类182377
- 手动清除IIS日志
- JP播放器(一个32K的播放器什么都能播
- 基于MVC模式的扫雷游戏
- WMVCore(WindowsServer2008R2 x64能用的版本
- SpringMVC+uploadify实现文件上传带进度条
- VC2010调用Labview2014的DLL范例
- 单片机制作的MP3播放器
- vc实现dicom读取与显示
- VC mirror driver源码
- lz0-052VCE 最全题库截止20181102
- vmware vcenter converter地址
- 汽车整车控制器底层软件开发及程序
评论
共有 条评论