my.h

来自「不错的particle filter的程序」· C头文件 代码 · 共 46 行

H
46
字号
/* File: my.h
 * -----------
 */

#ifndef MY_H#define MY_H
#include "defs.h"
#include "particles.h"#include "observation.h"
#define UPDATE_FRAMES	100
#define L_WEIGHT	0.03
#define L_WEIGHT_NUM	5
#define OVERLAP_RATE	0.8
#define MIN_HEIGHT	10
#define MIN_WIDTH	6
#define PRE_WEIGHT	0.7
#define R	5	//15	//R取奇数,为正方形框的边长,c中每点的值用以该点为中心所画框中所有点的平均值代替得到mc
#define G	20	//50;	G为一域值,当每个小方格中的最大值大于该域值,则记下该方格,所有方格的集合即包含了运动物体
#define L	5	//15	//L、H为列、行最大位移
#define H	5	//15
#define COLOR_CUE	0.7#define MOTION_CUE	0.3//update histogram to the current position
void UpdateHisto( IplImage* img, int r, int c, int w, int h, histogram* ref_histo );

void MaskParticleImage(IplImage* img, particle p, FILE *outfile);void DisplayDistribution(particle* particles, float sum, int n, char *window, int export);void DisplayHistogram(histogram* ref_histo, histogram* histo, char *window);void DisplayParticleHistogram(histogram* ref_histo, IplImage* img, int r, int c, int w, int h, char *window, FILE *file);int TryUpdateHistogram(particle* particles, int n, histogram* ref_histo);void Concentrate(CvMat *Mdiff, CvMat *Mdiff_conctr, int w, int h);CvPoint MotionCompensation(IplImage *Ma, IplImage *Mb, int w, int h, int DispL, int DispH);void InitRect(int i, int j, int w, int h, CvRect *recta, CvRect *rectb);#endif

⌨️ 快捷键说明

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