📄 testdlg.h
字号:
#if !defined(AFX_TESTDLG_H__FF7BE2B4_8CB5_40A1_AA4A_2B04B3A70A1F__INCLUDED_)
#define AFX_TESTDLG_H__FF7BE2B4_8CB5_40A1_AA4A_2B04B3A70A1F__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// TestDlg.h : header file
#include "dib.h"
#include "vfw.h"
//
/////////////////////////////////////////////////////////////////////////////
// CTestDlg dialog
{
// Construction
//成员函数:
public:
void detect(BYTE* buff);//检测图像
void UpdateBackground();//更新背景
void initiate(CString filename);//初始化视频流
void show();//显示一帧
// void Action(BYTE* buff);
//成员变量:
public:
BYTE* m_pbuff; //存放一祯的数据
BITMAPINFO *m_pbmi; //每祯图像的信息头
BITMAPFILEHEADER m_bf; //文件头
BITMAPINFOHEADER m_bmih;
PAVISTREAM m_pavi; //avi文件得到的流
PAVIFILE m_pfile; //avi文件
AVIFILEINFO m_pfi; //avi文件信息
PGETFRAME m_pgf; // 从流中读出时一祯的格式
CDib m_dib;
int m_nw; // 图像宽
int m_nh; // 图像高
int m_step; //图像存储时每行应补充的字节数
// int m_number_car; //车流量
bool m_bopen; //avi文件打开状态
bool m_bpause; // 暂停状态
int m_timeinterval; //图像采集时间间隔
bool m_frontstate; //原来的状态
bool m_nowstate; //现在的状态
BYTE *background1; //背景1
BYTE *curground1; //当前图像数据1
int m_bkmean;
int m_bkchange;//背景转换标志
int c_threshold;
public:
CTestDlg(CWnd* pParent = NULL); // standard constructor
// Dialog Data
//{{AFX_DATA(CTestDlg)
enum { IDD = IDD_DIALOG1 };
CButton m_stop;
CButton m_start;
CButton m_pause;
CButton m_open;
long m_firstframe;
long m_curframe;
long m_length;
CString m_state;
//}}AFX_DATA
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CTestDlg)
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
//}}AFX_VIRTUAL
// Implementation
protected:
// Generated message map functions
//{{AFX_MSG(CTestDlg)
afx_msg void OnOpen();
afx_msg void OnStart();
afx_msg void OnPause();
afx_msg void OnStop();
afx_msg void OnPaint();
afx_msg void OnTimer(UINT nIDEvent);
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
};
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
#endif // !defined(AFX_TESTDLG_H__FF7BE2B4_8CB5_40A1_AA4A_2B04B3A70A1F__INCLUDED_)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -