資源簡介
計算機圖形學的大實驗,直線、圓、多邊形畫法,多邊形填充算法,包括掃描線填充、四方向種子填充和種子棧填充,方法是,先畫好多邊形,點擊多邊形填充方法,選擇好顏色后,點擊多邊形,就可自動填充。注意,種子填充法,多邊形不要畫太大

代碼片段和文件信息
//?31509030.cpp?:?Defines?the?class?behaviors?for?the?application.
//
#include?“stdafx.h“
#include?“31509030.h“
#include?“MainFrm.h“
#include?“31509030Doc.h“
#include?“31509030View.h“
#ifdef?_DEBUG
#define?new?DEBUG_NEW
#undef?THIS_FILE
static?char?THIS_FILE[]?=?__FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
//?CMy31509030App
BEGIN_MESSAGE_MAP(CMy31509030App?CWinApp)
//{{AFX_MSG_MAP(CMy31509030App)
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()
/////////////////////////////////////////////////////////////////////////////
//?CMy31509030App?construction
CMy31509030App::CMy31509030App()
{
//?TODO:?add?construction?code?here
//?Place?all?significant?initialization?in?InitInstance
}
/////////////////////////////////////////////////////////////////////////////
//?The?one?and?only?CMy31509030App?object
CMy31509030App?theApp;
/////////////////////////////////////////////////////////////////////////////
//?CMy31509030App?initialization
BOOL?CMy31509030App::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(CMy31509030Doc)
RUNTIME_CLASS(CMainframe)???????//?main?SDI?frame?window
RUNTIME_CLASS(CMy31509030View));
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
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????文件??????29688??2016-04-13?11:05??多邊形填充(掃描線、四方向種子填充、)\31509030\31509030.aps
?????文件???????2675??2016-04-13?11:05??多邊形填充(掃描線、四方向種子填充、)\31509030\31509030.clw
?????文件???????4273??2016-03-16?17:09??多邊形填充(掃描線、四方向種子填充、)\31509030\31509030.cpp
?????文件???????4954??2016-03-30?19:22??多邊形填充(掃描線、四方向種子填充、)\31509030\31509030.dsp
?????文件????????524??2016-03-16?17:09??多邊形填充(掃描線、四方向種子填充、)\31509030\31509030.dsw
?????文件???????1388??2016-03-16?17:09??多邊形填充(掃描線、四方向種子填充、)\31509030\31509030.h
?????文件?????148480??2016-04-13?11:05??多邊形填充(掃描線、四方向種子填充、)\31509030\31509030.ncb
?????文件??????49664??2016-04-13?11:05??多邊形填充(掃描線、四方向種子填充、)\31509030\31509030.opt
?????文件????????250??2016-04-13?11:05??多邊形填充(掃描線、四方向種子填充、)\31509030\31509030.plg
?????文件??????12519??2016-03-30?17:12??多邊形填充(掃描線、四方向種子填充、)\31509030\31509030.rc
?????文件???????1816??2016-03-16?17:09??多邊形填充(掃描線、四方向種子填充、)\31509030\31509030Doc.cpp
?????文件???????1511??2016-03-16?17:09??多邊形填充(掃描線、四方向種子填充、)\31509030\31509030Doc.h
?????文件??????20980??2016-03-30?20:30??多邊形填充(掃描線、四方向種子填充、)\31509030\31509030View.cpp
?????文件???????3686??2016-03-30?20:28??多邊形填充(掃描線、四方向種子填充、)\31509030\31509030View.h
?????文件????????507??2016-03-18?20:45??多邊形填充(掃描線、四方向種子填充、)\31509030\AEL.cpp
?????文件????????535??2016-03-18?20:45??多邊形填充(掃描線、四方向種子填充、)\31509030\AEL.h
?????文件????????500??2016-03-18?20:44??多邊形填充(掃描線、四方向種子填充、)\31509030\ET.cpp
?????文件????????534??2016-03-18?20:44??多邊形填充(掃描線、四方向種子填充、)\31509030\ET.h
?????文件???????2550??2016-03-20?17:00??多邊形填充(掃描線、四方向種子填充、)\31509030\MainFrm.cpp
?????文件???????1440??2016-03-16?20:56??多邊形填充(掃描線、四方向種子填充、)\31509030\MainFrm.h
?????文件???????4373??2016-03-16?17:09??多邊形填充(掃描線、四方向種子填充、)\31509030\ReadMe.txt
?????文件???????1078??2016-03-16?17:09??多邊形填充(掃描線、四方向種子填充、)\31509030\res\31509030.ico
?????文件????????400??2016-03-16?17:09??多邊形填充(掃描線、四方向種子填充、)\31509030\res\31509030.rc2
?????文件???????1078??2016-03-16?17:09??多邊形填充(掃描線、四方向種子填充、)\31509030\res\31509030Doc.ico
?????文件???????1078??2016-03-23?10:53??多邊形填充(掃描線、四方向種子填充、)\31509030\res\Toolbar.bmp
?????文件???????1065??2016-03-30?17:12??多邊形填充(掃描線、四方向種子填充、)\31509030\resource.h
?????文件????????807??2016-03-30?19:20??多邊形填充(掃描線、四方向種子填充、)\31509030\Stack.cpp
?????文件????????808??2016-03-30?19:19??多邊形填充(掃描線、四方向種子填充、)\31509030\Stack.h
?????文件????????210??2016-03-16?17:09??多邊形填充(掃描線、四方向種子填充、)\31509030\StdAfx.cpp
?????文件???????1054??2016-03-16?17:09??多邊形填充(掃描線、四方向種子填充、)\31509030\StdAfx.h
............此處省略6個文件信息
評論
共有 條評論