资源简介
新手学习opencv--基于Hog的视频行人检测

代码片段和文件信息
/*源文件 CvvImage.cpp*/
#include “StdAfx.h“
#include “CvvImage.h“
//////////////////////////////////////////////////////////////////////
// Construction/Destruction
//////////////////////////////////////////////////////////////////////
CV_INLINE RECT NormalizeRect( RECT r );
CV_INLINE RECT NormalizeRect( RECT r )
{
int t;
if( r.left > r.right )
{
t = r.left;
r.left = r.right;
r.right = t;
}
if( r.top > r.bottom )
{
t = r.top;
r.top = r.bottom;
r.bottom = t;
}
return r;
}
CV_INLINE CvRect RectToCvRect( RECT sr );
CV_INLINE CvRect RectToCvRect( RECT sr )
{
sr = NormalizeRect( sr );
return cvRect( sr.left sr.top sr.right - sr.left sr.bottom - sr.top );
}
CV_INLINE RECT CvRectToRect( CvRect sr );
CV_INLINE RECT CvRectToRect( CvRect sr )
{
RECT dr;
dr.left = sr.x;
dr.top = sr.y;
dr.right = sr.x + sr.width;
dr.bottom = sr.y + sr.height;
return dr;
}
CV_INLINE IplROI RectToROI( RECT r );
CV_INLINE IplROI RectToROI( RECT r )
{
IplROI roi;
r = NormalizeRect( r );
roi.xOffset = r.left;
roi.yOffset = r.top;
roi.width = r.right - r.left;
roi.height = r.bottom - r.top;
roi.coi = 0;
return roi;
}
void FillBitmapInfo( BITMAPINFO* bmi int width int height int bpp int origin )
{
assert( bmi && width >= 0 && height >= 0 && (bpp == 8 || bpp == 24 || bpp == 32));
BITMAPINFOHEADER* bmih = &(bmi->bmiHeader);
memset( bmih 0 sizeof(*bmih));
bmih->biSize = sizeof(BITMAPINFOHEADER);
bmih->biWidth = width;
bmih->biHeight = origin ? abs(height) : -abs(height);
bmih->biPlanes = 1;
bmih->biBitCount = (unsigned short)bpp;
bmih->biCompression = BI_RGB;
if( bpp == 8 )
{
RGBQUAD* palette = bmi->bmiColors;
int i;
for( i = 0; i < 256; i++ )
{
palette[i].rgbBlue = palette[i].rgbGreen = palette[i].rgbRed = (BYTE)i;
palette[i].rgbReserved = 0;
}
}
}
CvvImage::CvvImage()
{
m_img = 0;
}
void CvvImage::Destroy()
{
cvReleaseImage( &m_img );
}
CvvImage::~CvvImage()
{
Destroy();
}
bool CvvImage::Create( int w int h int bpp int origin )
{
const unsigned max_img_size = 10000;
if( (bpp != 8 && bpp != 24 && bpp != 32) ||
(unsigned)w >= max_img_size || (unsigned)h >= max_img_size ||
(origin != IPL_ORIGIN_TL && origin != IPL_ORIGIN_BL))
{
assert(0); // most probably it is a programming error
return false;
}
if( !m_img || Bpp() != bpp || m_img->width != w || m_img->height != h )
{
if( m_img && m_img->nSize == sizeof(IplImage))
Destroy();
/* prepare IPL header */
m_img = cvCreateImage( cvSize( w h ) IPL_DEPTH_8U bpp/8 );
}
if( m_img )
m_img->origin = origin == 0 ? IPL_ORIGIN_TL : IPL_ORIGIN_BL;
return m_img != 0;
}
void CvvImage::CopyOf( CvvImage& image int desired_color )
{
Ip
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 7251 2016-05-15 11:42 PasserTest\PasserTest\CvvImage.cpp
文件 2054 2015-05-27 10:51 PasserTest\PasserTest\CvvImage.h
文件 3438 2013-12-20 17:49 PasserTest\PasserTest\include\opencv\cv.h
文件 2411 2013-12-20 17:49 PasserTest\PasserTest\include\opencv\cv.hpp
文件 2850 2013-12-20 17:49 PasserTest\PasserTest\include\opencv\cvaux.h
文件 2346 2013-12-20 17:49 PasserTest\PasserTest\include\opencv\cvaux.hpp
文件 2184 2013-12-20 17:49 PasserTest\PasserTest\include\opencv\cvwimage.h
文件 2465 2013-12-20 17:49 PasserTest\PasserTest\include\opencv\cxcore.h
文件 2423 2013-12-20 17:49 PasserTest\PasserTest\include\opencv\cxcore.hpp
文件 2265 2013-12-20 17:49 PasserTest\PasserTest\include\opencv\cxeigen.hpp
文件 110 2013-12-20 17:49 PasserTest\PasserTest\include\opencv\cxmisc.h
文件 2306 2013-12-20 17:49 PasserTest\PasserTest\include\opencv\highgui.h
文件 2189 2013-12-20 17:49 PasserTest\PasserTest\include\opencv\ml.h
文件 37635 2013-12-20 17:49 PasserTest\PasserTest\include\opencv2\calib3d\calib3d.hpp
文件 38471 2013-12-20 17:49 PasserTest\PasserTest\include\opencv2\contrib\contrib.hpp
文件 3042 2013-12-20 17:49 PasserTest\PasserTest\include\opencv2\contrib\detection_ba
文件 7099 2013-12-20 17:49 PasserTest\PasserTest\include\opencv2\contrib\hybridtracker.hpp
文件 12807 2013-12-20 17:49 PasserTest\PasserTest\include\opencv2\contrib\openfabmap.hpp
文件 23958 2013-12-20 17:49 PasserTest\PasserTest\include\opencv2\contrib\retina.hpp
文件 15428 2014-02-04 11:57 PasserTest\PasserTest\include\opencv2\core\affine.hpp
文件 186316 2014-02-04 11:57 PasserTest\PasserTest\include\opencv2\core\core.hpp
文件 78497 2014-03-05 13:02 PasserTest\PasserTest\include\opencv2\core\core_c.h
文件 7854 2013-12-20 17:49 PasserTest\PasserTest\include\opencv2\core\cuda_devptrs.hpp
文件 2198 2013-12-20 17:49 PasserTest\PasserTest\include\opencv2\core\devmem2d.hpp
文件 9464 2013-12-20 17:49 PasserTest\PasserTest\include\opencv2\core\eigen.hpp
文件 18705 2013-12-20 17:49 PasserTest\PasserTest\include\opencv2\core\gpumat.hpp
文件 34132 2013-12-20 17:49 PasserTest\PasserTest\include\opencv2\core\internal.hpp
文件 80561 2014-01-10 11:00 PasserTest\PasserTest\include\opencv2\core\mat.hpp
文件 9346 2013-12-20 17:49 PasserTest\PasserTest\include\opencv2\core\opengl_interop.hpp
文件 9919 2013-12-20 17:49 PasserTest\PasserTest\include\opencv2\core\opengl_interop_deprecated.hpp
............此处省略211个文件信息
相关资源
- Anti-biofilm Activity of Resveratrol and Ursol
- [b115]FPGA上运行人脸识别源代码.zip
- 3D_HOG 代码
- hog特征提取,c版本代码
- 论文研究 - 多阶段人行横道和两阶段
- HOG+SVM实现数字识别
- 人车分类识别 HOG特征+KNN分类器
- opencv行人检测,新鲜出炉
- 基于HOG特征提取的svm行人头肩训练
- RISC-V 二值化 CNN 芯片加速器进行人员
- 使用kalman滤波实现动态行人检测与跟
- 经典的行人检测算法,利用HOG和SVM实
- 行人再识别和步态识别综述
- 基于HOG-CSLBP与深度学习的跨年龄人脸
- MIT行人检测数据库JPG格式
- 行人跟踪OPENCV代码
- opencv实现行人检测
- 行人检测研究现状和常用方法总结p
- 智能视频监控中的行人检测与跟踪方
- 利用PCA和SVM进行人脸识别
- 积分通道特征资料
- 行人检测程序
- VISSIM行人仿真模块介绍和使用方法d
- Anylogic行人库教程.pdf
- 深度学习与自动驾驶领域的数据集K
- Fundamental Principles of Optical Lithography
- 蓝牙核心技术-HOGP
- 多运动行人检测与跟踪技术研究
- HOG_SVM_DATA
- anylogic行人库中文说明文档
评论
共有 条评论