資源簡介
1、對火車攝像頭的獲得的圖像進行預處理
其中,濾波用高斯濾波,圖像增強包括直方圖均衡化和增強對比度,邊緣檢測用canny算子。
2、檢測靜態障礙物(只需要檢測鐵軌內側以及鐵軌上的障礙物):
(1)提取鐵軌的框架
(2)設置檢測窗
(3)障礙物檢測,通過判斷圖像的八維紋理特征。
代碼片段和文件信息
//?ImagePro.cpp?:?Defines?the?class?behaviors?for?the?application.
//
#include?“stdafx.h“
#include?“ImagePro.h“
#include?“ImageProDlg.h“
#ifdef?_DEBUG
#define?new?DEBUG_NEW
#endif
//?CImageProApp
BEGIN_MESSAGE_MAP(CImageProApp?CWinApp)
ON_COMMAND(ID_HELP?&CWinApp::onhelp)
//?CImageProApp?construction
CImageProApp::CImageProApp()
{
//?support?Restart?Manager
m_dwRestartManagerSupportFlags?=?AFX_RESTART_MANAGER_SUPPORT_RESTART;
//?TODO:?add?construction?code?here
//?Place?all?significant?initialization?in?InitInstance
}
//?The?one?and?only?CImageProApp?object
CImageProApp?theApp;
//?CImageProApp?initialization
BOOL?CImageProApp::InitInstance()
{
//?InitCommonControlsEx()?is?required?on?Windows?XP?if?an?applicationINITCOMMONCONTROLSEX?InitCtrls;
InitCtrls.dwSize?=?sizeof(InitCtrls);
//?Set?this?to?include?all?the?common?control?classes?you?want?to?use
//?in?your?application.
InitCtrls.dwICC?=?ICC_WIN95_CLASSES;
InitCommonControlsEx(&InitCtrls);
CWinApp::InitInstance();
AfxEnableControlContainer();
//?Create?the?shell?manager?in?case?the?dialog?contains
//?any?shell?tree?view?or?shell?list?view?controls.
CShellManager?*pShellManager?=?new?CShellManager;
//?Activate?“Windows?Native“?visual?manager?for?enabling?themes?in?MFC?controls
CMFCVisualManager::SetDefaultManager(RUNTIME_CLASS(CMFCVisualManagerWindows));
//?Standard?initialization
//?the?specific?initialization?routines?you?do?not?need
//?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“));
CImageProDlg?dlg;
m_pMainWnd?=?&dlg;
INT_PTR?nResponse?=?dlg.DoModal();
if?(nResponse?==?IDOK)
{
//?TODO:?Place?code?here?to?handle?when?the?dialog?is
//??dismissed?with?OK
}
else?if?(nResponse?==?IDCANCEL)
{
//?TODO:?Place?code?here?to?handle?when?the?dialog?is
//??dismissed?with?Cancel
}
else?if?(nResponse?==?-1)
{
//?Delete?the?shell?manager?created?above.
if?(pShellManager?!=?NULL)
{
delete?pShellManager;
}
//?Since?the?dialog?has?been?closed?return?FALSE?so?that?we?exit?the
//??application?rather?than?start?the?application‘s?message?pump.
return?FALSE;
}
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????目錄???????????0??2018-10-11?10:15??基于機器視覺的列車前方障礙物檢測\
?????目錄???????????0??2018-10-11?10:13??基于機器視覺的列車前方障礙物檢測\源碼\
?????目錄???????????0??2018-05-21?23:52??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\
?????目錄???????????0??2018-05-19?00:24??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\Debug\
?????文件??????375808??2018-05-21?23:51??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\Debug\ImagePro.exe
?????文件?????2678056??2018-05-21?23:51??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\Debug\ImagePro.ilk
?????文件?????8858624??2018-05-21?23:51??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\Debug\ImagePro.pdb
?????目錄???????????0??2018-10-11?10:14??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\
?????目錄???????????0??2018-05-21?23:51??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\Debug\
?????文件????????1154??2018-05-18?23:05??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\Debug\ImagePro.Build.CppClean.log
?????文件????????4494??2018-05-21?23:51??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\Debug\ImagePro.log
?????文件??????509962??2018-05-19?00:24??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\Debug\ImagePro.obj
?????文件????43188224??2018-05-18?23:05??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\Debug\ImagePro.pch
?????文件???????69772??2018-05-19?00:30??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\Debug\ImagePro.res
?????目錄???????????0??2018-05-21?23:51??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\Debug\ImagePro.tlog\
?????文件??????215152??2018-05-21?23:51??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\Debug\ImagePro.tlog\CL.read.1.tlog
?????文件????????3132??2018-05-21?23:51??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\Debug\ImagePro.tlog\CL.write.1.tlog
?????文件?????????155??2018-05-21?23:51??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\Debug\ImagePro.tlog\ImagePro.lastbuildstate
?????文件????????2562??2018-05-21?23:51??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\Debug\ImagePro.tlog\cl.command.1.tlog
?????文件????????1670??2018-05-21?23:51??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\Debug\ImagePro.tlog\li
?????文件????????5534??2018-05-21?23:51??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\Debug\ImagePro.tlog\li
?????文件?????????768??2018-05-21?23:51??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\Debug\ImagePro.tlog\li
?????文件?????????588??2018-05-19?00:30??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\Debug\ImagePro.tlog\rc.command.1.tlog
?????文件????????2682??2018-05-19?00:30??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\Debug\ImagePro.tlog\rc.read.1.tlog
?????文件?????????194??2018-05-19?00:30??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\Debug\ImagePro.tlog\rc.write.1.tlog
?????文件??????694801??2018-05-19?00:32??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\Debug\ImageProDlg.obj
?????文件??????675385??2018-05-21?23:51??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\Debug\Imageprocess.obj
?????文件??????908966??2018-05-18?23:05??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\Debug\stdafx.obj
?????文件?????2657280??2018-05-21?23:51??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\Debug\vc120.idb
?????文件?????7344128??2018-05-21?23:51??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\Debug\vc120.pdb
?????文件??????108680??2018-05-19?00:30??基于機器視覺的列車前方障礙物檢測\源碼\ImagePro\ImagePro\ImagePro.aps
............此處省略28個文件信息
- 上一篇:IMDB電影數據集
- 下一篇:完整代碼!掃雷游戲,vs2010
評論
共有 條評論