⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 setupvideodlg.cpp

📁 VIS H.323 Library V2.1 Release
💻 CPP
字号:
/*
  VIS H.323 Video Conference System
      --Sample for VIS H.323 DLL Library 2.1 Release

  For more information,visit our homepage 
  
    [http://www.115studio.com]

  or mail to us for tech support and bug report

    [support@115studio.com]

  2000-2004 115Studio
  
  2004-04-05
*/
// SetupVideoDlg.cpp : implementation file
//

#include "stdafx.h"
#include "visconf.h"
#include "SetupVideoDlg.h"
#include "MyEndPoint.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

/////////////////////////////////////////////////////////////////////////////
// CSetupVideoDlg dialog


CSetupVideoDlg::CSetupVideoDlg(CWnd* pParent /*=NULL*/)
	: CDialog(CSetupVideoDlg::IDD, pParent)
{
	//{{AFX_DATA_INIT(CSetupVideoDlg)
	m_autoSendVideo = FALSE;
	m_captureFormat = -1;
	m_device = -1;
	m_quality = 50;
	m_sendLocalVideo = FALSE;
	m_transmitFormat = -1;
	m_useDirectshow = FALSE;
	m_captureFPS = 10;
	m_transmitFPS = 10;
	m_h263 = _T("");
	//}}AFX_DATA_INIT
}


void CSetupVideoDlg::DoDataExchange(CDataExchange* pDX)
{
	CDialog::DoDataExchange(pDX);
	//{{AFX_DATA_MAP(CSetupVideoDlg)
	DDX_Control(pDX, IDC_SPIN_TRANSMIT_FPS, m_spinTransmitFPS);
	DDX_Control(pDX, IDC_SPIN_CAPTURE_FPS, m_spinCaptureFPS);
	DDX_Control(pDX, IDC_TRANSMIT_FORMAT, m_comboTransmitFormat);
	DDX_Control(pDX, IDC_SPIN_QUALITY, m_spinQuality);
	DDX_Control(pDX, IDC_DEVICE, m_comboDevice);
	DDX_Control(pDX, IDC_CAPTURE_FORMAT, m_comboCaptureFormat);
	DDX_Check(pDX, IDC_AUTO_SEND_VIDEO, m_autoSendVideo);
	DDX_CBIndex(pDX, IDC_CAPTURE_FORMAT, m_captureFormat);
	DDX_CBIndex(pDX, IDC_DEVICE, m_device);
	DDX_Text(pDX, IDC_QUALITY, m_quality);
	DDV_MinMaxUInt(pDX, m_quality, 0, 100);
	DDX_Check(pDX, IDC_SEND_LOCAL_VIDEO, m_sendLocalVideo);
	DDX_CBIndex(pDX, IDC_TRANSMIT_FORMAT, m_transmitFormat);
	DDX_Check(pDX, IDC_USE_DIRECTSHOW, m_useDirectshow);
	DDX_Text(pDX, IDC_CAPTURE_FPS, m_captureFPS);
	DDV_MinMaxUInt(pDX, m_captureFPS, 1, 30);
	DDX_Text(pDX, IDC_TRANSMIT_FPS, m_transmitFPS);
	DDV_MinMaxUInt(pDX, m_transmitFPS, 1, 30);
	DDX_Text(pDX, IDC_H263, m_h263);
	//}}AFX_DATA_MAP
}


BEGIN_MESSAGE_MAP(CSetupVideoDlg, CDialog)
	//{{AFX_MSG_MAP(CSetupVideoDlg)
	//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CSetupVideoDlg message handlers

BOOL CSetupVideoDlg::OnInitDialog() 
{
	CDialog::OnInitDialog();
	
	// TODO: Add extra initialization here
	m_spinQuality.SetRange32(0,100);
	m_spinCaptureFPS.SetRange32(1,30);
	m_spinTransmitFPS.SetRange32(1,30);

	char name[256]="";
	for(DWORD i=0;i<g_pep->m_VideoGrabber.GetDeviceCount();i++)
	{
		g_pep->m_VideoGrabber.GetDeviceName(i,name,256);
		m_comboDevice.AddString(name);
	}

	m_comboCaptureFormat.AddString("QCIF - 176*144");
	m_comboCaptureFormat.AddString("CIF  - 352*288");

	m_comboTransmitFormat.AddString("QCIF - 176*144");
	m_comboTransmitFormat.AddString("CIF  - 352*288");

	if(IsH263Available())
		m_h263="H.263 codec available!";
	else
		m_h263="H.263 codec not available!";
	UpdateData(FALSE);
	return TRUE;  // return TRUE unless you set the focus to a control
	              // EXCEPTION: OCX Property Pages should return FALSE
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -