-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathTestDriver.cpp
More file actions
89 lines (82 loc) · 1.29 KB
/
Copy pathTestDriver.cpp
File metadata and controls
89 lines (82 loc) · 1.29 KB
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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
#include "StdAfx.h"
#include "TestDriver.h"
using namespace System::Windows::Forms;
using namespace System;
namespace forms2{
TestDriver::TestDriver(void)
{
}
int TestDriver::initCamera()
{
return 0;
}
int TestDriver::openCameraDialog()
{
return 0;
}
void TestDriver::lockCameraDialog(bool lock)
{
}
void TestDriver::closeCamera()
{
}
void TestDriver::expose()
{
}
void TestDriver::stop()
{
}
int TestDriver::getImageStatus()
{
return CAMERA_IDLE;
}
int TestDriver::getImageWidth()
{
return getCols();
}
int TestDriver::getImageHeight()
{
return getRows();
}
void TestDriver::readImage(UInt16 *buffer)
{
int rows = getRows();
int cols = getCols();
for (int x=0;x<cols;x++)
for (int y=0;y<rows;y++)
{
buffer[x + y*cols]=7;
}
}
int TestDriver::armCamera()
{
return 0;
}
int TestDriver::getRows()
{
//this function determines the number of rows of data to be taken
getSettings();
int rows = (roiy2 - roiy1+1)/vbin;
return rows;
}
int TestDriver::getCols()
{
getSettings();
int cols = (roix2 - roix1+1)/hbin;
return cols;
}
bool TestDriver::isDouble()
{
return false;
}
void TestDriver::update(){}
void TestDriver::getSettings()
{
roix1 = 1;
roiy1 = 1;
roix2 = 512;
roiy2 = 512;
hbin = 1;
vbin = 1;
}
}