⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 scenechangedetection.cpp

📁 动态场景中运动目标检测提取与跟踪 对新手很有用
💻 CPP
字号:
#include "scenechangedetection.h"
#include "PreProcess.h"
#include "StdAfx.h"
#include <math.h>

int getHistogramDifference(IplImage* X, IplImage* Y)
{
	ASSERT(X!=NULL && Y!=NULL);
	int histX[3][256];//单个通道的直方图
	int histY[3][256];
	int diff=0;

	getHistogram3D(X,histX);
	getHistogram3D(Y,histY);

	for(int i=0;i<256;i++)
	{
		diff+=(abs(histX[0][i]-histY[0][i])+abs(histX[1][i]-histY[1][i])
			+abs(histX[2][i]-histY[2][i]));

	}
	return diff;



}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -