资源简介
计算机图形学基础教程案例源码,例如:中点Bresenham算法、多边形有效边表填充算法、梁友栋-Barsky直线裁剪算法、Bezier曲线算法等40多个案例源码。
代码片段和文件信息
// MainFrm.cpp : implementation of the CMainframe class
//
#include “stdafx.h“
#include “Test.h“
#include “MainFrm.h“
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// CMainframe
IMPLEMENT_DYNCREATE(CMainframe CframeWnd)
BEGIN_MESSAGE_MAP(CMainframe CframeWnd)
//{{AFX_MSG_MAP(CMainframe)
// NOTE - the ClassWizard will add and remove mapping macros here.
// DO NOT EDIT what you see in these blocks of generated code !
ON_WM_CREATE()
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
static UINT indicators[] =
{
ID_SEPARATOR // status line indicator
ID_INDICATOR_CAPS
ID_INDICATOR_NUM
ID_INDICATOR_SCRL
};
/////////////////////////////////////////////////////////////////////////////
// CMainframe construction/destruction
CMainframe::CMainframe()
{
// TODO: add member initialization code here
}
CMainframe::~CMainframe()
{
}
int CMainframe::OnCreate(LPCREATESTRUCT lpCreateStruct)
{
if (CframeWnd::OnCreate(lpCreateStruct) == -1)
return -1;
if (!m_wndToolBar.CreateEx(this TBstyle_FLAT WS_CHILD | WS_VISIBLE | CBRS_TOP
| CBRS_GRIPPER | CBRS_TOOLTIPS | CBRS_FLYBY | CBRS_SIZE_DYNAMIC) ||
!m_wndToolBar.LoadToolBar(IDR_MAINframe))
{
TRACE0(“Failed to create toolbar\n“);
return -1; // fail to create
}
if (!m_wndStatusBar.Create(this) ||
!m_wndStatusBar.SetIndicators(indicators
sizeof(indicators)/sizeof(UINT)))
{
TRACE0(“Failed to create status bar\n“);
return -1; // fail to create
}
// TODO: Delete these three lines if you don‘t want the toolbar to
// be dockable
m_wndToolBar.EnableDocking(CBRS_ALIGN_ANY);
EnableDocking(CBRS_ALIGN_ANY);
DockControlBar(&m_wndToolBar);
return 0;
}
BOOL CMainframe::PreCreateWindow(CREATESTRUCT& cs)
{
if( !CframeWnd::PreCreateWindow(cs) )
return FALSE;
// TODO: Modify the Window class or styles here by modifying
// the CREATESTRUCT cs
return TRUE;
}
/////////////////////////////////////////////////////////////////////////////
// CMainframe diagnostics
#ifdef _DEBUG
void CMainframe::AssertValid() const
{
CframeWnd::AssertValid();
}
void CMainframe::Dump(CDumpContext& dc) const
{
CframeWnd::Dump(dc);
}
#endif //_DEBUG
/////////////////////////////////////////////////////////////////////////////
// CMainframe message handlers
相关资源
- VC++数字图像处理
- VC++串口modbus测试工程
- Visual C++视频会议开发技术与源码.ra
- VC数字图像处理杨淑莹北京交通大学
- VC++实现浏览器
- 《Visual C++ 6.0 用户界面制作技术与应
- 计算机图形学+配书源代码
- VC++2017 64位
- vc++ MFC 背单词软件毕业设计系统源代
- msdn for vc++6.0
- VC++2010番茄西红柿VAXvirsual assist X完美
- IC卡停车场管理系统源代码
- Vc++编写的计算器简单小程序
- VC++ CLR编写带图形界面的简单计算器
- vc++6.0 绿色版 完整版支持win7,win8系统
- 状态指示灯(VC++6.0源代码)
- 车牌牌照检测识别 VC++和opencv1.0 完整
- VC++100.rar
- VC++窗口和控件自适应屏幕尺寸
- 算法与数据结构课件及源代码
- VC++ 可视化计算器
- MFC/VC++字符串与十六进制码之间互相转
- 课程信息VC操作Access数据库(实现增删
- VC++ 实现WIFI共享工具 源代码(无线承
- VC++ GDI+ gdiplus应用集
- 细胞统计识别系统
- devc++ 64位最新版本
- VC++基于socket传输文件服务端和客户端
- VC++6.0 WIN7 32位版
- USB HID STM32 开发资料全集
评论
共有 条评论