使用MFC实现三条曲线,Bezier支持多次,B样条曲线默认为3次,可以修改。内附有说明文档。
代码片段和文件信息
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
目录 0 2018-12-08 13:15 BSpline
文件 29276 2018-12-08 13:15 BSplineBSpline.aps
文件 2707 2018-12-08 13:15 BSplineBSpline.clw
文件 4227 2018-12-06 21:47 BSplineBSpline.cpp
文件 4941 2018-12-08 13:12 BSplineBSpline.dsp
文件 522 2018-12-06 21:47 BSplineBSpline.dsw
文件 1367 2018-12-06 21:47 BSplineBSpline.h
文件 115712 2018-12-08 13:15 BSplineBSpline.ncb
文件 50688 2018-12-08 13:15 BSplineBSpline.opt
文件 248 2018-12-08 13:15 BSplineBSpline.plg
文件 12262 2018-12-08 13:12 BSplineBSpline.rc
文件 1762 2018-12-06 21:47 BSplineBSplineDoc.cpp
文件 1486 2018-12-06 21:47 BSplineBSplineDoc.h
文件 10364 2018-12-08 13:10 BSplineBSplineView.cpp
文件 2256 2018-12-08 12:59 BSplineBSplineView.h
目录 0 2018-12-08 13:13 BSplineDebug
文件 131212 2018-12-08 13:12 BSplineDebugBSpline.exe
文件 344912 2018-12-08 13:12 BSplineDebugBSpline.ilk
文件 23310 2018-12-06 21:47 BSplineDebugBSpline.obj
文件 5497000 2018-12-06 21:47 BSplineDebugBSpline.pch
文件 525312 2018-12-08 13:12 BSplineDebugBSpline.pdb
文件 7532 2018-12-08 13:12 BSplineDebugBSpline.res
文件 15079 2018-12-06 21:47 BSplineDebugBSplineDoc.obj
文件 47810 2018-12-08 13:10 BSplineDebugBSplineView.obj
文件 10777 2018-12-08 13:05 BSplineDebugDialog1.obj
文件 10887 2018-12-08 13:05 BSplineDebugDialog2.obj
文件 20229 2018-12-06 21:47 BSplineDebugMainFrm.obj
文件 4639 2018-12-06 21:57 BSplineDebugP2.obj
文件 105912 2018-12-06 21:47 BSplineDebugStdAfx.obj
文件 222208 2018-12-08 13:15 BSplineDebugvc60.idb
文件 364544 2018-12-08 13:10 BSplineDebugvc60.pdb
............此处省略112个文件信息
// Bezier.cpp : Defines the class behaviors for the application.
//
#include “stdafx.h“
#include “Bezier.h“
#include “MainFrm.h“
#include “BezierDoc.h“
#include “BezierView.h“
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// CBezierApp
BEGIN_MESSAGE_MAP(CBezierApp CWinApp)
//{{AFX_MSG_MAP(CBezierApp)
ON_COMMAND(ID_APP_ABOUT OnAppAbout)
// NOTE - the ClassWizard will add and remove mapping macros here.
// DO NOT EDIT what you see in these blocks of generated code!
//}}AFX_MSG_MAP
// Standard file based document commands
ON_COMMAND(ID_FILE_NEW CWinApp::OnFileNew)
ON_COMMAND(ID_FILE_OPEN CWinApp::OnFileOpen)
// Standard print setup command
ON_COMMAND(ID_FILE_PRINT_SETUP CWinApp::OnFilePrintSetup)
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CBezierApp construction
CBezierApp::CBezierApp()
{
// TODO: add construction code here
// Place all significant initialization in InitInstance
}
/////////////////////////////////////////////////////////////////////////////
// The one and only CBezierApp object
CBezierApp theApp;
/////////////////////////////////////////////////////////////////////////////
// CBezierApp initialization
BOOL CBezierApp::InitInstance()
{
AfxEnableControlContainer();
// Standard initialization
// If you are not using these features and wish to reduce the size
// of your final executable you should remove from the following
// the specific initialization routines you do not need.
#ifdef _AFXDLL
Enable3dControls(); // Call this when using MFC in a shared DLL
#else
Enable3dControlsStatic(); // Call this when linking to MFC statically
#endif
// Change the registry key under which our settings are stored.
// TODO: You should modify this string to be something appropriate
// such as the name of your company or organization.
SetRegistryKey(_T(“Local AppWizard-Generated Applications“));
LoadStdProfileSettings(); // Load standard INI file options (including MRU)
// Register the application‘s document templates. Document templates
// serve as the connection between documents frame windows and views.
CSingleDocTemplate* pDocTemplate;
pDocTemplate = new CSingleDocTemplate(
IDR_MAINframe
RUNTIME_CLASS(CBezierDoc)
RUNTIME_CLASS(CMainframe) // main SDI frame window
RUNTIME_CLASS(CBezierView));
AddDocTemplate(pDocTemplate);
// Parse command line for standard shell commands DDE file open
CCommandLineInfo cmdInfo;
ParseCommandLine(cmdInfo);
// Dispatch commands specified on the command line
if (!ProcessShellCommand(cmdInfo))
return FALSE;
// The one and only window has been initialized so show and update it.
m_pMainWnd->ShowWindow(SW_SHOW);
m_pMainWnd->UpdateWindow();
return TRUE;
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
目录 0 2018-12-08 13:15 BSpline
文件 29276 2018-12-08 13:15 BSplineBSpline.aps
文件 2707 2018-12-08 13:15 BSplineBSpline.clw
文件 4227 2018-12-06 21:47 BSplineBSpline.cpp
文件 4941 2018-12-08 13:12 BSplineBSpline.dsp
文件 522 2018-12-06 21:47 BSplineBSpline.dsw
文件 1367 2018-12-06 21:47 BSplineBSpline.h
文件 115712 2018-12-08 13:15 BSplineBSpline.ncb
文件 50688 2018-12-08 13:15 BSplineBSpline.opt
文件 248 2018-12-08 13:15 BSplineBSpline.plg
文件 12262 2018-12-08 13:12 BSplineBSpline.rc
文件 1762 2018-12-06 21:47 BSplineBSplineDoc.cpp
文件 1486 2018-12-06 21:47 BSplineBSplineDoc.h
文件 10364 2018-12-08 13:10 BSplineBSplineView.cpp
文件 2256 2018-12-08 12:59 BSplineBSplineView.h
目录 0 2018-12-08 13:13 BSplineDebug
文件 131212 2018-12-08 13:12 BSplineDebugBSpline.exe
文件 344912 2018-12-08 13:12 BSplineDebugBSpline.ilk
文件 23310 2018-12-06 21:47 BSplineDebugBSpline.obj
文件 5497000 2018-12-06 21:47 BSplineDebugBSpline.pch
文件 525312 2018-12-08 13:12 BSplineDebugBSpline.pdb
文件 7532 2018-12-08 13:12 BSplineDebugBSpline.res
文件 15079 2018-12-06 21:47 BSplineDebugBSplineDoc.obj
文件 47810 2018-12-08 13:10 BSplineDebugBSplineView.obj
文件 10777 2018-12-08 13:05 BSplineDebugDialog1.obj
文件 10887 2018-12-08 13:05 BSplineDebugDialog2.obj
文件 20229 2018-12-06 21:47 BSplineDebugMainFrm.obj
文件 4639 2018-12-06 21:57 BSplineDebugP2.obj
文件 105912 2018-12-06 21:47 BSplineDebugStdAfx.obj
文件 222208 2018-12-08 13:15 BSplineDebugvc60.idb
文件 364544 2018-12-08 13:10 BSplineDebugvc60.pdb
............此处省略112个文件信息
版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容, 请发送邮件举报,一经查实,本站将立刻删除。
评论列表(条)