mirror of
https://github.com/peterbraden/node-opencv.git
synced 2025-12-08 19:45:55 +00:00
With OpenCV >3.1 and 2.4.13, OpenCV can now be installed without specific modules. This makes it so that `node-opencv` will still be able to compile.
26 lines
432 B
C++
26 lines
432 B
C++
#include "OpenCV.h"
|
|
|
|
#ifdef HAVE_OPENCV_VIDEO
|
|
|
|
class TrackedObject: public Nan::ObjectWrap {
|
|
public:
|
|
int channel;
|
|
cv::Mat hsv;
|
|
cv::Mat hue;
|
|
cv::Mat mask;
|
|
cv::Mat prob;
|
|
|
|
cv::Mat hist;
|
|
cv::Rect prev_rect;
|
|
|
|
static Nan::Persistent<FunctionTemplate> constructor;
|
|
static void Init(Local<Object> target);
|
|
static NAN_METHOD(New);
|
|
|
|
TrackedObject(cv::Mat image, cv::Rect rect, int channel);
|
|
|
|
JSFUNC(Track);
|
|
};
|
|
|
|
#endif
|