-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathtransfer.cpp
128 lines (98 loc) · 2.96 KB
/
transfer.cpp
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
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
#include "sap.h"
#include "transfer.h"
SapAcqToBufWrapper SapAcqToBuf_New(SapAcquisitionWrapper acq, SapBufferWrapper buf, SapXferContextWrapper context) {
return new SapAcqToBuf(acq, buf, goxferhandler, context);
}
void SapAcqToBuf_Delete(SapAcqToBufWrapper trs) {
delete trs;
}
bool SapAcqToBuf_Create(SapAcqToBufWrapper trs) {
return trs->Create();
}
bool SapAcqToBuf_Destroy(SapAcqToBufWrapper trs) {
return trs->Destroy();
}
bool SapAcqToBuf_Grab(SapAcqToBufWrapper trs) {
return trs->Grab();
}
bool SapAcqToBuf_Snap(SapAcqToBufWrapper trs) {
return trs->Snap(16);
}
bool SapAcqToBuf_IsGrabbing(SapAcqToBufWrapper trs) {
return trs->IsGrabbing();
}
bool SapAcqToBuf_Freeze(SapAcqToBufWrapper trs) {
return trs->Freeze();
}
bool SapAcqToBuf_Abort(SapAcqToBufWrapper trs) {
return trs->Abort();
}
bool SapAcqToBuf_Wait(SapAcqToBufWrapper trs, int ms) {
return trs->Wait(ms);
}
const char* SapAcqToBuf_GetLastStatus(SapAcqToBufWrapper trs) {
return trs->GetLastStatus();
}
bool SapAcqToBuf_SetCallbackInfo(SapAcqToBufWrapper trs, SapXferContextWrapper context) {
return trs->SetCallbackInfo(goxferhandler, context);
}
bool SapAcqToBuf_UnregisterCallback(SapAcqToBufWrapper trs) {
return trs->UnregisterCallback();
}
SapXferContextWrapper SapXferContext_New() {
return new SapXferContext;
}
void SapXferContext_Delete(SapXferContextWrapper ctx) {
delete ctx;
}
void SapXferContext_SetID(SapXferContextWrapper ctx, int id) {
ctx->id = id;
return;
}
int SapXferContext_GetID(SapXferContextWrapper ctx) {
return ctx->id;
}
void SapXferContext_SetBuffer(SapXferContextWrapper ctx, SapBufferWrapper buf) {
ctx->buffer = buf;
return;
}
SapBufferWrapper SapXferContext_GetBuffer(SapXferContextWrapper ctx) {
return ctx->buffer;
}
void SapXferContext_SetHeight(SapXferContextWrapper ctx, int height) {
ctx->height = height;
return;
}
int SapXferContext_GetHeight(SapXferContextWrapper ctx) {
return ctx->height;
}
void SapXferContext_SetWidth(SapXferContextWrapper ctx, int width) {
ctx->width = width;
return;
}
int SapXferContext_GetWidth(SapXferContextWrapper ctx) {
return ctx->width;
}
void SapXferContext_SetPixelDepth(SapXferContextWrapper ctx, int depth) {
ctx->pixeldepth = depth;
return;
}
int SapXferContext_GetPixelDepth(SapXferContextWrapper ctx) {
return ctx->pixeldepth;
}
void SapXferContext_SetCounter(SapXferContextWrapper ctx, long count) {
ctx->counter = count;
return;
}
long SapXferContext_GetCounter(SapXferContextWrapper ctx) {
return ctx->counter;
}
SapXferContextWrapper SapXferCallbackInfo_GetContext(SapXferCallbackInfoWrapper cbinfo) {
return (SapXferContextWrapper)cbinfo->GetContext();
}
SapXferFrameRateInfoWrapper SapAcqToBuf_GetFrameRateStatistics(SapAcqToBufWrapper trs) {
return trs->GetFrameRateStatistics();
}
int SapXferFrameRateInfo_GetBufferFrameRate(SapXferFrameRateInfoWrapper inf) {
return inf->GetBufferFrameRate();
}