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

📄 blobdetection_cc.h

📁 for the TI dm6446 platformBackground subtraction moduleMaintain a background model, which can distin
💻 H
字号:
/**
@file   blobDetection_CC.h
@brief  Implementation of blob detection algorithm for background subtraction (called by abs.c)
@author Magengyu
*/

#ifndef BLOB_DETECTION_CC_H
#define BLOB_DETECTION_CC_H

#include "backgroundSubtraction.h"

#include "../include/ema.h"

#ifdef    __cplusplus
extern "C" {
#endif


// allocate and release memory for Blob filling functions
void Blob_Create(USHORT w, USHORT h);
void Blob_Release();

// dilate the foreground region
// if a shadow pixel is close to the foreground, it is labeled as uncertain fore or back pixel
// in the advanced scanline filling method, deal with that
void Blob_Dilate_Fore_into_Shadow(BYTE* img);

// advanced blob detection
// 1. Add shadow removal code
// 2. connected foreground and theft pixels together
// 3. dilate foreground INTo shadow region. two foreground pixel can be reachable through shadow region.
//void Blob_Detection(BYTE* img, EmaRect* rects, BYTE* types, INT* nBlobNum, INT* forenum, INT* noisenum);
void Blob_Detection(BYTE* img, EmaRect* rects, INT* nBlobNum, INT* forenum, INT* noisenum);

void Blob_Detection_Again(BYTE* img, EmaRect* rects, INT* nBlobNum);

// two scan line filling functions for corresponding BlobDetection functions
INT Blob_ScanLineFill_Shadow(BYTE *img, USHORT seedx, USHORT seedy, EmaRect* box);
LONG Blob_ScanLineFill(BYTE *img, USHORT seedx, USHORT seedy, EmaRect* box);

// remove shadow in blob 
void Blob_RemoveShadow( BYTE* label, BYTE *diffimg, EmaRect* blob );

// determine whether a blob is left baggage or theft
void Blob_Theft_or_LeftBag(BYTE *grayimg, BYTE* label, EmaRect* blob); //, BYTE* type);

// compare if rsmall is inside rbig
BYTE Blob_Inside(EmaRect rsmall, EmaRect rbig);

void Blob_ResetLabelImage(BYTE* lblimg);

#ifdef    __cplusplus
}	// extern "C"
#endif

#endif // !defined(AFX_BLOB_H__59134AE0_EDB5_48B2_9944_E172E78041DC__INCLUDED_)

⌨️ 快捷键说明

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