-
Notifications
You must be signed in to change notification settings - Fork 1
/
InputProcessor.h
52 lines (43 loc) · 1.24 KB
/
InputProcessor.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
//
// InputProvider.h
// opencv_fd_demo
//
// Created by Igor Gridchyn on 10/7/12.
// Copyright (c) 2012 Igor Gridchyn. All rights reserved.
//
#ifndef __opencv_fd_demo__InputProvider__
#define __opencv_fd_demo__InputProvider__
#include <iostream>
#include <stdio.h>
#include "FrameProcessor.h"
#include "cv.h"
class InputProcessor : public FrameProcessor
{
public:
virtual cv::Ptr<Frame> Process(cv::Ptr<Frame> frame) = 0;
virtual ~InputProcessor() {};
};
class VideoStreamInputProcessor : public InputProcessor
{
CvCapture* capture_ = 0;
public:
virtual cv::Ptr<Frame> Process(cv::Ptr<Frame> frame);
VideoStreamInputProcessor(int deviceNumber);
VideoStreamInputProcessor(std::string videoFileName);
virtual ~VideoStreamInputProcessor();
};
class PhotoInputProcessor : public InputProcessor
{
public:
virtual cv::Ptr<Frame> Process(cv::Ptr<Frame> frame);
virtual ~PhotoInputProcessor() {};
};
class PhotoFileListInputProcessor : public InputProcessor
{
FILE* photoListFile;
public:
virtual cv::Ptr<Frame> Process(cv::Ptr<Frame> frame);
PhotoFileListInputProcessor(std::string PhotoListFilePath);
virtual ~PhotoFileListInputProcessor();
};
#endif /* defined(__opencv_fd_demo__InputProvider__) */