pyobs-flipro 1.2.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
lib/libflipro.h ADDED
@@ -0,0 +1,3820 @@
1
+ ///
2
+ /// @file libflipro.h
3
+ ///
4
+ /// @brief Finger Lakes Instrumentation Camera API
5
+ ///
6
+ /// The library uses the standard way of creating macros which make exporting
7
+ /// from a DLL simpler. All files within this DLL are compiled with the LIBFLIPRO_EXPORTS
8
+ /// symbol defined on the command line. This symbol should not be defined on any project
9
+ /// that uses this DLL. This way any other project whose source files include this file see
10
+ /// LIBFLIPRO_API functions as being imported from a DLL, whereas this DLL sees symbols
11
+ /// defined with this macro as being exported.
12
+ ///
13
+
14
+ #ifdef __cplusplus
15
+ extern "C" {
16
+ #endif
17
+
18
+ #ifndef _LIBFLIPRO_H_
19
+ /// @cond DO_NOT_DOCUMENT
20
+ #define _LIBFLIPRO_H_
21
+ /// @endcond
22
+
23
+ #ifdef __linux__
24
+ #include <wchar.h>
25
+ #include <stdarg.h>
26
+ #endif
27
+ #include "stdbool.h"
28
+ #include "stdint.h"
29
+
30
+ // The following ifdef block is the standard way of creating macros which make exporting
31
+ // from a DLL simpler. All files within this DLL are compiled with the LIBFLIPRO_EXPORTS
32
+ // symbol defined on the command line. This symbol should not be defined on any project
33
+ // that uses this DLL. This way any other project whose source files include this file see
34
+ // LIBFLIPRO_API functions as being imported from a DLL, whereas this DLL sees symbols
35
+ // defined with this macro as being exported.
36
+ /// @cond DO_NOT_DOCUMENT
37
+ #if defined(_WIN32) || defined(_WINDOWS)
38
+ #ifdef LIBFLIPRO_EXPORTS
39
+ #define LIBFLIPRO_API __declspec(dllexport) int32_t
40
+ #define LIBFLIPRO_API_DATA __declspec(dllexport)
41
+ #define LIBFLIPRO_VOID __declspec(dllexport) void
42
+ #else
43
+ #define LIBFLIPRO_API __declspec(dllimport) int32_t
44
+ #define LIBFLIPRO_API_DATA __declspec(dllimport)
45
+ #define LIBFLIPRO_VOID __declspec(dllimport) void
46
+ #endif
47
+
48
+ #endif
49
+
50
+ #ifdef __linux__
51
+ #define LIBFLIPRO_API int32_t
52
+ #define LIBFLIPRO_API_DATA
53
+ #define LIBFLIPRO_VOID void
54
+ #endif
55
+ /// @endcond
56
+
57
+ ////////////////////////////////////////////////////////////////////////
58
+ // Typedefs, Defines, Macros
59
+ ////////////////////////////////////////////////////////////////////////
60
+ // Version information
61
+ /// @cond DO_NOT_DOCUMENT
62
+ #define FPRO_API_VERSION_MAJOR (1)
63
+ #define FPRO_API_VERSION_MINOR (12) // Should change if must change the Camera side as well
64
+ #define FPRO_API_VERSION_BUILD (59) // Minor changes not requiring Camera change
65
+ /// @endcond
66
+
67
+ //
68
+ // Some Helpful #defines
69
+ ///
70
+ /// @brief Convert image size in Bytes to Pixels
71
+ ///
72
+ /// The frame size is 1.5 * width * height (12 bit pixels)
73
+ /// This macro only works if the pixel size is 12 bits.
74
+ #define FPRO_IMAGE_FRAMEBYTES_TO_PIXELS(__framebytes) (((__framebytes) << 1) / 3)
75
+ ///
76
+ /// @brief Convert Pixels to Image size in Bytes
77
+ ///
78
+ /// This macro only works if the pixel size is 12 bits.
79
+ #define FPRO_IMAGE_PIXELS_TO_FRAMEBYTES(__pixels) (((__pixels) & 0x1) ? ((((__pixels) * 3 ) >> 1) + 1) : (((__pixels) * 3 ) >> 1))
80
+ ///
81
+ /// @brief Convert image dimensions in Pixels to Image size in Bytes
82
+ ///
83
+ /// This macro only works if the pixel size is 12 bits.
84
+ #define FPRO_IMAGE_DIMENSIONS_TO_FRAMEBYTES(__width,__height) FPRO_IMAGE_PIXELS_TO_FRAMEBYTES((__width) * (__height))
85
+ ///
86
+ /// @brief Maximum number of pre/post frame Reference rows supported by the API.
87
+ ///
88
+ /// This number should be treated as a constant.
89
+ #define FPRO_REFERENCE_ROW_MAX (4094)
90
+ ///
91
+ /// @brief Height of Thumbnail image in pixels.
92
+ #define FPRO_THUMBNAIL_ROWS (512)
93
+ ///
94
+ /// @brief Width of Thumbnail image in pixels.
95
+ #define FPRO_THUMBNAIL_COLUMNS (512)
96
+ ///
97
+ /// @brief Max pixel depth
98
+ ///
99
+ /// Use this macro to extract the Max Pixel depth supported by
100
+ /// the device from the FPROCAP capabilities structure.
101
+ ///
102
+ #define FPRO_GET_MAX_PIXEL_DEPTH(__pCapCam, __uiMax) { \
103
+ if (__pCapCam) \
104
+ { \
105
+ for (int __ix = 0; __ix < 32; ++__ix) \
106
+ if (__pCapCam->uiAvailablePixelDepths & (1 << __ix)) \
107
+ __uiMax = __ix + 1; \
108
+ } \
109
+ else \
110
+ { \
111
+ __uiMax = 12; \
112
+ } \
113
+ }
114
+
115
+
116
+ ///
117
+ /// @brief Known Device Types
118
+ /// @enum FPRODEVICETYPE
119
+ ///
120
+ /// These constants are returned in the Device Capabilities Structure
121
+ /// FPROCAP in the uiDeviceType field.
122
+ /// See the user manual for a description of the capabilities for
123
+ /// your device.
124
+ ///
125
+ /// @var FPRODEVICETYPE::FPRO_CAM_DEVICE_TYPE_GSENSE400
126
+ /// @brief Enum value = 0x01000400
127
+ /// @var FPRODEVICETYPE::FPRO_CAM_DEVICE_TYPE_GSENSE2020
128
+ /// @brief Enum value = 0x01002020
129
+ /// @var FPRODEVICETYPE::FPRO_CAM_DEVICE_TYPE_GSENSE4040
130
+ /// @brief Enum value = 0x01004040
131
+ /// @var FPRODEVICETYPE::FPRO_CAM_DEVICE_TYPE_KODAK47051
132
+ /// @brief Enum value = 0x02047051
133
+ /// @var FPRODEVICETYPE::FPRO_CAM_DEVICE_TYPE_KODAK29050
134
+ /// @brief Enum value = 0x02029050
135
+ /// @var FPRODEVICETYPE::FPRO_CAM_DEVICE_TYPE_DC230_42
136
+ /// @brief Enum value = 0x03023042
137
+ /// @var FPRODEVICETYPE::FPRO_CAM_DEVICE_TYPE_DC230_84
138
+ /// @brief Enum value = 0x03023084
139
+ /// @var FPRODEVICETYPE::FPRO_CAM_DEVICE_TYPE_SONYIMX183
140
+ /// @brief Enum value = 0x04000183
141
+ /// @var FPRODEVICETYPE::FPRO_CAM_DEVICE_TYPE_FTM
142
+ /// @brief Enum value = 0x04000F1F
143
+ ///
144
+
145
+ typedef enum
146
+ {
147
+ FPRO_CAM_DEVICE_TYPE_GSENSE400 = 0x01000400,
148
+ FPRO_CAM_DEVICE_TYPE_GSENSE2020 = 0x01002020,
149
+ FPRO_CAM_DEVICE_TYPE_GSENSE4040 = 0x01004040,
150
+ FPRO_CAM_DEVICE_TYPE_GSENSE6060 = 0x01006060,
151
+ FPRO_CAM_DEVICE_TYPE_KODAK47051 = 0x02047051,
152
+ FPRO_CAM_DEVICE_TYPE_KODAK29050 = 0x02029050,
153
+ FPRO_CAM_DEVICE_TYPE_DC230_42 = 0x03023042,
154
+ FPRO_CAM_DEVICE_TYPE_DC230_84 = 0x03023084,
155
+ FPRO_CAM_DEVICE_TYPE_DC4320 = 0x03004320,
156
+ FPRO_CAM_DEVICE_TYPE_SONYIMX183 = 0x04000183,
157
+ FPRO_CAM_DEVICE_TYPE_FTM = 0x04000F1F
158
+
159
+ } FPRODEVICETYPE;
160
+
161
+ ///
162
+ /// @brief Maximum String Length
163
+ ///
164
+ /// The maximum number of characters (not bytes) allowed in USB strings throughout
165
+ /// the API.
166
+ ///
167
+ #define FPRO_USB_STRING_MAXLEN (256)
168
+
169
+ ///
170
+ /// @brief Maximum path length for low level OS device path
171
+ ///
172
+ /// The maximum number of characters (not bytes) allowed for device path
173
+ /// strings throughout the API.
174
+ ///
175
+ #define FPRO_DEVICE_MAX_PATH_LENGTH (1024)
176
+
177
+ ///
178
+ /// @brief Supported Connection Types
179
+ /// @enum FPROCONNECTION
180
+ ///
181
+ /// This enumeration is used as part of the FPRODEVICEINFO structure to
182
+ /// return the physical connection type to the camera.
183
+ ///
184
+ /// @var FPROCONNECTION::FPRO_CONNECTION_USB
185
+ /// @brief Camera is connected with a USB link.
186
+ ///
187
+ /// @var FPROCONNECTION::FPRO_CONNECTION_FIBRE
188
+ /// @brief Camera is connected with a Fibre Optic link.
189
+ ///
190
+ typedef enum
191
+ {
192
+ FPRO_CONNECTION_USB,
193
+ FPRO_CONNECTION_FIBRE,
194
+ } FPROCONNECTION;
195
+
196
+ ///
197
+ /// @brief Known USB Connection Speeds
198
+ /// @enum FPROUSBSPEED
199
+ ///
200
+ /// This enumeration is used as part of the FPRODEVICEINFO structure to
201
+ /// return the detected USB connection speed. FLI Cameras require a
202
+ /// FPRO_USB_SUPERSPEED USB connection in order to transfer image data reliably.
203
+ ///
204
+ /// @var FPROUSBSPEED::FPRO_USB_FULLSPEED
205
+ /// @brief Full Speed Connection
206
+ ///
207
+ /// @var FPROUSBSPEED::FPRO_USB_HIGHSPEED
208
+ /// @brief High Speed Connection
209
+ ///
210
+ /// @var FPROUSBSPEED::FPRO_USB_SUPERSPEED
211
+ /// @brief Super Speed Connection
212
+ ///
213
+ typedef enum
214
+ {
215
+ FPRO_USB_FULLSPEED,
216
+ FPRO_USB_HIGHSPEED,
217
+ FPRO_USB_SUPERSPEED
218
+ } FPROUSBSPEED;
219
+
220
+ ///
221
+ /// @typedef device_info_t FPRODEVICEINFO
222
+ /// @brief Device Information
223
+ ///
224
+ /// This is used as the Camera Device enumeration structure. It is
225
+ /// returned by the #FPROCam_GetCameraList function and contains the
226
+ /// list of detected cameras. To open a connection to a specific camera,
227
+ /// a single FPRODEVICEINFO structure is passed to the #FPROCam_Open function.
228
+ ///
229
+ /// @var FPRODEVICEINFO::cFriendlyName
230
+ /// @brief Human readable friendly name of the USB device.
231
+ /// This string along with the cSerialNo field provide a unique name
232
+ /// for your device suitable for a user interface.
233
+ /// @var FPRODEVICEINFO::cSerialNo
234
+ /// @brief The manufacturing serial number of the device.
235
+ /// @var FPRODEVICEINFO::cDevicePath
236
+ /// @brief The OS device Path. Used internally by the API for opening requisite file
237
+ /// descriptors to connect to the device.
238
+ /// @var FPRODEVICEINFO::eConnType
239
+ /// @brief The physical connection type. If the connection type is FPRO_CONNECTION_USB, then the
240
+ /// uiVendorId, uiProdId, and eUSBSpeed fields are also filled in. Otherwise those fields
241
+ /// are not used and their contents is undefined.
242
+ /// @var FPRODEVICEINFO::uiVendorId
243
+ /// @brief The USB vendor ID. This field is applicable only when the eCOnnType is #FPRO_CONNECTION_USB.
244
+ /// @var FPRODEVICEINFO::uiProdId
245
+ /// @brief The USB Product ID. This field is applicable only when the eCOnnType is #FPRO_CONNECTION_USB.
246
+ /// @var FPRODEVICEINFO::eUSBSpeed
247
+ /// @brief The USB connection speed of the device. This field is applicable only when the eCOnnType is #FPRO_CONNECTION_USB.
248
+ /// <br>NOTE: When connected through USB, FLI Cameras require a FPRO_USB_SUPERSPEED USB connection
249
+ /// in order to transfer image data reliably.
250
+ typedef struct device_info_t
251
+ {
252
+ wchar_t cFriendlyName[FPRO_USB_STRING_MAXLEN];
253
+ wchar_t cSerialNo[FPRO_USB_STRING_MAXLEN];
254
+ wchar_t cDevicePath[FPRO_DEVICE_MAX_PATH_LENGTH];
255
+ FPROCONNECTION eConnType;
256
+ uint32_t uiVendorId;
257
+ uint32_t uiProdId;
258
+ FPROUSBSPEED eUSBSpeed;
259
+ } FPRODEVICEINFO;
260
+
261
+
262
+ ///
263
+ /// @brief Version String Lengths
264
+ ///
265
+ /// Maximum length characters (not bytes) of version strings.
266
+ #define FPRO_VERSION_STRING_MAXLEN (32)
267
+ ///
268
+ /// @typedef device_version_info_t FPRODEVICEVERS
269
+ /// @brief Device Version Information
270
+ ///
271
+ /// Contains the various version numbers supplied by the device.
272
+ /// See #FPROCam_GetDeviceVersion.
273
+ ///
274
+ /// @var FPRODEVICEVERS::cFirmwareVersion
275
+ /// @brief The version of firmware on the internal device processor.
276
+ /// @var FPRODEVICEVERS::cFPGAVersion
277
+ /// @brief The version of firmware on the internal FPGA device.
278
+ /// @var FPRODEVICEVERS::cControllerVersion
279
+ /// @brief The version of firmware on the internal sensor controller device.
280
+ /// @var FPRODEVICEVERS::cHostHardwareVersion
281
+ /// @brief The version of firmware on the host interface card if any. For example,
282
+ /// it returns the hardware version of the Host PCIE card for Fibre connections.
283
+ /// For USB connections, there is no host side interface card so '0' is returned.
284
+ typedef struct device_version_info_t
285
+ {
286
+ wchar_t cFirmwareVersion[FPRO_VERSION_STRING_MAXLEN];
287
+ wchar_t cFPGAVersion[FPRO_VERSION_STRING_MAXLEN];
288
+ wchar_t cControllerVersion[FPRO_VERSION_STRING_MAXLEN];
289
+ wchar_t cHostHardwareVersion[FPRO_VERSION_STRING_MAXLEN];
290
+ } FPRODEVICEVERS;
291
+
292
+ ///
293
+ /// @enum FPROTESTIMAGETYPE
294
+ /// @brief Test Image Types
295
+ ///
296
+ /// Some cameras have the ability to generate test image data. This enumeration
297
+ /// is used to tell the camera how you would like the test image data to be
298
+ /// formatted. Not all cameras support all test image types. Consult you camera
299
+ /// documentation for more details on which test images are supported for your device.
300
+ ///
301
+ /// @var FPROTESTIMAGETYPE::FLI_TESTIMAGE_TYPE_ROW
302
+ /// @brief Row order format.
303
+ /// <br>The first 'width' number of pixels will be 0, the second 'width'
304
+ /// number of pixels will be 1... etc.
305
+ /// @var FPROTESTIMAGETYPE::FLI_TESTIMAGE_TYPE_COL
306
+ /// @brief Column order format.
307
+ /// <br>The first pixel of the first row will be 0, the second pixel will be 1...
308
+ /// the n'th pixel of the row will n. The first pixel of the second row
309
+ /// will be 0 again, followed by 1, etc...
310
+ /// @var FPROTESTIMAGETYPE::FLI_TESTIMAGE_IMX183_VERTICAL
311
+ /// @brief IMX183 Sensor Vertical Test Pattern.
312
+ /// @var FPROTESTIMAGETYPE::FLI_TESTIMAGE_IMX183_HORIZONTAL
313
+ /// @brief IMX183 Sensor Horizontal Test Pattern.
314
+ /// @var FPROTESTIMAGETYPE::FLI_TESTIMAGE_IMX183_ALL_LOW
315
+ /// @brief IMX183 Sensor All Low Test Pattern.
316
+ /// <br>All pixels are 0x000.
317
+ /// @var FPROTESTIMAGETYPE::FLI_TESTIMAGE_IMX183_ALL_HIGH
318
+ /// @brief IMX183 Sensor All High Test Pattern.
319
+ /// <br>All pixels are 0xFFF.
320
+ /// @var FPROTESTIMAGETYPE::FLI_TESTIMAGE_IMX183_LOW_HIGH
321
+ /// @brief IMX183 Sensor Repeating Low High Test Pattern.
322
+ /// <br>All pixels are 0x555.
323
+ /// @var FPROTESTIMAGETYPE::FLI_TESTIMAGE_IMX183_HIGH_LOW
324
+ /// @brief IMX183 Sensor Repeating High Low Test Pattern.
325
+ /// <br>All pixels are 0xAAA.
326
+ ///
327
+ typedef enum
328
+ {
329
+ FLI_TESTIMAGE_TYPE_ROW,
330
+ FLI_TESTIMAGE_TYPE_COL,
331
+ FLI_TESTIMAGE_IMX183_VERTICAL,
332
+ FLI_TESTIMAGE_IMX183_HORIZONTAL,
333
+ FLI_TESTIMAGE_IMX183_ALL_LOW,
334
+ FLI_TESTIMAGE_IMX183_ALL_HIGH,
335
+ FLI_TESTIMAGE_IMX183_LOW_HIGH,
336
+ FLI_TESTIMAGE_IMX183_HIGH_LOW
337
+ } FPROTESTIMAGETYPE;
338
+
339
+
340
+ ///
341
+ /// @enum FPROEXTTRIGTYPE
342
+ /// @brief External Trigger Types
343
+ ///
344
+ /// This enumeration defines the types of external triggers available.
345
+ /// There is a single external trigger line available to the camera. This
346
+ /// enumeration governs how this signal behaves. This enumeration is used with
347
+ /// the #FPROCtrl_GetExternalTriggerEnable and #FPROCtrl_SetExternalTriggerEnable API's.
348
+ ///
349
+ /// @var FPROEXTTRIGTYPE::FLI_EXT_TRIGGER_RISING_EDGE
350
+ /// @brief Trigger Exposure on Rising Edge
351
+ /// <br>For this setting, when the external trigger line goes from low to high, it
352
+ /// triggers the exposure to begin on the camera. The exposure will complete based
353
+ /// on the exposure time set with the FPROCtrl_SetExposure API.
354
+ /// @var FPROEXTTRIGTYPE::FLI_EXT_TRIGGER_FALLING_EDGE
355
+ /// @brief Trigger Exposure on Falling Edge
356
+ /// <br>For this setting, when the external trigger line goes from high to low, it
357
+ /// triggers the exposure to begin on the camera. The exposure will complete based
358
+ /// on the exposure time set with the FPROCtrl_SetExposure API.
359
+ /// @var FPROEXTTRIGTYPE::FLI_EXT_TRIGGER_EXPOSE_ACTIVE_HIGH
360
+ /// @brief Exposure Active High
361
+ /// <br>For this setting, the exposure is active the entire time the external trigger signal is high.
362
+ /// The exposure will complete when the external trigger line goes low or when the exposure time
363
+ /// has reached the value set with the FPROCtrl_SetExposure API (whichever occurs first).
364
+ /// That is, in this case the value used in the FPROCtrl_SetExposure API acts as a maximum exposure time.
365
+ /// @var FPROEXTTRIGTYPE::FLI_EXT_TRIGGER_EXPOSE_ACTIVE_LOW
366
+ /// @brief Exposure Active High
367
+ /// <br>For this setting, the exposure is active the entire time the external trigger signal is low.
368
+ /// The exposure will complete when the external trigger line goes high or when the exposure time
369
+ /// has reached the value set with the FPROCtrl_SetExposure API (whichever occurs first).
370
+ /// That is, in this case the value used in the FPROCtrl_SetExposure API acts as a maximum exposure time.
371
+ ///
372
+ typedef enum
373
+ {
374
+ FLI_EXT_TRIGGER_FALLING_EDGE,
375
+ FLI_EXT_TRIGGER_RISING_EDGE,
376
+ FLI_EXT_TRIGGER_EXPOSE_ACTIVE_LOW,
377
+ FLI_EXT_TRIGGER_EXPOSE_ACTIVE_HIGH
378
+ } FPROEXTTRIGTYPE;
379
+
380
+ ///
381
+ /// @typedef ext_trigger_info_t FPROEXTTRIGINFO
382
+ /// @brief External Trigger Setup Details
383
+ ///
384
+ /// This structure is used to set up the External Trigger capability on the camera.
385
+ /// See #FPROEXTTRIGTYPE for more information.
386
+ /// <br>
387
+ /// Note that the bSingleFramePerTrigger function is not avaliable on older cameras. This
388
+ /// function was introduced in the camera firmware versions 0x2A. In addition, in API versions
389
+ /// prior to 1.12.32, the API enforced an Image Count of 1 when enabling the external trigger.
390
+ /// <br>
391
+ ///
392
+ /// @var FPROEXTTRIGINFO::eTriggerType
393
+ /// @brief The trigger behaovior type.
394
+ /// @var FPROEXTTRIGINFO::bSingleFramePerTrigger
395
+ /// @brief Default behavior of the external trigger gets uiFrameCount images. Setting this ensures
396
+ /// only a single frame per trigger. see #FPROCtrl_SetExternalTriggerEnable() for the uiFrameCount parameter.
397
+ /// @var FPROEXTTRIGINFO::bEnable
398
+ /// @brief True= enable the external trigger. False= disable the external trigger.
399
+ typedef struct ext_trigger_info_t
400
+ {
401
+ FPROEXTTRIGTYPE eTriggerType;
402
+ bool bSingleFramePerTrigger;
403
+ bool bEnable;
404
+ } FPROEXTTRIGINFO;
405
+
406
+ ///
407
+ /// @enum FPRODBGLEVEL
408
+ /// @brief Debug Capability
409
+ ///
410
+ /// The API provides a debug interface. This sets the level of debug information
411
+ /// that can be logged by your application.
412
+ ///
413
+ /// @var FPRODBGLEVEL::FPRO_DEBUG_NONE
414
+ /// @brief All debug disabled
415
+ /// @var FPRODBGLEVEL::FPRO_DEBUG_ERROR
416
+ /// @brief Only ERROR level debug is output
417
+ /// @var FPRODBGLEVEL::FPRO_DEBUG_WARNING
418
+ /// @brief WARNING and ERROR debug is output
419
+ /// @var FPRODBGLEVEL::FPRO_DEBUG_INFO
420
+ /// @brief INFO, WARNING, and ERROR debug is output
421
+ /// @var FPRODBGLEVEL::FPRO_DEBUG_REGRW
422
+ /// @brief REGWR, INFO, WARNING, and ERROR debug is output
423
+ /// @var FPRODBGLEVEL::FPRO_DEBUG_DEBUG
424
+ /// @brief DEBUG, REGRW, INFO, WARNING, and ERROR debug is output
425
+ /// @var FPRODBGLEVEL::FPRO_DEBUG_TRACE
426
+ /// @brief TRACE, DEBUG, REGRW, INFO, WARNING, and ERROR debug is output
427
+ typedef enum
428
+ {
429
+ FPRO_DEBUG_NONE,
430
+ FPRO_DEBUG_ERROR,
431
+ FPRO_DEBUG_WARNING,
432
+ FPRO_DEBUG_INFO,
433
+ FPRO_DEBUG_REGRW,
434
+ FPRO_DEBUG_DEBUG,
435
+ FPRO_DEBUG_TRACE
436
+ } FPRODBGLEVEL;
437
+
438
+
439
+ ///
440
+ /// @enum FPROGPSSTATE
441
+ /// @brief GPS Connection State
442
+ ///
443
+ /// This enumeration defines the possible states of an optional GPS receiver attached
444
+ /// to the camera. The GPS data is contained in the Meta Data that prepends every image.
445
+ /// The format for the fields in the Meta Data is shown below:
446
+ /// <br>
447
+ /// <br><B>Timestamp</B><br>
448
+ /// @code
449
+ /// Year - 2016(31:26), Month(25:22), Days(21:17), Hours(16:12), Minutes(11:6), Seconds(5:0)
450
+ /// @endcode
451
+ /// <br><B>Longitude</B><br>
452
+ /// @code
453
+ /// East / West(31), 600000 * DDD + 10000 * MM.MMMM(31:0)
454
+ /// @endcode
455
+ /// Where bit 31 is 1 for East and 0 for West
456
+ /// <br>
457
+ /// <br><B>Latitude</B><br>
458
+ /// @code
459
+ /// North / South(31), 600000 * DD + 10000 * MM.MMMM(31:0)
460
+ /// @endcode
461
+ /// Where bit 31 is 1 for North and 0 for South
462
+ /// <br>
463
+ /// @var FPROGPSSTATE::FPRO_GPS_NOT_DETECTED
464
+ /// @brief GPS unit has not been detected by the camera.
465
+ /// @var FPROGPSSTATE::FPRO_GPS_DETECTED_NO_SAT_LOCK
466
+ /// @brief GPS unit has been detected by the camera but the satellite lock has not been made.
467
+ /// @var FPROGPSSTATE::FPRO_GPS_DETECTED_AND_SAT_LOCK
468
+ /// @brief GPS unit has been detected by the camera and the satellite lock has been made. This is the only
469
+ /// value that will provide accurate results in the Meta Data.
470
+ typedef enum
471
+ {
472
+ FPRO_GPS_NOT_DETECTED = 0,
473
+ FPRO_GPS_DETECTED_NO_SAT_LOCK,
474
+ FPRO_GPS_DETECTED_AND_SAT_LOCK
475
+
476
+ } FPROGPSSTATE;
477
+
478
+ ///
479
+ /// @enum FPROSENSREADCFG
480
+ /// @brief Sensor Read Out Configuration
481
+ ///
482
+ /// Some camera models support different physical imaging sensor read out configurations.
483
+ /// This enumeration allows setting and retrieving the sensor read out configuration through the
484
+ /// #FPROSensor_SetReadoutConfiguration() and #FPROSensor_GetReadoutConfiguration(). Consult your
485
+ /// camera user documentation for availability of this feature for your camera model.
486
+ /// <br>
487
+ /// For the Cobalt cameras that support this feature, you may select one of the channels or all four
488
+ /// of the channels. Selecting 2 or 3 channels is not allowed.
489
+ /// <br>
490
+ /// @var FPROSENSREADCFG::FPRO_SENSREAD_CB_TOPLEFT
491
+ /// @brief Read data using the top left channel of the sensor.
492
+ /// @var FPROSENSREADCFG::FPRO_SENSREAD_CB_TOPRIGHT
493
+ /// @brief Read data using the top right channel of the sensor.
494
+ /// @var FPROSENSREADCFG::FPRO_SENSREAD_CB_BOTTOMLEFT
495
+ /// @brief Read data using the bottom left channel of the sensor.
496
+ /// @var FPROSENSREADCFG::FPRO_SENSREAD_CB_BOTTOMRIGHT
497
+ /// @brief Read data using the bottom left channel of the sensor.
498
+ /// @var FPROSENSREADCFG::FPRO_SENSREAD_CB_ALL
499
+ /// @brief Read data using all 4 sensor channels.
500
+ typedef enum
501
+ {
502
+ FPRO_SENSREAD_CB_BOTTOMLEFT = 0x01,
503
+ FPRO_SENSREAD_CB_BOTTOMRIGHT = 0x02,
504
+ FPRO_SENSREAD_CB_TOPLEFT = 0x04,
505
+ FPRO_SENSREAD_CB_TOPRIGHT = 0x08,
506
+ FPRO_SENSREAD_CB_ALL = 0x0F
507
+ } FPROSENSREADCFG;
508
+
509
+ //
510
+ /// @brief Sensor Mode Name Length
511
+ ///
512
+ /// Max allowed name length for Camera Modes. See #FPROSENSMODE
513
+ ///
514
+ #define FPRO_SENSOR_MODE_NAME_LENGTH (32)
515
+
516
+ ///
517
+ /// @typedef sensor_mode_t FPROSENSMODE
518
+ /// @brief Sensor Modes
519
+ ///
520
+ /// The FLI Camera devices support the concept of 'Modes'. A mode is a collection
521
+ /// of settings for the camera. As this structure illustrates, the mode has a
522
+ /// name and an index. The name can be used primarily for a user interface so that
523
+ /// a user can see a friendly and descriptive name for the mode. The index is used by
524
+ /// the API to set a particular mode on the camera. See #FPROSensor_SetMode, #FPROSensor_GetMode,
525
+ /// and #FPROSensor_GetModeCount.
526
+ ///
527
+ /// @var FPROSENSMODE::uiModeIndex
528
+ /// @brief The corresponding index of the mode name.
529
+ /// @var FPROSENSMODE::wcModeName
530
+ /// @brief A descriptive human readable name for the mode suitable for
531
+ /// a user interface.
532
+ typedef struct sensor_mode_t
533
+ {
534
+ uint32_t uiModeIndex;
535
+ wchar_t wcModeName[FPRO_SENSOR_MODE_NAME_LENGTH];
536
+ } FPROSENSMODE;
537
+
538
+
539
+ ///
540
+ /// @brief Gain Scale Factor
541
+ ///
542
+ /// All gain table values (see #FPROGAINTABLE) returned by the API are scaled
543
+ /// by the factor #FPRO_GAIN_SCALE_FACTOR.
544
+ #define FPRO_GAIN_SCALE_FACTOR (1000)
545
+
546
+ ///
547
+ /// @enum FPROGAINTABLE
548
+ /// @brief Gain Tables
549
+ ///
550
+ /// The camera makes available specific gain values for the image sensor.
551
+ /// Each set of values is stored in a table and this enum allows you to pick
552
+ /// the desired gain table to get using the function #FPROSensor_GetGainTable.
553
+ /// The values in the table can be used as part of a user interface allowing users
554
+ /// to select a specific gain setting. The settings are retrieved and set by index
555
+ /// in the gain table using #FPROSensor_GetGainIndex and #FPROSensor_SetGainIndex.
556
+ /// <br><br> Note that all gain table values returned by the API are scaled by the factor #FPRO_GAIN_SCALE_FACTOR.
557
+ ///
558
+ /// @var FPROGAINTABLE::FPRO_GAIN_TABLE_LOW_CHANNEL
559
+ /// @brief Low Gain Channel used for Low Gain images in HDR modes.
560
+ /// @var FPROGAINTABLE::FPRO_GAIN_TABLE_HIGH_CHANNEL
561
+ /// @brief High Gain Channel used for LDR modes
562
+ /// <br>NOTE: Different cameras support different gain settings. The number of gain settings for
563
+ /// the camera are stored in the device Capabilities structure #FPROCAP.
564
+ typedef enum
565
+ {
566
+ FPRO_GAIN_TABLE_LOW_CHANNEL,
567
+ FPRO_GAIN_TABLE_HIGH_CHANNEL,
568
+
569
+ FPRO_GAIN_TABLE_CHANNEL_NUM,
570
+ } FPROGAINTABLE;
571
+
572
+ ///
573
+ /// @typedef gain_value_t FPROGAINVALUE
574
+ /// @brief Gain Value
575
+ ///
576
+ /// The function #FPROSensor_GetGainTable returns a list of FPROGAINVALUE
577
+ /// items. The uiDeviceIndex must be used to set the desired gain on the camera
578
+ /// using the #FPROSensor_SetGainIndex function.
579
+ ///
580
+ /// @var FPROGAINVALUE::uiValue
581
+ /// @brief The actual gain value.
582
+ /// @var FPROGAINVALUE::uiDeviceIndex
583
+ /// @brief The device index to use to set the gain value on the camera.
584
+ typedef struct gain_value_t
585
+ {
586
+ uint32_t uiValue;
587
+ uint32_t uiDeviceIndex;
588
+ } FPROGAINVALUE;
589
+
590
+ ///
591
+ /// @enum FPROBLACKADJUSTCHAN
592
+ /// @brief Black Adjust Channels
593
+ ///
594
+ /// Depending on the camera model, multiple channels may be supported with respect to Black Level and Black Sun adjustment.
595
+ /// This enumeration lists the appropriate channels supported by the API. They are meant for use with the
596
+ /// #FPROSensor_GetBlackLevelAdjustEx, #FPROSensor_GetBlackSunAdjustEx, #FPROSensor_SetBlackLevelAdjustEx, and #FPROSensor_SetBlackSunAdjustEx
597
+ /// API calls to specify the channel for the adjustment.
598
+ /// <br><br>
599
+ ///
600
+ /// @var FPROBLACKADJUSTCHAN::FPRO_BLACK_ADJUST_CHAN_LDR
601
+ /// @brief Specifies the LDR Black adjust channel.
602
+ /// @var FPROBLACKADJUSTCHAN::FPRO_BLACK_ADJUST_CHAN_HDR
603
+ /// @brief Specifies the HDR Black adjust channel.
604
+ /// <br>NOTE: Not supported on all devices. See your specific device documentation for details.
605
+ typedef enum
606
+ {
607
+ FPRO_BLACK_ADJUST_CHAN_LDR,
608
+ FPRO_BLACK_ADJUST_CHAN_HDR,
609
+ } FPROBLACKADJUSTCHAN;
610
+
611
+ // Camera Capabilities
612
+ #pragma pack(push, 1)
613
+ ///
614
+ /// @typedef camera_capabilities_t FPROCAP
615
+ /// @brief Camera Capabilities
616
+ ///
617
+ /// The camera capabilities structure is a structure provided by the camera that
618
+ /// publishes a set of camera capabilities. The structure is retrieved using the
619
+ /// #FPROSensor_GetCapabilities API.
620
+ /// <br>
621
+ /// Different camera models offer different sets of capabilities based on the
622
+ /// imaging sensor and other hardware attributes. The values in this structure can
623
+ /// be used by an application to configure settings and user interfaces based
624
+ /// on the specific camera model that is connected. The uiDeviceType member is a
625
+ /// specific device type, one of #FPRODEVICETYPE, that allows further checking
626
+ /// by an application as it can cover specific functionality not described by
627
+ /// this structure. The uIDeviceType number maps to a specific camera model. As such,
628
+ /// you can use this number along with the user documentation provided for the
629
+ /// associated camera model to determine specific functionality not covered here.
630
+ /// <br>
631
+ /// <br>
632
+ /// Reference Rows: The Pre and Post frame reference row fields in the capabilities
633
+ /// structure is the number of physical pre/post imaging sensor cells available for
634
+ /// the camera model. For pre-frame reference row, this is a hard number. That is,
635
+ /// no more pre-frame reference rows may be requested in an image frame than specified
636
+ /// by this number. For post-frame reference rows, additional reference rows may be
637
+ /// requested in an image frame. The post-frame number is just provided to indicate the
638
+ /// number of physical rows available.
639
+ /// <br>
640
+ /// <br>
641
+ /// Dummy Pixels: For API versions up to 1.10.x, the uiDummyPixelNum field contained the
642
+ /// Dummy pixels pixels appended to specified rows (post row). From API versions 1.11.x and onward, the
643
+ /// value is divided into two 16 bit quantities. The upper 16 bits contains the Pre-Row Dummy Pixels
644
+ /// and the lower 16 bits contains the Post Row Dummy Pixels. Note for this to be completely functional,
645
+ /// your camera firmware version must also be version 1.11.x or newer.
646
+ typedef struct camera_capabilities_t
647
+ {
648
+ uint32_t uiSize; ///< Size of this structure (including uiSize)
649
+ uint32_t uiCapVersion; ///< Version of this structure
650
+ uint32_t uiDeviceType; ///< General device type- see documentation
651
+ uint32_t uiMaxPixelImageWidth; ///< Max allowed image width in pixels
652
+ uint32_t uiMaxPixelImageHeight; ///< max allowed image height in pixels
653
+ uint32_t uiAvailablePixelDepths; ///< Bit is set if pixel depth allowed (lsb= pixel depth 1)
654
+ uint32_t uiBinningsTableSize; ///< 0= 1:1 binning only
655
+ uint32_t uiBlackLevelMax; ///< Max Value Allowed (see #FPROSensor_SetBlackLevelAdjust())
656
+ uint32_t uiBlackSunMax; ///< Max Value Allowed (see #FPROSensor_SetBlackSunAdjust())
657
+ uint32_t uiLowGain; ///< Number of Gain Values (Low Gain channel for low gain frame in HDR Modes)
658
+ uint32_t uiHighGain; ///< Number Of Gain Values (High Gain channel for LDR Modes)
659
+ uint32_t uiReserved; ///< Reserved
660
+ uint32_t uiRowScanTime; ///< Row Scan Time in nano secs (LDR)
661
+ uint32_t uiDummyPixelNum; ///< Number of Pre and Post Row Dummy Pixels when enabled. See #FPROFrame_SetDummyPixelEnable
662
+ bool bHorizontalScanInvertable; ///< False= Normal scan direction only, True= Inverse Scan Available
663
+ bool bVerticalScanInvertable; ///< False= Normal scan direction only, True= Inverse Scan Available
664
+ uint32_t uiNVStorageAvailable; ///< Number of bytes of Non-Volatile Storage available on the camera
665
+ uint32_t uiPreFrameReferenceRows; ///< Number of Pre-Frame Reference rows available
666
+ uint32_t uiPostFrameReferenceRows; ///< Number of Post-Frame Reference rows available
667
+ uint32_t uiMetaDataSize; ///< Number of bytes used for the pre-frame image meta data
668
+
669
+ } FPROCAP;
670
+ #pragma pack(pop)
671
+
672
+
673
+ // Auxiliary I/O
674
+ /// @enum FPROAUXIO
675
+ /// @brief Auxiliary I/O Pins
676
+ ///
677
+ /// The camera makes available auxiliary I/O pins for customer defined use. This enum simply
678
+ /// assigns a name for each of the pins to be used in the FPROAuxIO_xxx() set of API calls.
679
+ /// <br><br> Note that different camera models can support different Aux I/O pins. Consult your
680
+ /// specific camera documentation for supported pins and physical pin outs.
681
+ ///
682
+ /// @var FPROAUXIO::FPRO_AUXIO_1
683
+ /// @brief Name for AUX I/O Pin 1
684
+ /// @var FPROAUXIO::FPRO_AUXIO_2
685
+ /// @brief Name for AUX I/O Pin 2
686
+ /// @var FPROAUXIO::FPRO_AUXIO_3
687
+ /// @brief Name for AUX I/O Pin 3
688
+ /// @var FPROAUXIO::FPRO_AUXIO_4
689
+ /// @brief Name for AUX I/O Pin 4
690
+ ///
691
+ typedef enum
692
+ {
693
+ FPRO_AUXIO_1= 0x01,
694
+ FPRO_AUXIO_2= 0x02,
695
+ FPRO_AUXIO_3= 0x04,
696
+ FPRO_AUXIO_4= 0x08,
697
+ } FPROAUXIO;
698
+
699
+ /// @enum FPROAUXIO_DIR
700
+ /// @brief Auxiliary I/O Pin Direction
701
+ ///
702
+ /// The camera makes available auxiliary I/O pins for customer defined use. The pins can be defined
703
+ /// as inputs or outputs. This enum is to be used with the FPROAuxIO_xxx() set of API calls to set the
704
+ /// direction of a given AUX I/O pin. See #FPROAUXIO for more information.
705
+ /// <br><br> Note that different camera models can support different Aux I/O pins. Consult your
706
+ /// specific camera documentation for supported pins and physical pin outs.
707
+ ///
708
+ /// @var FPROAUXIO_DIR::FPRO_AUXIO_DIR_IN
709
+ /// @brief Set AUX I/O pin as an input with respect to the camera.
710
+ /// @var FPROAUXIO_DIR::FPRO_AUXIO_DIR_OUT
711
+ /// @brief Set AUX I/O pin as an output with respect to the camera.
712
+ typedef enum
713
+ {
714
+ FPRO_AUXIO_DIR_IN= 0,
715
+ FPRO_AUXIO_DIR_OUT,
716
+ } FPROAUXIO_DIR;
717
+
718
+ /// @enum FPROAUXIO_STATE
719
+ /// @brief Auxiliary Output State
720
+ ///
721
+ /// The camera makes available auxiliary I/O pins for customer defined use. The pins can be defined
722
+ /// as inputs or outputs. For pins defined as outputs, this enum is to be used with the FPROAuxIO_xxx()
723
+ /// set of API calls to set the state of that pin. See #FPROAUXIO for more information.
724
+ /// <br><br> Note that different camera models can support different Aux I/O pins. Consult your
725
+ /// specific camera documentation for supported pins and physical pin outs.
726
+ ///
727
+ /// @var FPROAUXIO_STATE::FPRO_AUXIO_STATE_LOW
728
+ /// @brief Pin is in the low state.
729
+ /// @var FPROAUXIO_STATE::FPRO_AUXIO_STATE_HIGH
730
+ /// @brief Pin is in the high state.
731
+ typedef enum
732
+ {
733
+ FPRO_AUXIO_STATE_LOW,
734
+ FPRO_AUXIO_STATE_HIGH,
735
+ } FPROAUXIO_STATE;
736
+
737
+
738
+ /// @enum FPROAUXIO_EXPACTIVETYPE
739
+ /// @brief Exposure Active Auxiliary Output
740
+ ///
741
+ /// The camera makes available an auxiliary output pin that signals when an exposure is active. This
742
+ /// enum defines the the set of signal types that may be configured for the output. Consult your
743
+ /// specific camera documentation for the timing details of each of these signal types.
744
+ /// <br><br> Note that different camera models can support different Aux I/O pins. Consult your
745
+ /// specific camera documentation for supported pins and physical pin outs.
746
+ ///
747
+ /// @var FPROAUXIO_EXPACTIVETYPE::FPRO_AUXIO_EXPTYPE_EXPOSURE_ACTIVE
748
+ /// @brief Exposure Active- consult your camera documentation for timing details.
749
+ /// @var FPROAUXIO_EXPACTIVETYPE::FPRO_AUXIO_EXPTYPE_GLOBAL_EXPOSURE_ACTIVE
750
+ /// @brief Global Exposure Active- consult your camera documentation for timing details.
751
+ /// @var FPROAUXIO_EXPACTIVETYPE::FPRO_AUXIO_EXPTYPE_FIRST_ROW_SYNC
752
+ /// @brief First Row Sync- consult your camera documentation for timing details.
753
+ typedef enum
754
+ {
755
+ FPRO_AUXIO_EXPTYPE_EXPOSURE_ACTIVE= 0,
756
+ FPRO_AUXIO_EXPTYPE_GLOBAL_EXPOSURE_ACTIVE,
757
+ FPRO_AUXIO_EXPTYPE_FIRST_ROW_SYNC,
758
+ FPRO_AUXIO_EXPTYPE_RESERVED
759
+ } FPROAUXIO_EXPACTIVETYPE;
760
+
761
+
762
+ /// @typedef FPROSTREAMERSTATUS
763
+ /// @brief Streamer Status
764
+ ///
765
+ /// The FLI Camera devices support the ability to stream images to disk.
766
+ /// The FPROFrame_Streamxxx() API's are used to enable, start, and stop the streaming process.
767
+ /// In addition, #FPROFrame_StreamGetStatistics() is provided to retrieve the current stream
768
+ /// statistics. The status is part of the #FPROSTREAMSTATS statistics returned by the
769
+ /// #FPROFrame_StreamGetStatistics() API. Note that this status is with respect to images
770
+ /// arriving from the camera. Multiple frames can be received and queued to be written to disk.
771
+ /// As such, in order to correctly determine when all images have been received and written
772
+ /// to the disk, you need to check the #FPROSTREAMSTATS uiDiskFramesWritten field and make sure it
773
+ /// matches the number of images you requested. If you stop the stream before all frames are
774
+ /// written to the disk, any frames not fully written will be lost.
775
+ ///
776
+ /// @var FPROSTREAMERSTATUS::FPRO_STREAMER_STOPPED
777
+ /// @brief Streaming Stopped. This is the default state. It also enters this state when the
778
+ /// requested number of images have been streamed or #FPROFrame_StreamStop() is called.
779
+ /// @var FPROSTREAMERSTATUS::FPRO_STREAMER_STREAMING
780
+ /// @brief Streaming is running. This state is entered when streaming is started via the FPROFrame_StreamStart() API.
781
+ /// It remains in this state until #FPROFrame_StreamStop() is called, the requested number of images have been streamed, or
782
+ /// an error has caused streaming to stop.
783
+ /// @var FPROSTREAMERSTATUS::FPRO_STREAMER_STOPPED_ERROR
784
+ /// @brief If streaming has stopped due to an error, the status will be less than 0. Consult the log file for error messages.
785
+ typedef enum
786
+ {
787
+ FPRO_STREAMER_STOPPED_ERROR = -1,
788
+ FPRO_STREAMER_STOPPED= 0,
789
+ FPRO_STREAMER_STREAMING,
790
+
791
+ } FPROSTREAMERSTATUS;
792
+
793
+
794
+ ///
795
+ /// @typedef fpro_stream_stats_t FPROSTREAMSTATS
796
+ /// @brief Streamer Statistics
797
+ ///
798
+ /// The FLI Camera devices support the ability to stream images to disk.
799
+ /// The FPROFrame_Streamxxx() API's are used to enable, start, and stop the streaming process.
800
+ /// In addition, #FPROFrame_StreamGetStatistics() is provided to retrieve the current stream
801
+ /// statistics in this structure. The statistics are reset each time #FPROFrame_StreamStart()
802
+ /// is called.
803
+ ///
804
+ /// @var FPROSTREAMSTATS::uiNumFramesReceived
805
+ /// @brief The number of frames received from the camera.
806
+ /// @var FPROSTREAMSTATS::uiTotalBytesReceived
807
+ /// @brief The total number of bytes received from the camera.
808
+ /// @var FPROSTREAMSTATS::uiDiskFramesWritten
809
+ /// @brief The total number of frames written to disk.
810
+ /// @var FPROSTREAMSTATS::dblDiskAvgMBPerSec
811
+ /// @brief The average disk write rate in MBytes/sec on a per frame basis
812
+ /// @var FPROSTREAMSTATS::dblDiskPeakMBPerSec
813
+ /// @brief The peak write rate in MBytes/sec; the fastest a given frame was written.
814
+ /// @var FPROSTREAMSTATS::dblOverallFramesPerSec
815
+ /// @brief The overall frames per second received by the streamer. Note this depends on actual
816
+ /// frame rate from the camera (e.g. exposure time, etc.). It is calculated simply by counting the
817
+ /// number of frames received a dividing by the time delta from when the streaming was started.
818
+ /// @var FPROSTREAMSTATS::dblOverallMBPerSec
819
+ /// @brief The overall MB per second received by the streamer. Note this depends on actual
820
+ /// frame rate from the camera (e.g. exposure time, etc.). Calculated similarly to dblOverallFramesPerSec.
821
+ /// @var FPROSTREAMSTATS::iStatus
822
+ /// @brief The status of the streamer. See #FPROSTREAMERSTATUS.
823
+ /// @var FPROSTREAMSTATS::uiReserved
824
+ /// @brief Reserved for internal use.
825
+ typedef struct fpro_stream_stats_t
826
+ {
827
+ uint32_t uiNumFramesReceived;
828
+ uint64_t uiTotalBytesReceived;
829
+ uint64_t uiDiskFramesWritten;
830
+ double dblDiskAvgMBPerSec;
831
+ double dblDiskPeakMBPerSec;
832
+ double dblOverallFramesPerSec;
833
+ double dblOverallMBPerSec;
834
+ FPROSTREAMERSTATUS iStatus;
835
+ uint32_t uiReserved;
836
+ } FPROSTREAMSTATS;
837
+
838
+ ///
839
+ /// @typedef fpro_stream_preview_info_t FPROPREVIEW
840
+ /// @brief Streamer Statistics For Preview Images
841
+ /// When obtaining a preview image while streaming, this structure
842
+ /// will contain the stream statistics for the image returned.
843
+ /// See #FPROFrame_StreamGetPreviewImageEx().
844
+ ///
845
+ /// @var FPROPREVIEW::uiFrameNumber
846
+ /// @brief The frame number returned in the preview.
847
+ /// @var FPROPREVIEW::streamStats
848
+ /// @brief The stream statistics. See #FPROSTREAMSTATS.
849
+ ///
850
+ typedef struct fpro_stream_preview_info_t
851
+ {
852
+ uint32_t uiFrameNumber;
853
+ FPROSTREAMSTATS streamStats;
854
+ } FPROPREVIEW;
855
+
856
+ /// @enum FPRO_FRAME_TYPE
857
+ /// @brief Image Frame Type
858
+ ///
859
+ /// The camera has the ability to produce different frame types. The default
860
+ /// frame type is FPRO_FRAMETYPE_NORMAL. Consult you camera documentation for
861
+ /// the details of each frame type and availability on a given camera model.
862
+ /// <br>
863
+ /// <br>
864
+ /// See #FPROFrame_SetFrameType() and #FPROFrame_GetFrameType().
865
+ /// <br>
866
+ ///
867
+ /// @var FPRO_FRAME_TYPE::FPRO_FRAMETYPE_NORMAL
868
+ /// @brief Normal Frame (default).
869
+ /// @var FPRO_FRAME_TYPE::FPRO_FRAMETYPE_DARK
870
+ /// @brief Dark Frame.
871
+ /// @var FPRO_FRAME_TYPE::FPRO_FRAMETYPE_BIAS
872
+ /// @brief Bias Frame.
873
+ /// @var FPRO_FRAME_TYPE::FPRO_FRAMETYPE_LIGHTFLASH
874
+ /// @brief Light Flash Frame.
875
+ /// @var FPRO_FRAME_TYPE::FPRO_FRAMETYPE_DARKFLASH
876
+ /// @brief Dark Flash Frame.
877
+ typedef enum
878
+ {
879
+ FPRO_FRAMETYPE_NORMAL= 0,
880
+ FPRO_FRAMETYPE_DARK,
881
+ FPRO_FRAMETYPE_BIAS,
882
+ FPRO_FRAMETYPE_LIGHTFLASH,
883
+ FPRO_FRAMETYPE_DARKFLASH,
884
+ } FPRO_FRAME_TYPE;
885
+
886
+ /// @enum FPROCMS
887
+ /// @brief Correlated Multiple Samples (Samples Per Pixel)
888
+ ///
889
+ /// Some camera models are capable of taking multiple sensor samples per pixel. Based
890
+ /// on imaging modes this can effect the amount of image data sent by the camera for
891
+ /// a frame of data. Consult your specific camera documentation for details on how this
892
+ /// feature is supported and its effect on image data. The values are used in the
893
+ /// #FPROSensor_GetSamplesPerPixel() and #FPROSensor_SetSamplesPerPixel() API calls.
894
+ ///
895
+ /// @var FPROCMS::FPROCMS_1
896
+ /// @brief Single Sample Per Pixel. This is the default for all cameras.
897
+ /// @var FPROCMS::FPROCMS_2
898
+ /// @brief Two sensor samples per pixel are read out.
899
+ /// @var FPROCMS::FPROCMS_4
900
+ /// @brief Four sensor samples per pixel are read out.
901
+ typedef enum
902
+ {
903
+ FPROCMS_1 = 0,
904
+ FPROCMS_2,
905
+ FPROCMS_4,
906
+ } FPROCMS;
907
+
908
+ /// @cond DO_NOT_DOCUMENT
909
+ /// Not implemented yet.
910
+ typedef struct crop_rect_t
911
+ {
912
+ uint32_t uiColumnOffset;
913
+ uint32_t uiRowOffset;
914
+ uint32_t uiWidth;
915
+ uint32_t uiHeight;
916
+ } FPRO_CROP;
917
+ /// @endcond
918
+
919
+
920
+ ///
921
+ /// @typedef ref_frames_t FPRO_REFFRAMES
922
+ /// @brief Reference Frames for Hardware Image Merging
923
+ ///
924
+ /// Version 2 and later of the PCIE Fibre interface allows for the image
925
+ /// merging process to be done in hardware on the host side PCIE Fibre interface card.
926
+ /// This structure is used to transfer the reference frames used in the processing. See
927
+ /// #FPROAlgo_SetHardwareMergeReferenceFrames and #FPROAlgo_SetHardwareMergeReferenceFiles for
928
+ /// additional information.
929
+ /// <br>
930
+ /// <br>
931
+ /// The format of the additive frames is a fixed point number with the lower 3 bits
932
+ /// being the decimal. The 16 bit quantity must be in Little Endian byte order.
933
+ /// <br>
934
+ /// The aditive frames are also referred to as Dark Signal Non-Uniformity (DSNU) frames.
935
+ /// <br>
936
+ /// <br>
937
+ /// The format of the multiply frames is a fixed point number with the lower 10 bits being the
938
+ /// decimal. For example, a vaue of 1.0 = 0x0400. These values must also be stored in
939
+ /// Little Endian byte order.
940
+ /// <br>
941
+ /// The multiplicative frames are also referred to as Photo Response Non-Uniformity (PRNU) frames.
942
+ /// <br>
943
+ ///
944
+ ///
945
+ /// @var FPRO_REFFRAMES::uiWidth
946
+ /// @brief Width of the frames in pixels.
947
+ /// @var FPRO_REFFRAMES::uiHeight
948
+ /// @brief Height of the frames in pixels.
949
+ /// @var FPRO_REFFRAMES::pAdditiveLowGain
950
+ /// @brief Low Gain Additive Reference Frame.
951
+ /// @var FPRO_REFFRAMES::pAdditiveHighGain
952
+ /// @brief High Gain Additive Reference Frame.
953
+ /// @var FPRO_REFFRAMES::pMultiplicativeLowGain
954
+ /// @brief Low Gain Multiply Reference Frame.
955
+ /// @var FPRO_REFFRAMES::pMultiplicativeHighGain
956
+ /// @brief High Gain Multiply Reference Frame.
957
+ typedef struct ref_frames_t
958
+ {
959
+ uint32_t uiWidth;
960
+ uint32_t uiHeight;
961
+
962
+ int16_t* pAdditiveLowGain;
963
+ int16_t* pAdditiveHighGain;
964
+ uint16_t* pMultiplicativeLowGain;
965
+ uint16_t* pMultiplicativeHighGain;
966
+ } FPRO_REFFRAMES;
967
+
968
+ ///
969
+ /// @typedef FPRO_IMAGE_FORMAT
970
+ /// @brief Output Frame Formats for image merging and conversion
971
+ ///
972
+ /// This enum is used by the merging algorithms and conversion functions
973
+ /// to specify the resultant image format of the operation.
974
+ /// @var FPRO_IMAGE_FORMAT::IFORMAT_RCD
975
+ /// @brief FLI native RCD Frame.
976
+ /// @var FPRO_IMAGE_FORMAT::IFORMAT_TIFF
977
+ /// @brief TIFF Formatted image.
978
+ /// @var FPRO_IMAGE_FORMAT::IFORMAT_FITS
979
+ /// @brief FITS formatted image.
980
+ typedef enum
981
+ {
982
+ IFORMAT_NONE = 0,
983
+ IFORMAT_RCD = 0,
984
+ IFORMAT_TIFF,
985
+ IFORMAT_FITS
986
+ } FPRO_IMAGE_FORMAT;
987
+
988
+ ///
989
+ /// @typedef FPRO_CONV
990
+ /// @brief Conversion info structure supplied to conversion functions.
991
+ ///
992
+ /// This enum is used by the conversion functions
993
+ /// to specify the resultant image format of the operation. It also supplies
994
+ /// merge reference frames to use in the case a image merge needs to occur. If these
995
+ /// are not supplied, identity frames are used based on the gain settings in the meta
996
+ /// data of the given rcd file to convert. See #FPROAlgo_SetHardwareMergeReferenceFiles and
997
+ /// #FPROFrame_ConvertFile for more information.
998
+ /// @var FPRO_CONV::eFormat
999
+ /// @brief File format for the converted frame.
1000
+ /// @var FPRO_CONV::pDSNUFile
1001
+ /// @brief DSNU Reference file (may be NULL).
1002
+ /// @var FPRO_CONV::pPRNUFile
1003
+ /// @brief PRNU Reference file (may be NULL).
1004
+ typedef struct conv_info_t
1005
+ {
1006
+ FPRO_IMAGE_FORMAT eFormat;
1007
+ wchar_t* pDSNUFile;
1008
+ wchar_t* pPRNUFile;
1009
+ } FPRO_CONV;
1010
+
1011
+ ///
1012
+ /// @typedef FPRO_HWMERGEFRAMES
1013
+ /// @brief Enables for Hardware Image Merging
1014
+ ///
1015
+ /// This enum is used by the hardware merging algorithms and
1016
+ /// specifies which image planes from the camera to merge. See #FPRO_HWMERGEENABLE.
1017
+ /// Normally you would merge both the low and high gain frames to get the
1018
+ /// best resultant merged image. This allows you to obtain either the
1019
+ /// low or high gain images as well.
1020
+ /// @var FPRO_HWMERGEFRAMES::HWMERGE_FRAME_BOTH
1021
+ /// @brief Normal merge, both low and high gain planes are corrected and merged.
1022
+ /// @var FPRO_HWMERGEFRAMES::HWMERGE_FRAME_LOWONLY
1023
+ /// @brief Only the corrected low gain pixels will be sent through to the API. The high gain pixels will be ignored.
1024
+ /// @var FPRO_HWMERGEENABLE::HWMERGE_FRAME_HIGHONLY
1025
+ /// @brief Only the corrected high gain pixels will be sent through to the API. The low gain pixels will be ignored.
1026
+ typedef enum
1027
+ {
1028
+ HWMERGE_FRAME_BOTH = 0,
1029
+ HWMERGE_FRAME_LOWONLY,
1030
+ HWMERGE_FRAME_HIGHONLY,
1031
+
1032
+ } FPRO_HWMERGEFRAMES;
1033
+
1034
+
1035
+ ///
1036
+ /// @typedef hw_merge_enables_t FPRO_HWMERGEENABLE
1037
+ /// @brief Enables for Hardware Image Merging
1038
+ ///
1039
+ /// Version 2 and later of the PCIE Fibre interface card allows for the image
1040
+ /// merging process to be done in hardware directly on the card.
1041
+ /// This structure is used to enable the different merging options.
1042
+ /// See #FPROAlgo_SetHardwareMergeEnables() and #FPRO_REFFRAMES for more information.
1043
+ /// <br>
1044
+ /// <br>
1045
+ /// In addition, the same merge algorithm used on the PCIE card is available in the API for use
1046
+ /// on USB connections, Fibre connections with older hardware, and even with version 2 PCIE hardware.
1047
+ /// For use in the API, all of the same hardware merge API's are used to set up the reference frames,
1048
+ /// thresholds, and enables (as with this structure). In the API's emulation, the bMergeEnable and eMergeFrames
1049
+ /// fields in this structure are ignored. You tell the API to merge or return the desired frames through the #FPROUNPACKEDIMAGES
1050
+ /// structure using the #FPROFrame_GetVideoFrameUnpacked() call. See the structure definition #FPROUNPACKEDIMAGES
1051
+ /// for more information on unpacking and merging.
1052
+ /// <br>
1053
+ /// <br>
1054
+ /// If unpacked and unmerged data is desired the #FPROFrame_GetVideoFrame() call is used.
1055
+ /// <br>
1056
+ ///
1057
+ /// @var FPRO_HWMERGEENABLE::bMergeEnable
1058
+ /// @brief True if merging enabled. This must be true for the other enables to have any effect. False turns merging off
1059
+ /// and the unprocessed frame data is passed through to the host directly from the camera.
1060
+ /// @var FPRO_HWMERGEENABLE::eMergeFormat
1061
+ /// @brief The image file format for the merged image. The Actual PCIE card only supports RCD and TIFF. When the
1062
+ /// API is used for merging through this mechanism, FITS is also supported.
1063
+ /// @var FPRO_HWMERGEENABLE::eMergeFrames
1064
+ /// @brief Specifies the frames to merge.
1065
+ typedef struct hw_merge_enables_t
1066
+ {
1067
+ bool bMergeEnable;
1068
+ FPRO_IMAGE_FORMAT eMergeFormat;
1069
+ FPRO_HWMERGEFRAMES eMergeFrames;
1070
+ } FPRO_HWMERGEENABLE;
1071
+
1072
+ /// @enum FPRO_MERGEALGO
1073
+ /// @brief Merging algorithms available in the API
1074
+ ///
1075
+ /// This enum is for use with the #FPROFrame_GetVideoFrameUnpacked() API to retrieve unpacked and
1076
+ /// merged image data. This enum tells the API which algorithm to use when merging data.
1077
+ /// See #FPROUNPACKEDIMAGES for more information on unpacking and merging in general.
1078
+ /// See #FPROAlgo_SetHardwareMergeEnables(), #FPROAlgo_SetHardwareMergeReferenceFrames() and #FPRO_REFFRAMES
1079
+ /// for more information on the hardware merge (and API emulation) setup.
1080
+ ///
1081
+ /// @var FPRO_MERGEALGO::FPROMERGE_ALGO
1082
+ /// @brief Original merge algorithm based on camera settings.
1083
+ /// @var FPRO_MERGEALGO::FPROMERGE_ALGO_REF_FRAME
1084
+ /// @brief Emulates the hardware merge algorithm found on the FLI PCIE Fibre cards. Reference
1085
+ /// frames are required to be sent to the API for this to function correctly. Identity reference
1086
+ /// frames are used if none are sent.
1087
+ typedef enum
1088
+ {
1089
+ FPROMERGE_ALGO = 0,
1090
+ FPROMERGE_ALGO_REF_FRAME,
1091
+ } FPRO_MERGEALGO;
1092
+
1093
+ ///
1094
+ /// @typedef unpacked_images_t FPROUNPACKEDIMAGES
1095
+ /// @brief Unpacked Image Buffers
1096
+ ///
1097
+ /// The raw data returned by the cameras is of varying formats, bit depths, and interleaving based on the
1098
+ /// internal sensor used in the camera. In order to make use of the data for analysis or display, the images
1099
+ /// must be unpacked to a form more suitable for such purposes. This structure is used by the API to allow the application to
1100
+ /// request the frames to be automatically unpacked. The specific usage of these pointers is described in the
1101
+ /// function documentation in which they are used. For example, see #FPROFrame_GetVideoFrameUnpacked() for a description
1102
+ /// of how this structure is used for that particular call.
1103
+ ///
1104
+ /// @var FPROUNPACKEDIMAGES::pMetaData
1105
+ /// @brief The raw Meta Data Buffer.
1106
+ /// @var FPROUNPACKEDIMAGES::uiMetaDataSize
1107
+ /// @brief The Size of the pMetaData buffer in bytes.
1108
+ /// @var FPROUNPACKEDIMAGES::bMetaDataRequest
1109
+ /// @brief The Meta Data request Flag. Set to 'true' to unpack meta data.
1110
+ ///
1111
+ /// @var FPROUNPACKEDIMAGES::pLowImage
1112
+ /// @brief The Low Image Buffer.
1113
+ /// @var FPROUNPACKEDIMAGES::uiLowImageSize
1114
+ /// @brief The Size of the pLowImage image in pixels.
1115
+ /// @var FPROUNPACKEDIMAGES::uiLowBufferSize
1116
+ /// @brief The Size of the pLowImage buffer in bytes. This may be different than
1117
+ /// uiLowImageSize * sizeof(uint16_t) when a merge format other than RCD is chosen.
1118
+ /// @var FPROUNPACKEDIMAGES::bLowImageRequest
1119
+ /// @brief The Low Image request Flag. Set to 'true' to unpack the low gain image plane.
1120
+ ///
1121
+ /// @var FPROUNPACKEDIMAGES::pHighImage
1122
+ /// @brief The High Image Buffer.
1123
+ /// @var FPROUNPACKEDIMAGES::uiHighImageSize
1124
+ /// @brief The Size of the pHighImage image in pixels.
1125
+ /// @var FPROUNPACKEDIMAGES::uiHighBufferSize
1126
+ /// @brief The Size of the pHighImage buffer in bytes. This may be different than
1127
+ /// uiHighImageSize * sizeof(uint16_t) when a merge format other than RCD is chosen.
1128
+ /// @var FPROUNPACKEDIMAGES::bHighImageRequest
1129
+ /// @brief The High Image request Flag. Set to 'true' to unpack the high gain image plane.
1130
+ ///
1131
+ /// @var FPROUNPACKEDIMAGES::pMergedImage
1132
+ /// @brief The Merged Image Buffer.
1133
+ /// @var FPROUNPACKEDIMAGES::uiMergedImageSize
1134
+ /// @brief The Size of the pMergedImage image in pixels.
1135
+ /// @var FPROUNPACKEDIMAGES::uiMergedBufferSize
1136
+ /// @brief The Size of the pMergedImage buffer in bytes. This will be different than
1137
+ /// uiMergedImageSize * sizeof(uint16_t) when a merge format other than RCD is chosen.
1138
+ /// @var FPROUNPACKEDIMAGES::bMergedImageRequest
1139
+ /// @brief The Merged Image request Flag. Set to 'true' to merge the low and high gain image planes.
1140
+ /// @var FPROUNPACKEDIMAGES::eMergAlgo
1141
+ /// @brief Specifies which merging algorithm to use when merging the image data. See #FPRO_MERGEALGO.
1142
+ typedef struct unpacked_images_t
1143
+ {
1144
+ uint8_t *pMetaData;
1145
+ uint32_t uiMetaDataSize;
1146
+ bool bMetaDataRequest;
1147
+
1148
+ uint16_t *pLowImage;
1149
+ uint64_t uiLowImageSize;
1150
+ uint64_t uiLowBufferSize;
1151
+ bool bLowImageRequest;
1152
+
1153
+ uint16_t *pHighImage;
1154
+ uint64_t uiHighImageSize;
1155
+ uint64_t uiHighBufferSize;
1156
+ bool bHighImageRequest;
1157
+
1158
+ uint16_t *pMergedImage;
1159
+ uint64_t uiMergedImageSize;
1160
+ uint64_t uiMergedBufferSize;
1161
+ bool bMergedImageRequest;
1162
+
1163
+ FPRO_MERGEALGO eMergAlgo;
1164
+
1165
+ /// @cond DO_NOT_DOCUMENT
1166
+ /// Not implemented yet
1167
+ FPRO_CROP cropRect;
1168
+ bool bRequestCrop;
1169
+ /// @endcond
1170
+
1171
+ } FPROUNPACKEDIMAGES;
1172
+
1173
+ ///
1174
+ /// @typedef int_point_t FPROPOINT
1175
+ /// @brief Point Coordinates
1176
+ ///
1177
+ /// A simple structure to define a point in space. Used by other structures in the API
1178
+ /// such as #FPROPLANESTATS to specify the location of the dimmest and brightest
1179
+ /// pixels in an image plane.
1180
+ ///
1181
+ /// @var FPROPOINT::X
1182
+ /// @brief The x coordinate.
1183
+ /// @var FPROPOINT::Y
1184
+ /// @brief The y coordinate.
1185
+ typedef struct int_point_t
1186
+ {
1187
+ int32_t X;
1188
+ int32_t Y;
1189
+ } FPROPOINT;
1190
+
1191
+ ///
1192
+ /// @typedef pixel_info_t FPROPIXELINFO
1193
+ /// @brief Defines a location and value of a pixel within an image plane.
1194
+ ///
1195
+ /// A composite structure to define a location and value of a pixel within an image plane.
1196
+ /// Used by other structures in the API such as #FPROPLANESTATS to specify the location of the
1197
+ /// dimmest and brightest pixels in an image plane.
1198
+ ///
1199
+ /// @var FPROPIXELINFO::ptPosition
1200
+ /// @brief The x and y coordinate of the pixel within the plane.
1201
+ /// @var FPROPIXELINFO::uiValue
1202
+ /// @brief The pixel value.
1203
+ typedef struct pixel_info_t
1204
+ {
1205
+ FPROPOINT ptPosition;
1206
+ uint32_t uiValue;
1207
+ } FPROPIXELINFO;
1208
+
1209
+ /// @typedef image_plane_stats_t FPROPLANESTATS
1210
+ /// @brief Defines the set of statistics available for unpacked frames.
1211
+ ///
1212
+ /// This structure provides the given statistics for an image plane when unpacked by
1213
+ /// the API. See #FPROUNPACKEDSTATS for more information.
1214
+ ///
1215
+ /// @var FPROPLANESTATS::uiLCutoff
1216
+ /// @brief The lower pixel value cutoff.
1217
+ /// @var FPROPLANESTATS::uiUCutoff
1218
+ /// @brief The Upper pixel value cutoff.
1219
+ /// @var FPROPLANESTATS::uiHistogramSize
1220
+ /// @brief The number of elements in the array pointed to by pdblHistogram.
1221
+ /// @var FPROPLANESTATS::pdblHistogram
1222
+ /// @brief The pixel value histogram. The index is the pixel value, the value at that index is the number of pixels with that pixel value.
1223
+ /// @var FPROPLANESTATS::dblMean
1224
+ /// @brief The mean of the pixel values in the plane.
1225
+ /// @var FPROPLANESTATS::dblMedian
1226
+ /// @brief The median of the pixel values in the plane.
1227
+ /// @var FPROPLANESTATS::dblMode
1228
+ /// @brief The mode of the pixel values in the plane.
1229
+ /// @var FPROPLANESTATS::dblStandardDeviation
1230
+ /// @brief The standard deviation of the pixels in the plane.
1231
+ /// @var FPROPLANESTATS::pixBrightest
1232
+ /// @brief The location and value of the brightest pixel in the plane.
1233
+ /// @var FPROPLANESTATS::pixDimmest
1234
+ /// @brief The location and value of the dimmest pixel in the plane.
1235
+ typedef struct image_plane_stats_t
1236
+ {
1237
+ uint32_t uiLCutoff;
1238
+ uint32_t uiUCutoff;
1239
+ uint32_t uiHistogramSize;
1240
+ double *pdblHistogram;
1241
+ double dblMean;
1242
+ double dblMedian;
1243
+ double dblMode;
1244
+ double dblStandardDeviation;
1245
+
1246
+ FPROPIXELINFO pixBrightest;
1247
+ FPROPIXELINFO pixDimmest;
1248
+
1249
+ } FPROPLANESTATS;
1250
+
1251
+ /// @typedef FPROUNPACKEDSTATS
1252
+ /// @brief Statistics for unpacked image planes.
1253
+ ///
1254
+ /// A structure to retrieve the statistics for unpacked frames. The pointers within the
1255
+ /// encapsulated structures are allocated and deallocated by the API.
1256
+ /// See #FPROFrame_GetVideoFrameUnpacked() for a description
1257
+ /// of how this structure is used for that particular call.
1258
+ ///
1259
+ /// @var FPROUNPACKEDSTATS::statsLowImage
1260
+ /// @brief The statistics for the low image.
1261
+ /// @var FPROUNPACKEDSTATS::bLowRequest
1262
+ /// @brief Set to true to request the statistics for this image plane when unpacking.
1263
+ /// @var FPROUNPACKEDSTATS::statsHighImage
1264
+ /// @brief The statistics for the high image.
1265
+ /// @var FPROUNPACKEDSTATS::bHighRequest
1266
+ /// @brief Set to true to request the statistics for this image plane when unpacking.
1267
+ /// @var FPROUNPACKEDSTATS::statsMergedImage
1268
+ /// @brief The statistics for the merged image.
1269
+ /// @var FPROUNPACKEDSTATS::bMergedRequest
1270
+ /// @brief Set to true to request the statistics for this image plane when unpacking.
1271
+ typedef struct unpacked_stats_t
1272
+ {
1273
+ FPROPLANESTATS statsLowImage;
1274
+ bool bLowRequest;
1275
+
1276
+ FPROPLANESTATS statsHighImage;
1277
+ bool bHighRequest;
1278
+
1279
+ FPROPLANESTATS statsMergedImage;
1280
+ bool bMergedRequest;
1281
+
1282
+ } FPROUNPACKEDSTATS;
1283
+
1284
+ //////////////////////////////////////////
1285
+ // Camera Open, Close
1286
+ //////////////////////////////////////////
1287
+ //////////////////////////////////////////
1288
+ //////////////////////////////////////////
1289
+ ///
1290
+ /// @brief FPROCam_GetCameraList
1291
+ ///
1292
+ /// Returns a list of cameras detected on the host. Most often it is the
1293
+ /// first function called in the API in order to provide a list of
1294
+ /// available devices to the user. The information provided in the
1295
+ /// FPRODEVICEINFO structure allows unique names to be constructed for
1296
+ /// each camera. A pointer an FPRODEVICEINFO structure corresponding to a
1297
+ /// user selected device is passed to a subsequent call to FPROCam_Open()
1298
+ /// in order to connect to the camera.
1299
+ ///
1300
+ /// @param pDeviceInfo - Pointer to user allocated memory to hold the list of devices.
1301
+ /// @param pNumDevices - On entry, the max number of devices that may be assigned to the list.
1302
+ /// Note that the pDeviceInfo pointer must point to enough memory to hold
1303
+ /// the given pNumDevices. On exit, it contains the number of devices
1304
+ /// detected and inserted in the list. This can be less than the requested
1305
+ /// number. If it returns the requested number, there may be additional
1306
+ /// devices connected.
1307
+ ///
1308
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1309
+ ///
1310
+ LIBFLIPRO_API FPROCam_GetCameraList(FPRODEVICEINFO *pDeviceInfo, uint32_t *pNumDevices);
1311
+
1312
+ //////////////////////////////////////////
1313
+ ///
1314
+ /// @brief FPROCam_GetDeviceInfo
1315
+ ///
1316
+ /// Returns the device information structure FPRODEVICEINFO for the
1317
+ /// connected camera.
1318
+ ///
1319
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open().
1320
+ /// @param pDeviceInfo - Pointer to user allocated memory to hold the device connection information.
1321
+ ///
1322
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1323
+ LIBFLIPRO_API FPROCam_GetDeviceInfo(int32_t iHandle, FPRODEVICEINFO* pDeviceInfo);
1324
+
1325
+ //////////////////////////////////////////
1326
+ ///
1327
+ /// @brief Connects to the camera specified by the pDevInfo parameter.
1328
+ ///
1329
+ /// This call must complete successfully in order to use any calls in the API
1330
+ /// that communicate with the camera.
1331
+ /// The returned handle is passed to all such subsequent API calls.
1332
+ ///
1333
+ /// @param pDevInfo - Pointer to device description as returned by FPROCam_GetCameraList().
1334
+ /// @param pHandle - On successful completion, it contains the device handle to use in
1335
+ /// subsequent API calls.
1336
+ ///
1337
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1338
+ LIBFLIPRO_API FPROCam_Open(FPRODEVICEINFO *pDevInfo, int32_t *pHandle);
1339
+
1340
+
1341
+ //////////////////////////////////////////
1342
+ ///
1343
+ /// @brief Disconnects from the camera an releases the handle.
1344
+ ///
1345
+ /// @param iHandle - Connected camera handle to close.
1346
+ ///
1347
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1348
+ LIBFLIPRO_API FPROCam_Close(int32_t iHandle);
1349
+
1350
+ //////////////////////////////////////////
1351
+ ///
1352
+ /// @brief Returns the version of this API Library.
1353
+ ///
1354
+ /// This function may be called
1355
+ /// at any time, it does not need a device handle to report the API version.
1356
+ ///
1357
+ ///
1358
+ /// @param pVersion - Buffer for returned NULL terminated version string.
1359
+ /// @param uiLength - Length of supplied buffer.
1360
+ ///
1361
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1362
+ LIBFLIPRO_API FPROCam_GetAPIVersion(wchar_t *pVersion, uint32_t uiLength);
1363
+
1364
+ //////////////////////////////////////////
1365
+ ///
1366
+ /// @brief Returns the version information from the connected device.
1367
+ ///
1368
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open().
1369
+ /// @param pVersion - Structure buffer to return version information.
1370
+ ///
1371
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1372
+ LIBFLIPRO_API FPROCam_GetDeviceVersion(int32_t iHandle, FPRODEVICEVERS *pVersion);
1373
+
1374
+ //////////////////////////////////////////
1375
+ ///
1376
+ /// @brief Returns the version information from the connected device.
1377
+ ///
1378
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open().
1379
+ /// @param pFibre - Buffer for the Fibre FPGA serial number on the Host PCIE card.
1380
+ /// @param pPcie - Buffer for the PCIE FPGA serial number on the Host PCIE card.
1381
+ /// @param uiLength - Length of each of the buffers (they must be the same length).
1382
+ /// Serial numbers are limited to 32 characters by the API.
1383
+ ///
1384
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1385
+ LIBFLIPRO_API FPROCam_GetHostSerialNumbers(int32_t iHandle, wchar_t *pFibre, wchar_t *pPcie, uint32_t uiLength);
1386
+
1387
+
1388
+ ///////////////////////////////////////////////////////////////////////////////
1389
+ ///////////////////////////////////////////////////////////////////////////////
1390
+ // Frame Data Functions
1391
+ ///////////////////////////////////////////////////////////////////////////////
1392
+ ///////////////////////////////////////////////////////////////////////////////
1393
+ //////////////////////////////////////////
1394
+ ///
1395
+ /// @brief Aborts the active image capture.
1396
+ ///
1397
+ /// The abort function is meant to be called to abort the current image capture.
1398
+ /// It can be called from a different thread that is performing the image capture
1399
+ /// as long as the recommended calling pattern for image capture is followed.
1400
+ /// See FPROFrame_CaptureStart() for a description of
1401
+ /// the recommended image capture calling pattern.
1402
+ ///
1403
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1404
+ ///
1405
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1406
+ LIBFLIPRO_API FPROFrame_CaptureAbort(int32_t iHandle);
1407
+
1408
+ /// @cond DO_NOT_DOCUMENT
1409
+ //////////////////////////////////////////
1410
+ ///
1411
+ /// @brief Ends the active image capture.
1412
+ ///
1413
+ /// The end function is meant to be called to be called to end the current image capture
1414
+ /// and allow the capturing thread to retrieve the image data. It is intended to be
1415
+ /// be used to end a long exposure prior to the full exposure completing. Given that,
1416
+ /// it will normally be called from a different thread that is performing the image capture
1417
+ /// as long as the recommended calling pattern for image capture is followed.
1418
+ /// See FPROFrame_CaptureStart(), for a description of
1419
+ /// the recommended image capture calling pattern.
1420
+ ///
1421
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1422
+ ///
1423
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1424
+ /// DEPRECATED
1425
+ //LIBFLIPRO_API FPROFrame_CaptureEnd(int32_t iHandle);
1426
+ /// @endcond
1427
+
1428
+ //////////////////////////////////////////
1429
+ ///
1430
+ /// @brief Initiates the capture of the configured image.
1431
+ ///
1432
+ /// The image is retrieved using the FPROFrame_GetVideoFrame() API.
1433
+ ///
1434
+ /// NOTE: In order to ensure data pipe integrity, FPROFrame_CaptureStart(),
1435
+ /// FPROFrame_GetVideoFrame(), and FPROFrame_CaptureStop() must be called
1436
+ /// from the same thread in a pattern similar to below:
1437
+ ///
1438
+ /// @code
1439
+ ///
1440
+ /// FPROFrame_CaptureStart();
1441
+ /// while (frames_to_get)
1442
+ /// FPROFrame_GetVideoFrame();
1443
+ /// FPROFrame_CaptureStop();
1444
+ ///
1445
+ /// @endcode
1446
+ ///
1447
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1448
+ /// @param uiFrameCount - Number of frames to capture. 0 == infinite stream.
1449
+ ///
1450
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1451
+ LIBFLIPRO_API FPROFrame_CaptureStart(int32_t iHandle, uint32_t uiFrameCount);
1452
+
1453
+ //////////////////////////////////////////
1454
+ ///
1455
+ /// @brief Stops the active image capture.
1456
+ ///
1457
+ /// NOTE: In order to ensure data pipe integrity, FPROFrame_CaptureStart(),
1458
+ /// FPROFrame_GetVideoFrame(), and FPROFrame_CaptureStop() must be called
1459
+ /// from the same thread in a pattern similar to below:
1460
+ ///
1461
+ /// @code
1462
+ ///
1463
+ /// FPROFrame_CaptureStart();
1464
+ /// while (frames_to_get)
1465
+ /// FPROFrame_GetVideoFrame();
1466
+ /// FPROFrame_CaptureStop();
1467
+ ///
1468
+ /// @endcode
1469
+ ///
1470
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1471
+ ///
1472
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1473
+ LIBFLIPRO_API FPROFrame_CaptureStop(int32_t iHandle);
1474
+
1475
+
1476
+ //////////////////////////////////////////
1477
+ ///
1478
+ /// @brief Initiates the capture of a thumbnail image.
1479
+ ///
1480
+ /// The image is transferred over the
1481
+ /// image endpoint and is retrieved using the FPROFrame_GetThumbnail() API.
1482
+ /// Thumbnail images are 512x512 pixels. No Metadata or dummy pixels are included
1483
+ /// in the image.
1484
+ ///
1485
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1486
+ ///
1487
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1488
+ LIBFLIPRO_API FPROFrame_CaptureThumbnail(int32_t iHandle);
1489
+
1490
+ //////////////////////////////////////////
1491
+ ///
1492
+ /// @brief Computes the size in bytes of the image frame.
1493
+ ///
1494
+ /// This function uses the actual camera settings to determine the size of the image data that
1495
+ /// will be received in bytes. As such, all camera settings must be set up for your image prior to calling
1496
+ /// this function. Since communications with the camera is required to complete this function
1497
+ /// successfully, it can fail on the communication. In addition, this function can take tens of
1498
+ /// milli-seconds to complete because of this communication so it should not be called in time
1499
+ /// critical situations.
1500
+ /// <br>
1501
+ /// <br>
1502
+ /// IMPORTANT: On Fibre connections, when using the Hardware Merging capabilities of the PCIE card, this
1503
+ /// function MUST be called after you have set up the camera and enabled the Hardware Merging function.
1504
+ /// See #FPROAlgo_SetHardwareMergeEnables(). If you do not call this function, the hardware merging
1505
+ /// function may be incorrectly initialized for the current setup and image corruption may result.
1506
+ /// <br>
1507
+ ///
1508
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1509
+ ///
1510
+ /// @return The size of the expected image frame in bytes on success, less than 0 on failure.
1511
+ LIBFLIPRO_API FPROFrame_ComputeFrameSize(int32_t iHandle);
1512
+
1513
+ //////////////////////////////////////////
1514
+ ///
1515
+ /// @brief Computes the size in pixels of the image frame.
1516
+ ///
1517
+ /// This function uses the actual camera settings to determine the size of the image data that
1518
+ /// will be received in pixels. As such, all camera settings must be set up for your image prior to calling
1519
+ /// this function. Since communications with the camera is required to complete this function
1520
+ /// successfully, it can fail on the communication. In addition, this function can take tens of
1521
+ /// milli-seconds to complete because of this communication so it should not be called in time
1522
+ /// critical situations.
1523
+ ///
1524
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1525
+ /// @param pTotalWidth - If provided, the total width of the image (including reference pixels) is returned.
1526
+ /// @param pTotalHeight - If provided, the total height of the image (including reference rows) is returned.
1527
+ ///
1528
+ /// @return The size of the expected image frame in bytes on success, less than 0 on failure.
1529
+ LIBFLIPRO_API FPROFrame_ComputeFrameSizePixels(int32_t iHandle, uint32_t *pTotalWidth, uint32_t *pTotalHeight);
1530
+
1531
+ //////////////////////////////////////////
1532
+ ///
1533
+ /// @brief Frees the Unpacked Buffers within the given structure.
1534
+ ///
1535
+ /// See #FPROFrame_GetVideoFrameUnpacked() for additional information.
1536
+ ///
1537
+ /// @param pUPBuffers - The buffers to free.
1538
+ ///
1539
+ /// @return None.
1540
+ LIBFLIPRO_VOID FPROFrame_FreeUnpackedBuffers(FPROUNPACKEDIMAGES *pUPBuffers);
1541
+
1542
+ //////////////////////////////////////////
1543
+ ///
1544
+ /// @brief Frees the Unpacked Statistics Buffers within the given structure.
1545
+ ///
1546
+ /// See #FPROFrame_GetVideoFrameUnpacked() for additional information.
1547
+ ///
1548
+ /// @param pStats - The statistics buffers to free.
1549
+ ///
1550
+ /// @return None.
1551
+ LIBFLIPRO_VOID FPROFrame_FreeUnpackedStatistics(FPROUNPACKEDSTATS *pStats);
1552
+
1553
+ //////////////////////////////////////////
1554
+ ///
1555
+ /// @brief Retrieves the dummy pixel configuration to be appended row data.
1556
+ ///
1557
+ /// If enabled, dummy pixels are appended to every other row of image data
1558
+ /// starting with the second row of data.
1559
+ ///
1560
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1561
+ /// @param pEnable - true: Dummy pixels will be appended to every other image row
1562
+ /// false: Dummy pixels will NOT be appended to every other image row
1563
+ ///
1564
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1565
+ LIBFLIPRO_API FPROFrame_GetDummyPixelEnable(int32_t iHandle, bool *pEnable);
1566
+
1567
+ //////////////////////////////////////////
1568
+ ///
1569
+ /// @brief Retrieves the Frame Type setting.
1570
+ ///
1571
+ /// Returns the frame type set by the #FPROFrame_SetFrameType() API.
1572
+ /// The default frame type is FPRO_FRAMETYPE_NORMAL. Typically this is only used for testing
1573
+ /// purposes. Consult your documentation for a description and availability of the different
1574
+ /// frame types found on a given camera model. See also #FPRO_FRAME_TYPE.
1575
+ ///
1576
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1577
+ /// @param pType - The current frame type setting.
1578
+ ///
1579
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1580
+ LIBFLIPRO_API FPROFrame_GetFrameType(int32_t iHandle, FPRO_FRAME_TYPE *pType);
1581
+
1582
+ //////////////////////////////////////////
1583
+ ///
1584
+ /// @brief Retrieves the reference row count to be appended to frame data.
1585
+ ///
1586
+ /// If the count is > 0, this number of reference rows are appended to the
1587
+ /// frame data. See #FPROCAP capabilities structure for details about reference rows.
1588
+ ///
1589
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1590
+ /// @param pNumRows - Pointer to the number of reference rows to append to the image frame data.
1591
+ ///
1592
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1593
+ LIBFLIPRO_API FPROFrame_GetReferenceRowPostFrameCount(int32_t iHandle, uint32_t *pNumRows);
1594
+
1595
+ //////////////////////////////////////////
1596
+ ///
1597
+ /// @brief Retrieves the reference row count to be prepended to frame data.
1598
+ ///
1599
+ /// If the count is > 0, this number of reference rows are prepended to the
1600
+ /// frame data. See #FPROCAP capabilities structure for details about reference rows.
1601
+ ///
1602
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1603
+ /// @param pNumRows - Pointer to the number of reference rows to prepend to the image frame data.
1604
+ ///
1605
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1606
+ LIBFLIPRO_API FPROFrame_GetReferenceRowPreFrameCount(int32_t iHandle, uint32_t *pNumRows);
1607
+
1608
+ //////////////////////////////////////////
1609
+ ///
1610
+ /// @brief Enables image data imaging.
1611
+ ///
1612
+ /// Image data may be disabled allowing only reference rows to be
1613
+ /// produced for image frames. Reference rows are configured with the
1614
+ /// #FPROFrame_SetReferenceRowPostFrameCount() and #FPROFrame_SetReferenceRowPreFrameCount()
1615
+ /// API calls.
1616
+ ///
1617
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1618
+ /// @param pEnable - true: Image data pixels enabled, false: Image data pixels disabled.
1619
+ ///
1620
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1621
+ LIBFLIPRO_API FPROFrame_GetImageDataEnable(int32_t iHandle, bool *pEnable);
1622
+
1623
+ //////////////////////////////////////////
1624
+ ///
1625
+ /// @brief Retrieves the test image data settings.
1626
+ ///
1627
+ /// When enabled, the camera generates a test pattern rather than capturing image data from the
1628
+ /// image sensor. See #FPROFrame_SetTestImageEnable().
1629
+ ///
1630
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1631
+ /// @param pEnable - true: Enable test image data
1632
+ /// false: Disables test image data- normal image data produced
1633
+ /// @param pFormat - Format of the test image data to produce.
1634
+ ///
1635
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1636
+ LIBFLIPRO_API FPROFrame_GetTestImageEnable(int32_t iHandle, bool *pEnable, FPROTESTIMAGETYPE *pFormat);
1637
+
1638
+ //////////////////////////////////////////
1639
+ ///
1640
+ /// @brief Gets the area of the image sensor being used to produce image frame data.
1641
+ ///
1642
+ /// Image frames are retrieved using the FPROFrame_GetVideoFrame() API.
1643
+ ///
1644
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1645
+ /// @param pColOffset - Start column (pixel) of the image frame
1646
+ /// @param pRowOffset - Start row (pixel) of the image frame
1647
+ /// @param pWidth - Width of the image frame in pixels.
1648
+ /// @param pHeight - Height of the image frame in pixels.
1649
+ ///
1650
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1651
+ LIBFLIPRO_API FPROFrame_GetImageArea(int32_t iHandle, uint32_t *pColOffset, uint32_t *pRowOffset, uint32_t *pWidth, uint32_t *pHeight);
1652
+
1653
+ //////////////////////////////////////////
1654
+ ///
1655
+ /// @brief Retrieves the current pixel configuration.
1656
+ ///
1657
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1658
+ /// @param pPixelDepth - The current pixel depth.
1659
+ /// @param pPixelLSB - The Pixel LSB offset.
1660
+ ///
1661
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1662
+ LIBFLIPRO_API FPROFrame_GetPixelConfig(int32_t iHandle, uint32_t *pPixelDepth, uint32_t *pPixelLSB);
1663
+
1664
+
1665
+ //////////////////////////////////////////
1666
+ ///
1667
+ /// @brief Retrieves the thumbnail image from the camera.
1668
+ ///
1669
+ /// The image is transferred over the
1670
+ /// image endpoint and is retrieved using the FPROFrame_GetThumbnail() API.
1671
+ /// Thumbnail images are 512x512 12 bit pixels in size. That is, no Metadata,
1672
+ /// reference rows, or dummy pixels are included in the image.
1673
+ ///
1674
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1675
+ /// @param pFrameData - The buffer to store the frame data
1676
+ /// @param pSize - Size the of the pFrameData buffer.
1677
+ /// On return, the number of bytes actually received.
1678
+ ///
1679
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1680
+ LIBFLIPRO_API FPROFrame_GetThumbnailFrame(int32_t iHandle, uint8_t *pFrameData, uint32_t *pSize);
1681
+
1682
+ //////////////////////////////////////////
1683
+ ///
1684
+ /// @brief Retrieves an image frame from the camera.
1685
+ ///
1686
+ /// It is important to call this function with the
1687
+ /// appropriate size buffer for the frame. That is, the buffer size should be match the
1688
+ /// expected frame size. If it is too large, the function will try and read the given size and
1689
+ /// may stall the USB connection if no more frame data is available.
1690
+ ///
1691
+ /// NOTE: In order to ensure data pipe integrity, FPROFrame_CaptureStart(),
1692
+ /// FPROFrame_GetVideoFrame(), and FPROFrame_CaptureStop() must be called
1693
+ /// from the same thread in a pattern similar to below:
1694
+ ///
1695
+ /// @code
1696
+ ///
1697
+ /// FPROFrame_CaptureStart();
1698
+ /// while (frames_to_get)
1699
+ /// FPROFrame_GetVideoFrame();
1700
+ /// FPROFrame_CaptureStop();
1701
+ ///
1702
+ /// @endcode
1703
+ ///
1704
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1705
+ /// @param pFrameData - The buffer to store the frame data.
1706
+ /// @param pSize - Size the of the pFrameData buffer.
1707
+ /// On return, the number of bytes actually received.
1708
+ /// @param uiTimeoutMS - How long to wait for a frame to be available.
1709
+ /// Assuming you make this call very soon after the FPROFrame_CaptureStart()
1710
+ /// call, you should set this to the exposure time. Internally, the API
1711
+ /// blocks (i.e. no communication with the camera) for some time less than
1712
+ /// uiTimeoutMS and then attempts to retrieve the frame.
1713
+ ///
1714
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1715
+ LIBFLIPRO_API FPROFrame_GetVideoFrame(int32_t iHandle, uint8_t *pFrameData, uint32_t *pSize, uint32_t uiTimeoutMS);
1716
+
1717
+
1718
+ //////////////////////////////////////////
1719
+ ///
1720
+ /// @brief Retrieves an image frame from the camera and optionally unpacks and merges the image planes.
1721
+ ///
1722
+ /// This function behaves identically as the #FPROFrame_GetVideoFrame() call with respect to starting, stopping,
1723
+ /// and timeouts. See #FPROFrame_GetVideoFrame() for details.
1724
+ /// <br>
1725
+ /// In addition, if you specify unpacking buffers, the function will also unpack the raw image data received
1726
+ /// and return the planes requested (Low Gain, High Gain, Merged). The planes to unpack are specified in the
1727
+ /// pUPBuffers parameter. If this parameter is NULL, the function behaves identically to that of #FPROFrame_GetVideoFrame()
1728
+ /// call.
1729
+ /// <br>
1730
+ /// <br>
1731
+ /// To allocate the buffers, the first time you call this function for a given frame setup, you must set the buffer pointers
1732
+ /// within the structure to NULL and set the corresponding 'request flag' in the structure to 'true'. For example, to receive a merged
1733
+ /// frame, set pUPBUffers->pMergedImage to NULL and set pUPBuffers->bMergedImageRequest to 'true'. The API will allocate the
1734
+ /// requested buffers and return the requested planes. If your frame setup does not change, you may reuse the buffers that have
1735
+ /// been allocated for subsequent exposures. If the buffers provided are of incorrect size, the API does it's best to re-allocate them.
1736
+ /// If it can not, the function will return an error. In this case the raw frame may still have been received correctly. Check the
1737
+ /// *pSize value to obtain the number of bytes in the raw frame that were successfully received. When you are done with the buffers, you
1738
+ /// must call #FPROFrame_FreeUnpackedBuffers() to free the memory.
1739
+ /// <br>
1740
+ /// <br>
1741
+ /// Similarly, when you call this function the first time and request statistics for the frames, the API allocates the
1742
+ /// needed memory within the statistics structure. Make sure you initialize the structure with 0's in order for this to
1743
+ /// work properly! The structure can then be reused in subsequent calls.
1744
+ /// When you are done with the statistics, you must call #FPROFrame_FreeUnpackedStatistics() to free the memory.
1745
+ /// <br>
1746
+ /// <br>
1747
+ /// The meta data returned in the pUPBuffers structure is not the raw meta data received from the camera. It has been modified to
1748
+ /// reflect the processing of the raw frame. The raw meta data for the image is at the start of the pFrameData buffer just as it is
1749
+ /// with #FPROFrame_GetVideoFrame(). If you want to process the raw frame, or determine the original image characteristics, you must
1750
+ /// use the meta data in the pFrameData buffer.
1751
+ /// <br>
1752
+ /// <br>
1753
+ /// This function will also perform Bias and Flat Field correction on the Low Gain and High Gain frames if those operations are
1754
+ /// set up prior to this call with the #FPROFrame_SetUnpackingBiasFrames() and #FPROFrame_SetUnpackingFlatFieldFrames() API's.
1755
+ /// <br>
1756
+ ///
1757
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1758
+ /// @param pFrameData - The buffer to store the frame data.
1759
+ /// @param pSize - Size the of the pFrameData buffer.
1760
+ /// On return, the number of bytes actually received.
1761
+ /// @param uiTimeoutMS - How long to wait for a frame to be available.
1762
+ /// Assuming you make this call very soon after the FPROFrame_CaptureStart()
1763
+ /// call, you should set this to the exposure time. Internally, the API
1764
+ /// blocks (i.e. no communication with the camera) for some time less than
1765
+ /// uiTimeoutMS and then attempts to retrieve the frame.
1766
+ /// @param pUPBuffers - If specified, the call will return the unpacked buffers requested.
1767
+ /// @param pStats - If specified, the call will return the statistics requested.
1768
+ ///
1769
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1770
+ LIBFLIPRO_API FPROFrame_GetVideoFrameUnpacked(int32_t iHandle, uint8_t *pFrameData, uint32_t *pSize, uint32_t uiTimeoutMS, FPROUNPACKEDIMAGES *pUPBuffers, FPROUNPACKEDSTATS *pStats);
1771
+
1772
+ //////////////////////////////////////////
1773
+ ///
1774
+ /// @brief Retrieves an externally triggered image frame from the camera.
1775
+ ///
1776
+ /// This function is intended for use when using external trigger sources for image capture.
1777
+ /// Unlike FPROFrame_GetVideoFrame(), no timeout is specified. It waits forever until notification
1778
+ /// of image frame data availability from the camera. FPROFrame_CaptureAbort()
1779
+ /// can be used to cancel the exposure as described in those API calls.
1780
+ /// <br>
1781
+ /// <br>
1782
+ /// FPROFrame_CaptureStart() is not expected to be called prior to this API because the External Trigger
1783
+ /// will be supplying the trigger source. However, if this call is awaiting image data, another thread may
1784
+ /// call #FPROFrame_CaptureStart() to force a trigger. Once exposed, this function will return the data as
1785
+ /// if an external trigger occurred. If you do call FPROFrame_CaptureStart() to force a trigger, it is important
1786
+ /// to call #FPROFrame_CaptureAbort() after the image is retrieved.
1787
+ /// <br>
1788
+ /// <br>
1789
+ /// It is important to call this function with the
1790
+ /// appropriate size buffer for the frame. That is, the buffer size should be match the
1791
+ /// expected frame size. If it is too large, the function will try and read the given size and
1792
+ /// may stall the USB connection if no more frame data is available.
1793
+ ///
1794
+ ///
1795
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1796
+ /// @param pFrameData - The buffer to store the frame data.
1797
+ /// @param pSize - Size the of the pFrameData buffer.
1798
+ /// On return, the number of bytes actually received.
1799
+ ///
1800
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1801
+ LIBFLIPRO_API FPROFrame_GetVideoFrameExt(int32_t iHandle, uint8_t *pFrameData, uint32_t *pSize);
1802
+
1803
+ //////////////////////////////////////////
1804
+ ///
1805
+ /// @brief Unpack and merge the given file.
1806
+ ///
1807
+ /// This function performs similarly as the #FPROFrame_GetVideoFrameUnpacked() API
1808
+ /// except that it operates on the given file as opposed to the image data directly from the
1809
+ /// camera. As such, no connection to the camera is required for this API.
1810
+ /// If you have retrieved a frame with #FPROFrame_GetVideoFrame() or #FPROFrame_GetVideoFrameExt(),
1811
+ /// and saved it to a file, you may pass that file to this function to unpack and merge the image
1812
+ /// planes. For a description of the pUPBUffers and pStats parameters, see the
1813
+ /// #FPROFrame_GetVideoFrameUnpacked() API function.
1814
+ /// <br>
1815
+ /// <br>
1816
+ /// The FPROFrame_UnpackFileEx() API was introduced to accomodate the Reference Frame merging algorithm.
1817
+ /// The FPROFrame_UnpackFile() API simply calls FPROFrame_UnpackFileEx with NULL pointers for the reference
1818
+ /// file names. If the FPROMERGE_ALGO_REF_FRAME, algorithm is specified in the pUPBuffers parameter, this
1819
+ /// causes Identity Frames to be used for the merge. For a description of the pDSNUFile and pPRNUFile
1820
+ /// parameters, see #FPROAlgo_SetHardwareMergeReferenceFiles.
1821
+ /// <br>
1822
+ ///
1823
+ /// @param pFileName - The file to unpack and merge.
1824
+ /// @param pUPBuffers - The unpacked buffers.
1825
+ /// @param pStats - The unpacked statistics.
1826
+ ///
1827
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1828
+ LIBFLIPRO_API FPROFrame_UnpackFile(wchar_t* pFileName, FPROUNPACKEDIMAGES* pUPBuffers, FPROUNPACKEDSTATS* pStats);
1829
+
1830
+ //////////////////////////////////////////
1831
+ ///
1832
+ /// @brief Unpack and merge the given file.
1833
+ ///
1834
+ /// See #FPROFrame_UnpackFile for a complete description.
1835
+ /// <br>
1836
+ /// One or both of the pDSNUFile and pPRNUFile parameters may be NULL. In the case where the
1837
+ /// FPROMERGE_ALGO_REF_FRAME algorithm is specified in the pUPBuffers parameter, an identity reference frame
1838
+ /// will be used for the missing (NULL) frame. For a description of the pDSNUFile and pPRNUFile
1839
+ /// parameters, see #FPROAlgo_SetHardwareMergeReferenceFiles.
1840
+ /// <br>
1841
+ ///
1842
+ /// @param pFileName - The file to unpack and merge.
1843
+ /// @param pUPBuffers - The unpacked buffers.
1844
+ /// @param pStats - The unpacked statistics.
1845
+ /// @param pDSNUFile - DSNU Reference file to use (may be NULL)
1846
+ /// @param pPRNUFile - PRNU Reference File to use (may be NULL)
1847
+ ///
1848
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1849
+ LIBFLIPRO_API FPROFrame_UnpackFileEx(wchar_t* pFileName, FPROUNPACKEDIMAGES* pUPBuffers, FPROUNPACKEDSTATS* pStats, const wchar_t* pDSNUFile, const wchar_t* pPRNUFile);
1850
+
1851
+
1852
+ //////////////////////////////////////////
1853
+ ///
1854
+ /// @brief Convert (and possibly) merge the given RCD file.
1855
+ ///
1856
+ /// Convert the given RCD file to the file type specified.
1857
+ /// See #FPROAlgo_SetHardwareMergeReferenceFiles and #FPRO_CONV for
1858
+ /// more information.
1859
+ /// <br>
1860
+ /// <br>
1861
+ /// Only RCD files may be supplied as the input file to convert. If a single plane
1862
+ /// file is provided, that plane is unpacked and converted to the output format. If a
1863
+ /// two plane RCD is provided (both Low Gain and High Gain frames), the frames are
1864
+ /// unpacked, merged, and all 3 frames are converted to the specified output format.
1865
+ ///
1866
+ /// @param pInRcdFile - The file to convert.
1867
+ /// @param pConvInfo - Conversion specifications.
1868
+ /// @param pOutFile - Ouput (converted) file name.
1869
+ ///
1870
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1871
+ LIBFLIPRO_API FPROFrame_ConvertFile(wchar_t* pInRcdFile, FPRO_CONV* pConvInfo, wchar_t *pOutFile);
1872
+ /// @cond DO_NOT_DOCUMENT
1873
+ /// Not Implemented yet
1874
+ LIBFLIPRO_API FPROFrame_ConvertFileEx(wchar_t* pInRcdFile, FPRO_CONV* pConvInfo, FPROUNPACKEDIMAGES* pUPBuffers, FPROUNPACKEDSTATS* pStats);
1875
+ ///@endcond
1876
+
1877
+ //////////////////////////////////////////
1878
+ ///
1879
+ /// @brief Convert the meta data in the given file to string.
1880
+ ///
1881
+ /// This function simply parses the meta data in the given file and returns a NULL terminated string
1882
+ /// representation. Like #FPROFrame_UnpackFile, this function does not require an active camera connection
1883
+ /// to succeed. This function is intended primarily for trouble shooting purposes. Sufficient
1884
+ /// space must be provided in the pMetaString buffer to contain all of the data. 4K bytes is typically
1885
+ /// enough.
1886
+ ///
1887
+ /// @param pFileName - The file to parse.
1888
+ /// @param pMetaString - The string buffer.
1889
+ /// @param uiMaxSize - The size of the string buffer pMetaString.
1890
+ ///
1891
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1892
+ LIBFLIPRO_API FPROFrame_MetaDataToString(wchar_t* pFileName, wchar_t *pMetaString, uint32_t uiMaxSize);
1893
+
1894
+ //////////////////////////////////////////
1895
+ ///
1896
+ /// @brief Returns whether or not Image Frame data is ready for retrieval.
1897
+ ///
1898
+ /// This API is primarily used in conjunction with an external trigger setup.
1899
+ /// Since the external trigger is not natively synchronized with the software
1900
+ /// in any way, a method to determine when the image data is
1901
+ /// available for retrieval is required. Users can use this routine to query
1902
+ /// the camera and wait for image data to be available. When the function
1903
+ /// succeeds and *pAvailable is 'true', the user can call the normal FPROFrame_GetVideoFrame()
1904
+ /// API to retrieve the data.
1905
+ ///
1906
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1907
+ /// @param pAvailable - Pointer for returned query.
1908
+ /// true: Image Frame data is available for retrieval
1909
+ /// false: Image Frame Data is not available.
1910
+ ///
1911
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1912
+ LIBFLIPRO_API FPROFrame_IsAvailable(int32_t iHandle, bool *pAvailable);
1913
+
1914
+ //////////////////////////////////////////
1915
+ ///
1916
+ /// @brief Sets the dummy pixel configuration to be appended row data.
1917
+ ///
1918
+ /// For the FPRO_CAM_DEVICE_TYPE_GSENSE400 and FPRO_CAM_DEVICE_TYPE_GSENSE4040 model
1919
+ /// cameras, if enabled, dummy pixels are appended to every other row of image data
1920
+ /// starting with the second row of data. Consult your Camera Model user documentation
1921
+ /// as not all models support dummy pixels in the same way.
1922
+ ///
1923
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1924
+ /// @param bEnable - true: Dummy pixels will be appended to every other image row
1925
+ /// false: Dummy pixels will NOT be appended to every other image row
1926
+ ///
1927
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1928
+ LIBFLIPRO_API FPROFrame_SetDummyPixelEnable(int32_t iHandle, bool bEnable);
1929
+
1930
+ //////////////////////////////////////////
1931
+ ///
1932
+ /// @brief Sets Frame Type produced by the camera.
1933
+ ///
1934
+ /// Sets Frame Type produced by the camera. The frame type can be retrieved using the #FPROFrame_GetFrameType()
1935
+ /// API. The default frame type is FPRO_FRAMETYPE_NORMAL. Typically this is only used for testing
1936
+ /// purposes. Consult your documentation for a description and availability of the different
1937
+ /// frame types found on a given camera model. See also #FPRO_FRAME_TYPE.
1938
+ ///
1939
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1940
+ /// @param eType - The frame type to set.
1941
+ ///
1942
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1943
+ LIBFLIPRO_API FPROFrame_SetFrameType(int32_t iHandle, FPRO_FRAME_TYPE eType);
1944
+
1945
+ //////////////////////////////////////////
1946
+ ///
1947
+ /// @brief Sets the reference row count to be appended to frame data.
1948
+ ///
1949
+ /// If the count is > 0, this number of reference rows are appended to the
1950
+ /// frame data. See #FPROCAP capabilities structure for details about reference rows.
1951
+ ///
1952
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1953
+ /// @param uiNumRows - The number of reference rows to append to the image frame data data.
1954
+ ///
1955
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1956
+ LIBFLIPRO_API FPROFrame_SetReferenceRowPostFrameCount(int32_t iHandle, uint32_t uiNumRows);
1957
+
1958
+ //////////////////////////////////////////
1959
+ ///
1960
+ /// @brief Sets the reference row count to be prepended to frame data.
1961
+ ///
1962
+ /// If the count is > 0, this number of reference rows are prepended to the
1963
+ /// frame data. See #FPROCAP capabilities structure for details about reference rows.
1964
+ ///
1965
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1966
+ /// @param uiNumRows - The number of reference rows to prepend to the image frame data.
1967
+ ///
1968
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1969
+ LIBFLIPRO_API FPROFrame_SetReferenceRowPreFrameCount(int32_t iHandle, uint32_t uiNumRows);
1970
+
1971
+ //////////////////////////////////////////
1972
+ ///
1973
+ /// @brief Enables image data imaging.
1974
+ ///
1975
+ /// Image data may be disabled allowing only reference rows to be
1976
+ /// produced for image frames. Reference rows are configured with the
1977
+ /// #FPROFrame_SetReferenceRowPreFrameCount() and #FPROFrame_SetReferenceRowPostFrameCount()
1978
+ /// API calls.
1979
+ ///
1980
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1981
+ /// @param bEnable - true: Enables image data pixels, false: disables image data pixels.
1982
+ ///
1983
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
1984
+ LIBFLIPRO_API FPROFrame_SetImageDataEnable(int32_t iHandle, bool bEnable);
1985
+
1986
+ //////////////////////////////////////////
1987
+ ///
1988
+ /// @brief Enables test image data to be generated rather than normal image data.
1989
+ ///
1990
+ /// Use this to generate a test pattern rather than capturing image data from the
1991
+ /// image sensor.
1992
+ ///
1993
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
1994
+ /// @param bEnable - true: Enable test image data
1995
+ /// false: Disables test image data- normal image data produced
1996
+ /// @param eFormat - Format of the test image data to produce. This parameter is
1997
+ /// ignored if bEnable == false.
1998
+ ///
1999
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2000
+ LIBFLIPRO_API FPROFrame_SetTestImageEnable(int32_t iHandle, bool bEnable, FPROTESTIMAGETYPE eFormat);
2001
+
2002
+ //////////////////////////////////////////
2003
+ ///
2004
+ /// @brief Sets the area of the image sensor to be used for Tracking Frames during image capture.
2005
+ ///
2006
+ /// The tracking frames are retrieved as normal image frames using the
2007
+ /// FPROFrame_GetVideoFrame() API. The image frame follow the tracking
2008
+ /// frames in the USB stream.
2009
+ /// The exposure time setting set with FPROCtrl_SetExposure() applies to the
2010
+ /// tracking frames. As such, the total exposure time for your image frame will
2011
+ /// be exposure_time * uiNumTrackingFrames.
2012
+ ///
2013
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2014
+ /// @param uiStartRow - Start row of the tracking frame (inclusive).
2015
+ /// @param uiEndRow - End row of the tracking frame (inclusive).
2016
+ ///
2017
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2018
+ LIBFLIPRO_API FPROFrame_SetTrackingArea(int32_t iHandle, uint32_t uiStartRow, uint32_t uiEndRow);
2019
+
2020
+ //////////////////////////////////////////
2021
+ ///
2022
+ /// @brief Enables the production of Tracking Frames by the camera.
2023
+ ///
2024
+ /// There will be uiNumTrackingFrames produced for every image frame
2025
+ /// produced. The image frame follow the tracking frames in the USB stream.
2026
+ /// The exposure time setting set with FPROCtrl_SetExposure() applies to the
2027
+ /// tracking frames. As such, the total exposure time for your image frame will
2028
+ /// be exposure_time * uiNumTrackingFrames.
2029
+ ///
2030
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2031
+ /// @param uiNumTrackingFrames - Number of Tracking frames to produce. 0 disables Tracking Frames.
2032
+ ///
2033
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2034
+ LIBFLIPRO_API FPROFrame_SetTrackingAreaEnable (int32_t iHandle, uint32_t uiNumTrackingFrames);
2035
+
2036
+ //////////////////////////////////////////
2037
+ ///
2038
+ /// @brief Sets the current pixel configuration to the specified values.
2039
+ ///
2040
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2041
+ /// @param uiPixelDepth - The current pixel depth.
2042
+ /// @param uiPixelLSB - The Pixel LSB offset.
2043
+ ///
2044
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2045
+ LIBFLIPRO_API FPROFrame_SetPixelConfig(int32_t iHandle, uint32_t uiPixelDepth, uint32_t uiPixelLSB);
2046
+
2047
+ //////////////////////////////////////////
2048
+ ///
2049
+ /// @brief Sets the area of the image sensor to be used to produce image frame data.
2050
+ ///
2051
+ /// Image frames are retrieved using the FPROFrame_GetVideoFrame() API.
2052
+ ///
2053
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2054
+ /// @param uiColOffset - Start column (pixel) of the image frame
2055
+ /// @param uiRowOffset - Start row (pixel) of the image frame
2056
+ /// @param uiWidth - Width of the image frame in pixels.
2057
+ /// @param uiHeight - Height of the image frame in pixels.
2058
+ ///
2059
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2060
+ LIBFLIPRO_API FPROFrame_SetImageArea(int32_t iHandle, uint32_t uiColOffset, uint32_t uiRowOffset, uint32_t uiWidth, uint32_t uiHeight);
2061
+
2062
+ //////////////////////////////////////////
2063
+ ///
2064
+ /// @brief Sets Bias frame correction to be used during unpacking.
2065
+ ///
2066
+ /// This function is meant to be used when you intend to use the #FPROFrame_GetVideoFrameUnpacked() API
2067
+ /// to retrieve image data. During unpacking, the specified Bias frames will be applied to the
2068
+ /// raw image data. The operation is a simple subtraction on the raw image data. See #FPROFrame_GetVideoFrameUnpacked()
2069
+ /// for more information.
2070
+ /// <br>
2071
+ /// <br>
2072
+ /// The dimensions of the frames you pass must match the dimensions of the image frames you are collecting including
2073
+ /// pre and prost row reference pixels and pre and post frame reference rows. If they
2074
+ /// do not match, then the correction is not applied by the #FPROFrame_GetVideoFrameUnpacked() and
2075
+ /// #FPROFrame_GetVideoFrameUnpacked() will return a failure.
2076
+ /// <br>
2077
+ /// <br>
2078
+ /// The frame data you pass must be in row major order. The API copies the passed frames to an internal buffer so you may
2079
+ /// discard the buffers on return. Passing NULL for a frame pointer disables the correction for the given frame (and deletes
2080
+ /// the internal buffer copy).
2081
+ /// <br>
2082
+ ///
2083
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2084
+ /// @param uiWidth - The width of the bias frames in pixels.
2085
+ /// @param uiHeight - The height of the bias frames in pixels.
2086
+ /// @param pLowFrame - The bias correction to be applied to the Low Gain Image.
2087
+ /// @param pHighFrame - The bias correction to be applied to the High Gain Image.
2088
+ ///
2089
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2090
+ LIBFLIPRO_API FPROFrame_SetUnpackingBiasFrames(int32_t iHandle, uint32_t uiWidth, uint32_t uiHeight, uint16_t *pLowFrame, uint16_t *pHighFrame);
2091
+
2092
+ //////////////////////////////////////////
2093
+ ///
2094
+ /// @brief Sets Flat Field correction to be used during unpacking.
2095
+ ///
2096
+ /// This function is meant to be used when you intend to use the #FPROFrame_GetVideoFrameUnpacked() API
2097
+ /// to retrieve image data. During unpacking, the specified Flat Field Correction frames will be applied to the
2098
+ /// raw image data. See #FPROFrame_GetVideoFrameUnpacked() for more information.
2099
+ /// <br>
2100
+ /// <br>
2101
+ /// The dimensions of the frames you pass must match the dimensions of the image frames you are collecting
2102
+ /// including pre and prost row reference pixels and pre and post frame reference rows. If they
2103
+ /// do not match, then the correction is not applied by the #FPROFrame_GetVideoFrameUnpacked() and
2104
+ /// #FPROFrame_GetVideoFrameUnpacked() will return a failure.
2105
+ /// <br>
2106
+ /// <br>
2107
+ /// The frame data you pass must be in row major order. The API copies the passed frames to an internal buffer so you may
2108
+ /// discard the buffers on return. Passing NULL for a frame pointer disables the correction for the given frame (and deletes
2109
+ /// the internal buffer copy).
2110
+ /// <br>
2111
+ ///
2112
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2113
+ /// @param uiWidth - The width of the Flat Field frames in pixels.
2114
+ /// @param uiHeight - The height of the Flat Field frames in pixels.
2115
+ /// @param pLowFrame - The Flat Field correction to be applied to the Low Gain Image.
2116
+ /// @param pHighFrame - The Flat Field correction to be applied to the High Gain Image.
2117
+ ///
2118
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2119
+ LIBFLIPRO_API FPROFrame_SetUnpackingFlatFieldFrames(int32_t iHandle, uint32_t uiWidth, uint32_t uiHeight, uint16_t *pLowFrame, uint16_t *pHighFrame);
2120
+
2121
+
2122
+ //////////////////////////////////////////
2123
+ ///
2124
+ /// @brief Initializes the Streamer interfaces.
2125
+ ///
2126
+ /// The Streamer interfaces enable an efficient stream-to-functionality. Frames
2127
+ /// are streamed directly from the camera to disk. This function initializes the
2128
+ /// various sub modules, allocates resources, and enables the streaming capability.
2129
+ /// This function must be called prior to #FPROFrame_StreamStart().
2130
+ ///
2131
+ /// The streaming operation streams frames of the same size. In order to change the frame size,
2132
+ /// the streaming must be stopped and deinitialized using the #FPROFrame_StreamStop() and
2133
+ /// FPROFrame_StreamDeinitialize() API's respectively. Then a new stream can be initialized with
2134
+ /// a new frame size.
2135
+ ///
2136
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2137
+ /// @param uiFrameSizeBytes - Size of the frames that will be streamed.
2138
+ /// @param pRootPath - Name of the root path to store the files on disk.
2139
+ /// @param pFilePrefix - A file name prefix to be applied to each file being saved..
2140
+ ///
2141
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2142
+ LIBFLIPRO_API FPROFrame_StreamInitialize(int32_t iHandle, uint32_t uiFrameSizeBytes, wchar_t *pRootPath, wchar_t *pFilePrefix);
2143
+
2144
+ //////////////////////////////////////////
2145
+ ///
2146
+ /// @brief Deinitializes the Streamer interfaces.
2147
+ ///
2148
+ /// This function deinitializes the streamer interfaces. All streaming operations are stopped
2149
+ /// and streaming resources are returned to the system.
2150
+ ///
2151
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2152
+ ///
2153
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2154
+ LIBFLIPRO_API FPROFrame_StreamDeinitialize(int32_t iHandle);
2155
+
2156
+ //////////////////////////////////////////
2157
+ ///
2158
+ /// @brief Start the streaming operation.
2159
+ ///
2160
+ /// This function starts the actual streaming operations. The streaming interfaces must
2161
+ /// have been previously initialized by a successful call to #FPROFrame_StreamInitialize().
2162
+ /// <br>
2163
+ /// This function returns immediately after the stream is started. You should call
2164
+ /// #FPROFrame_StreamGetStatistics() to retrieve the current statistics of the stream and
2165
+ /// check the iStatus member of the FPROSTREAMERSTATUS structure for FPRO_STREAMER_STOPPED
2166
+ /// or an error. Note that FPRO_STREAMER_STOPPED indicates that streaming has stopped from
2167
+ /// from the camera (i.e. the number of expected images have been received). However, there still
2168
+ /// may be images queued internally waiting to be written to disk. If you need an explicit number
2169
+ /// of images to be captured and written to disk, also check the uiDiskFramesWritten of the
2170
+ /// FPROSTREAMERSTATUS structure to make sure all the images have indeed been written to disk.
2171
+ ///
2172
+ ///
2173
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2174
+ /// @param uiFrameCount - Number of frames to stream. Zero (0) == infinite (until the disk fills
2175
+ /// or #FPROFrame_StreamStop is called.
2176
+ /// @param uiFrameIntervalMS - The frame interval in milliseconds() (exposure time + delay).
2177
+ ///
2178
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2179
+ LIBFLIPRO_API FPROFrame_StreamStart(int32_t iHandle,uint32_t uiFrameCount,uint64_t uiFrameIntervalMS);
2180
+
2181
+ //////////////////////////////////////////
2182
+ ///
2183
+ /// @brief Stop the streaming operation.
2184
+ ///
2185
+ /// This function stops the actual streaming operations.
2186
+ ///
2187
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2188
+ ///
2189
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2190
+ LIBFLIPRO_API FPROFrame_StreamStop(int32_t iHandle);
2191
+
2192
+ //////////////////////////////////////////
2193
+ ///
2194
+ /// @brief Stop the streaming operation.
2195
+ ///
2196
+ /// This function stops the actual streaming operations.
2197
+ ///
2198
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2199
+ /// @param pStats - The returned statistics. See #FPROSTREAMSTATS.
2200
+ ///
2201
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2202
+ LIBFLIPRO_API FPROFrame_StreamGetStatistics(int32_t iHandle, FPROSTREAMSTATS *pStats);
2203
+
2204
+ //////////////////////////////////////////
2205
+ ///
2206
+ /// @brief Retrieve the next image available for preview from the image stream.
2207
+ ///
2208
+ /// This function is to be used while image streaming is taking place.
2209
+ /// It will retrieve the available preview from the image stream. The image returned
2210
+ /// is also written to disk as normal. If you call this function faster than the
2211
+ /// exposure time, you will receive the same preview image.
2212
+ /// <br>
2213
+ /// FPROFrame_StreamGetPreviewImageEx() operates the same as FPROFrame_StreamGetPreviewImage() with the
2214
+ /// exception of also returning information about the image and the current stream statistics.
2215
+ ///
2216
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2217
+ /// @param pImage - The buffer for the image data.
2218
+ /// @param pLength - On enter, the size of the buffer pointed to by pImage. On exit, the actual
2219
+ /// number of bytes stored in pImage.
2220
+ /// @param uiTimeoutMSecs - Timeout to wait for an image in milli-seconds. Useful when
2221
+ /// streaming 1 image. Once the first image arrives, there will
2222
+ /// always be an image available for preview until #FPROFrame_StreamDeinitialize
2223
+ /// is called.
2224
+ ///
2225
+ /// @return Greater than or equal to 0 on success, less than 0 on failure. On timeout, the function
2226
+ /// returns success (0), and sets the *pLength parameter to 0.
2227
+ LIBFLIPRO_API FPROFrame_StreamGetPreviewImage(int32_t iHandle, uint8_t* pImage, uint32_t* pLength, uint32_t uiTimeoutMSecs);
2228
+
2229
+
2230
+ //////////////////////////////////////////
2231
+ ///
2232
+ /// @brief Retrieve the next image available for preview from the image stream.
2233
+ ///
2234
+ /// See #FPROFrame_StreamGetPreviewImage().
2235
+ ///
2236
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2237
+ /// @param pImage - The buffer for the image data.
2238
+ /// @param pLength - On enter, the size of the buffer pointed to by pImage. On exit, the actual
2239
+ /// number of bytes stored in pImage.
2240
+ /// @param pInfo - Optional. If provided it contains the requisite information about the image and the stream.
2241
+ /// @param uiTimeoutMSecs - Timeout to wait for an image in milli-seconds. Useful when
2242
+ /// streaming 1 image. Once the first image arrives, there will
2243
+ /// always be an image available for preview until #FPROFrame_StreamDeinitialize
2244
+ /// is called.
2245
+ ///
2246
+ /// @return Greater than or equal to 0 on success, less than 0 on failure. On timeout, the function
2247
+ /// returns success (0), and sets the *pLength parameter to 0.
2248
+ LIBFLIPRO_API FPROFrame_StreamGetPreviewImageEx(int32_t iHandle, uint8_t* pImage, uint32_t* pLength, FPROPREVIEW *pInfo, uint32_t uiTimeoutMSecs);
2249
+
2250
+
2251
+ ///////////////////////////////////////////////////////////////////////////////////
2252
+ ///////////////////////////////////////////////////////////////////////////////////
2253
+ // Control Functions
2254
+ ///////////////////////////////////////////////////////////////////////////////////
2255
+ ///////////////////////////////////////////////////////////////////////////////////
2256
+
2257
+ //////////////////////////////////////////
2258
+ ///
2259
+ /// @brief Get Camera Burst Mode enable
2260
+ ///
2261
+ /// Retrieves the current burst mode setting. See #FPROCtrl_SetBurstModeEnable() for a description of this setting.
2262
+ ///
2263
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2264
+ /// @param pEnable - True if burst mode is enabled, false otherwise.
2265
+ ///
2266
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2267
+ LIBFLIPRO_API FPROCtrl_GetBurstModeEnable(int32_t iHandle, bool *pEnable);
2268
+
2269
+ //////////////////////////////////////////
2270
+ ///
2271
+ /// @brief Reads the current duty cycle of the cooler.
2272
+ ///
2273
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2274
+ /// @param pDutyCycle - Returned Cooler Duty Cycle 0-100%.
2275
+ ///
2276
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2277
+ LIBFLIPRO_API FPROCtrl_GetCoolerDutyCycle(int32_t iHandle, uint32_t *pDutyCycle);
2278
+
2279
+ //////////////////////////////////////////
2280
+ ///
2281
+ /// @brief Returns the current Camera Buffer Bypass state of the camera
2282
+ ///
2283
+ /// Internally, the camera and Host PCIE Fibre boards contain memory used to buffer image data prior to sending
2284
+ /// to the host over the connected interface. This is required to compensate for the
2285
+ /// inherent performance differences of the camera and external interfaces to the host (USB or Fibre).
2286
+ /// For USB connections, it is required to buffer the data internally on the camera or image data
2287
+ /// may be lost. For Fibre connections, the physical transfer rate is in theory fast enough to handle the
2288
+ /// full throughput of the camera. This of course depends on the camera and the actual reliability of
2289
+ /// your Fibre connection. In order to achieve absolute maximum throughput over a Fibre connection, the
2290
+ /// internal memory buffering may be turned off or bypassed using this feature. Note, enabling the memory bypass on either
2291
+ /// or both of the camera and host PCIE boards may result in lost data if your camera is set to deliver data at a higher
2292
+ /// rate that can be processed by your host computer. This is also highly dependent on the performance capability of your
2293
+ /// computer.
2294
+ /// See #FPROCtrl_SetCameraBufferBypass() to set this feature.
2295
+ /// <br>
2296
+ /// NOTE: When a USB connection is established to a camera, this feature is turned off automatically. If you
2297
+ /// subsequently connect over Fibre and assuming you want the buffering turned off, you must set the enable
2298
+ /// again if it was set the last time you were connected over Fibre.
2299
+ /// <br>
2300
+ ///
2301
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2302
+ /// @param pCameraBypassEnable - Returned Buffering Bypass enable.
2303
+ /// @param pHostBypassEnable - Returned Buffering Bypass enable.
2304
+ ///
2305
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2306
+ LIBFLIPRO_API FPROCtrl_GetCameraBufferBypass(int32_t iHandle, bool* pCameraBypassEnable, bool* pHostBypassEnable);
2307
+
2308
+ //////////////////////////////////////////
2309
+ ///
2310
+ /// @brief Returns the current Electrically Black Pixel Enable state from the camera
2311
+ ///
2312
+ /// Some camera models support the ability to produce electrically black reference pixels rather
2313
+ /// than imaging reference pixels. The #FPROCtrl_GetElectricallyBlackPixelEnable() and
2314
+ /// #FPROCtrl_SetElectricallyBlackPixelEnable() API functions are used to enable and disable this
2315
+ /// feature. Consult your camera documentation for the availability of this feature.
2316
+ /// <br>
2317
+ /// This function will return failure if the connected camera does not support this feature.
2318
+ /// <br>
2319
+ ///
2320
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2321
+ /// @param pEnable - Returned Enable state.
2322
+ ///
2323
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2324
+ LIBFLIPRO_API FPROCtrl_GetElectricallyBlackPixelEnable(int32_t iHandle, bool* pEnable);
2325
+
2326
+ //////////////////////////////////////////
2327
+ ///
2328
+ /// @brief Reads the exposure time of the image sensor.
2329
+ ///
2330
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2331
+ /// @param pExposureTime - Returned exposure time in nanoseconds.
2332
+ /// @param pFrameDelay - Returned frame delay (end -to-start) time in nanoseconds.
2333
+ /// When performing multiple exposures with a single trigger, the frame
2334
+ /// delay is the time from the end of exposure of a frame
2335
+ /// to the start of exposure of the next frame.
2336
+ /// @param pImmediate - This parameter affects the way exposure starts when the
2337
+ /// FPROFrame_CaptureStart() function is called. The camera
2338
+ /// image sensor is continually exposing its pixels on a row
2339
+ /// by row basis. When this parameter is set to true, the exposure
2340
+ /// for the frame begins at whatever image sensor row is currently
2341
+ /// being exposed. The raw image data returned by the FPROFrame_GetVideoFrame()
2342
+ /// call begins with this row (most likely not row 0). The row that
2343
+ /// starts the raw video frame is recorded in the meta data for the image frame.
2344
+ ///
2345
+ /// When this parameter is set to false, the camera waits until row 0 is
2346
+ /// being exposed before starting the frame exposure. In this case, the
2347
+ /// image frame data returned by the FPROFrame_GetVideoFrame() call will
2348
+ /// start at row 0.
2349
+ ///
2350
+ /// NOTE: The Exposure Time and Frame Delay values are translated to camera specific units which
2351
+ /// are in turn dependent on the current imaging mode of the camera (e.g. LDR vs HDR).
2352
+ /// The API does its best to perform the necessary conversions automatically
2353
+ /// when the modes are changed. It is recommended, however, to make sure the
2354
+ /// desired exposure times are set after imaging modes have changed using this
2355
+ /// and its counterpart API function FPROCtrl_SetExposure().
2356
+ ///
2357
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2358
+ LIBFLIPRO_API FPROCtrl_GetExposure(int32_t iHandle, uint64_t *pExposureTime, uint64_t *pFrameDelay, bool *pImmediate);
2359
+
2360
+
2361
+ //////////////////////////////////////////
2362
+ ///
2363
+ /// @brief Returns the external trigger settings of the camera.
2364
+ ///
2365
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2366
+ /// @param pTrigInfo - External Trigger setup information. See #FPROEXTTRIGINFO and #FPROEXTTRIGTYPE.
2367
+ ///
2368
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2369
+ LIBFLIPRO_API FPROCtrl_GetExternalTriggerEnable(int32_t iHandle, FPROEXTTRIGINFO* pTrigInfo);
2370
+
2371
+
2372
+ //////////////////////////////////////////
2373
+ ///
2374
+ /// @brief Returns the current Fan status, on or off.
2375
+ ///
2376
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2377
+ /// @param pOn - true: the fan is on, false: the fan is off
2378
+ ///
2379
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2380
+ LIBFLIPRO_API FPROCtrl_GetFanEnable(int32_t iHandle, bool *pOn);
2381
+
2382
+ //////////////////////////////////////////
2383
+ ///
2384
+ /// @brief Returns the current state of an optionally attached GPS unit.
2385
+ ///
2386
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2387
+ /// @param pState - One of FPROGPSSTATE enumerations. See #FPROGPSSTATE for the definitions
2388
+ /// of the states.
2389
+ ///
2390
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2391
+ LIBFLIPRO_API FPROCtrl_GetGPSState(int32_t iHandle, FPROGPSSTATE *pState);
2392
+
2393
+ //////////////////////////////////////////
2394
+ ///
2395
+ /// @brief Reads the current heater configuration.
2396
+ ///
2397
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2398
+ /// @param pPwrPercentage - The setting of the heater in percent.
2399
+ ///
2400
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2401
+ LIBFLIPRO_API FPROCtrl_GetHeaterPower(int32_t iHandle, uint32_t *pPwrPercentage);
2402
+
2403
+ //////////////////////////////////////////
2404
+ ///
2405
+ /// @brief Gets the delay between setting the Illumination on/off via FPROCtrl_SetIlluminationOn()
2406
+ /// and when the illumination actually activates. Each increment is TBD msecs.
2407
+ ///
2408
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2409
+ /// @param pOnDelay - Delay for turning the illumination on in TBD msec increments
2410
+ /// @param pOffDelay - Delay for turning the illumination off in TBD msec increments
2411
+ ///
2412
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2413
+ LIBFLIPRO_API FPROCtrl_GetIlluminationDelay(int32_t iHandle, uint32_t *pOnDelay, uint32_t *pOffDelay);
2414
+
2415
+ //////////////////////////////////////////
2416
+ ///
2417
+ /// @brief Returns the setting of External Illumination- on or off.
2418
+ ///
2419
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2420
+ /// @param pOn - true: illumination on, false: illumination off
2421
+ ///
2422
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2423
+ LIBFLIPRO_API FPROCtrl_GetIlluminationOn(int32_t iHandle, bool *pOn);
2424
+
2425
+ //////////////////////////////////////////
2426
+ ///
2427
+ /// @brief Returns the state of the LED on or off setting.
2428
+ ///
2429
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2430
+ /// @param pOn - true: LED on, false: LED off
2431
+ /// <br>
2432
+ /// See #FPROCtrl_SetLED() for a description of the LED functionality.
2433
+ /// <br>
2434
+ ///
2435
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2436
+ LIBFLIPRO_API FPROCtrl_GetLED(int32_t iHandle, bool *pOn);
2437
+
2438
+ //////////////////////////////////////////
2439
+ ///
2440
+ /// @brief Get the LED Duration setting.
2441
+ ///
2442
+ /// @param iHandle - The handle to an open camera device returned from #FPROCam_Open()
2443
+ /// @param *pDurationUsec - Duration in micro seconds. 0xFFFFFFFF = always on.
2444
+ /// <br>
2445
+ /// <br>
2446
+ /// Note that each camera model may have different resolution capability on the duration
2447
+ /// (i.e. something larger than a micro-second). The FPROCtrl_SetLEDDuration() converts the
2448
+ /// micro-second value passed to the proper resolution for the camera. This call reverses
2449
+ /// the conversion. As such, the value returned by this call may not match the value exactly
2450
+ /// as that passed to FPROCtrl_SetLEDDuration(). On most cameras, the physical resolution for
2451
+ /// this duration is 10usecs.
2452
+ /// <br>
2453
+ /// <br>
2454
+ /// Also see #FPROCtrl_SetLEDDuration() for a description of the LED functionality.
2455
+ /// <br>
2456
+ ///
2457
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2458
+ LIBFLIPRO_API FPROCtrl_GetLEDDuration(int32_t iHandle, uint32_t *pDurationUsec);
2459
+
2460
+ //////////////////////////////////////////
2461
+ ///
2462
+ /// @brief Returns the temperatures on the Host PCIE Fibre Interface card
2463
+ ///
2464
+ /// This function is only applicable to the Host PCIE Fibre Interface card. If the
2465
+ /// iHandle parameter is a valid handle to a connected camera over a Fibre interface,
2466
+ /// then iHandle is used to obtain the host PCIE card information. If iHandle is a negative
2467
+ /// number, then the API looks for an installed card and attempts to get the information from
2468
+ /// the first found card.
2469
+ /// <br>
2470
+ /// <br>
2471
+ /// NOTE: This function only works on Host PCIE Fibre Interface cards version 2.0 or later.
2472
+ /// <br>
2473
+ ///
2474
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2475
+ /// @param pPcieFpga - The PCIE side FPGA Temperature in degC.
2476
+ /// @param pFibreFpga - The Fibre side FPGA Temperature in degC.
2477
+ ///
2478
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2479
+ LIBFLIPRO_API FPROCtrl_GetPCIETemperatures(int32_t iHandle, double* pPcieFpga, double *pFibreFpga);
2480
+
2481
+ //////////////////////////////////////////
2482
+ ///
2483
+ /// @brief Reads the internal sensor temperature of the camera.
2484
+ ///
2485
+ /// Note that if this
2486
+ /// function is called during an exposure and 'Read During Exposure' is not
2487
+ /// enabled, the internal sensor temperature is not explicitly read. The
2488
+ /// last value successfully read will be returned. See the
2489
+ /// FPROCtrl_SetSensorTemperatureReadEnable() API for more information.
2490
+ ///
2491
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2492
+ /// @param pTemp - For the returned temperature, deg C.
2493
+ ///
2494
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2495
+ LIBFLIPRO_API FPROCtrl_GetSensorTemperature(int32_t iHandle, int32_t *pTemp);
2496
+
2497
+ //////////////////////////////////////////
2498
+ ///
2499
+ /// @brief Returns the 'read sensor temperature during exposure' enabled flag.
2500
+ ///
2501
+ /// See FPROCtrl_SetSensorTemperatureReadEnable() for more details.
2502
+ ///
2503
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2504
+ /// @param pEnable - true: 'read sensor temperature during exposure' Enabled
2505
+ /// false: 'read sensor temperature during exposure' Disabled
2506
+ ///
2507
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2508
+ LIBFLIPRO_API FPROCtrl_GetSensorTemperatureReadEnable(int32_t iHandle, bool *pEnable);
2509
+
2510
+
2511
+ //////////////////////////////////////////
2512
+ ///
2513
+ /// @brief Gets the current shutter setting.
2514
+ ///
2515
+ /// By default the camera controls the shutter during exposures. In order for
2516
+ /// the #FPROCtrl_SetShutterOpen() API to correctly control the shutter,
2517
+ /// the #FPROCtrl_SetShutterOverride() API must be called prior with the override
2518
+ /// parameter set to True.
2519
+ ///
2520
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2521
+ /// @param pOpen - true: Shutter open, false: Shutter closed
2522
+ ///
2523
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2524
+ LIBFLIPRO_API FPROCtrl_GetShutterOpen(int32_t iHandle, bool *pOpen);
2525
+
2526
+ //////////////////////////////////////////
2527
+ ///
2528
+ /// @brief Gets the current shutter override setting.
2529
+ ///
2530
+ /// By default the camera controls the shutter during exposures. In order for
2531
+ /// the #FPROCtrl_SetShutterOpen() API to correctly control the shutter,
2532
+ /// the shutter override must be set to True.
2533
+ ///
2534
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2535
+ /// @param pOverride - true: Allows user control of shutter, false: Camera controls shutter
2536
+ ///
2537
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2538
+ LIBFLIPRO_API FPROCtrl_GetShutterOverride(int32_t iHandle, bool *pOverride);
2539
+
2540
+ //////////////////////////////////////////
2541
+ ///
2542
+ /// @brief Reads the various temperatures sensors of the camera.
2543
+ ///
2544
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2545
+ /// @param pAmbientTemp - For the returned Ambient temperature, deg C.
2546
+ /// @param pBaseTemp - For the returned Base temperature, deg C.
2547
+ /// @param pCoolerTemp - For the returned Cooler temperature, deg C.
2548
+ ///
2549
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2550
+ LIBFLIPRO_API FPROCtrl_GetTemperatures(int32_t iHandle, double *pAmbientTemp, double *pBaseTemp, double *pCoolerTemp);
2551
+
2552
+ //////////////////////////////////////////
2553
+ ///
2554
+ /// @brief Returns the Base Temperature Set Point.
2555
+ ///
2556
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2557
+ /// @param pSetPoint - The setpoint value in -75 to 70 degC.
2558
+ ///
2559
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2560
+ LIBFLIPRO_API FPROCtrl_GetTemperatureSetPoint(int32_t iHandle, double *pSetPoint);
2561
+
2562
+ //////////////////////////////////////////
2563
+ ///
2564
+ /// @brief Set Camera Burst Mode enable
2565
+ ///
2566
+ /// Internally, the camera contains memory used to buffer image data prior to sending
2567
+ /// to the host over the connected interface. Burst Mode allows all of the memory to be used to buffer
2568
+ /// images providing a burst of images to the host. Disabling burst mode restricts the camera to buffer only
2569
+ /// a single image, not reading out another from the sensor until the image has been fully sent to the host.
2570
+ /// See #FPROCtrl_GetBurstModeEnable() to retrieve the current setting.
2571
+ /// <br>
2572
+ /// The API sets the camera to burst mode when a connection is established. Disabling burst mode is useful for
2573
+ /// being able to make adjustments between frames such as re-focusing.
2574
+ /// <br>
2575
+ ///
2576
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2577
+ /// @param bEnable - True to enable burst mode, false to disable.
2578
+ ///
2579
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2580
+ LIBFLIPRO_API FPROCtrl_SetBurstModeEnable(int32_t iHandle, bool bEnable);
2581
+
2582
+ //////////////////////////////////////////
2583
+ ///
2584
+ /// @brief Set Camera Buffer Bypass state of the camera
2585
+ ///
2586
+ /// Internally, the camera contains memory used to buffer image data prior to sending
2587
+ /// to the host over the connected interface. See #FPROCtrl_GetCameraBufferBypass() for
2588
+ /// a complete description of this feature.
2589
+ /// <br>
2590
+ /// This feature is only supported on Fibre connections and certain camera models.
2591
+ /// If you attempt to call this function on an unsupported connection, the call returns
2592
+ /// a failure.
2593
+ /// <br>
2594
+ ///
2595
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2596
+ /// @param bCameraBypassEnable - Buffering Bypass enable. Set to true to bypass internal buffering on the camera.
2597
+ /// @param bHostBypassEnable - Buffering Bypass enable. Set to true to bypass internal buffering on the host PCIE card.
2598
+ ///
2599
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2600
+ LIBFLIPRO_API FPROCtrl_SetCameraBufferBypass(int32_t iHandle, bool bCameraBypassEnable, bool bHostBypassEnable);
2601
+
2602
+ //////////////////////////////////////////
2603
+ ///
2604
+ /// @brief Returns the current Electrically Black Pixel Enable state from the camera
2605
+ ///
2606
+ /// See #FPROCtrl_GetElectricallyBlackPixelEnable() for a description of this feature.
2607
+ /// <br>
2608
+ /// This function will return failure if the connected camera does not support this feature.
2609
+ /// <br>
2610
+ ///
2611
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2612
+ /// @param bEnable - Enable state to set.
2613
+ ///
2614
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2615
+ LIBFLIPRO_API FPROCtrl_SetElectricallyBlackPixelEnable(int32_t iHandle, bool bEnable);
2616
+
2617
+ //////////////////////////////////////////
2618
+ ///
2619
+ /// @brief Sets the exposure time of the image sensor.
2620
+ ///
2621
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2622
+ /// @param uiExposureTime - Exposure time in nanosecond increments.
2623
+ /// @param uiFrameDelay - Frame delay (end - to - start) time in nanoseconds.
2624
+ /// When performing multiple exposures with a single trigger, the frame
2625
+ /// delay is the time from the end of exposure of a frame
2626
+ /// to the start of exposure of the next frame.
2627
+ /// @param bImmediate - This parameter affects the way exposure starts when the
2628
+ /// FPROFrame_CaptureStart() function is called. The camera
2629
+ /// image sensor is continually exposing its pixels on a row
2630
+ /// by row basis. When this parameter is set to true, the exposure
2631
+ /// for the frame begins at whatever image sensor row is currently
2632
+ /// being exposed. The raw image data returned by the FPROFrame_GetVideoFrame()
2633
+ /// call begins with this row (most likely not row 0). The row that
2634
+ /// starts the raw video frame is recorded in the meta data for the image frame.
2635
+ ///
2636
+ /// When this parameter is set to false, the camera waits until row 0 is
2637
+ /// being exposed before starting the frame exposure. In this case, the
2638
+ /// image frame data returned by the FPROFrame_GetVideoFrame() call will
2639
+ /// start at row 0.
2640
+ ///
2641
+ /// <br>
2642
+ /// NOTE: The Exposure Time and Frame Delay values are translated to camera specific units which
2643
+ /// are in turn dependent on the current imaging mode of the camera (e.g. LDR vs HDR),
2644
+ /// as well as the camera model.
2645
+ /// The API does its best to perform the necessary conversions automatically
2646
+ /// when the modes are changed. It is recommended, however, to make sure the
2647
+ /// desired exposure times are set after imaging modes have changed using this
2648
+ /// and its counterpart API function #FPROCtrl_GetExposure().
2649
+ ///
2650
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2651
+ LIBFLIPRO_API FPROCtrl_SetExposure(int32_t iHandle, uint64_t uiExposureTime, uint64_t uiFrameDelay, bool bImmediate);
2652
+
2653
+ //////////////////////////////////////////
2654
+ ///
2655
+ /// @brief Sets the exposure time of the image sensor.
2656
+ ///
2657
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2658
+ /// @param uiExposureTime - Exposure time in nanosecond increments.
2659
+ /// @param uiFrameDelay - Frame delay (end - to - start) time in nanoseconds.
2660
+ /// When performing multiple exposures with a single trigger, the frame
2661
+ /// delay is the time from the end of exposure of a frame
2662
+ /// to the start of exposure of the next frame.
2663
+ /// @param bImmediate - This parameter affects the way exposure starts when the
2664
+ /// FPROFrame_CaptureStart() function is called. The camera
2665
+ /// image sensor is continually exposing its pixels on a row
2666
+ /// by row basis. When this parameter is set to true, the exposure
2667
+ /// for the frame begins at whatever image sensor row is currently
2668
+ /// being exposed. The raw image data returned by the FPROFrame_GetVideoFrame()
2669
+ /// call begins with this row (most likely not row 0). The row that
2670
+ /// starts the raw video frame is recorded in the meta data for the image frame.
2671
+ ///
2672
+ /// When this parameter is set to false, the camera waits until row 0 is
2673
+ /// being exposed before starting the frame exposure. In this case, the
2674
+ /// image frame data returned by the FPROFrame_GetVideoFrame() call will
2675
+ /// start at row 0.
2676
+ /// @param pActualExposureTime - If not NULL, the actual Exposure Time will be returned.
2677
+ /// This is the same value that would be returned by #FPROCtrl_GetExposure().
2678
+ /// See NOTE below.
2679
+ /// @param pActualFrameDelay - If not NULL, the actual Frame Delay will be returned.
2680
+ /// This is the same value that would be returned by #FPROCtrl_GetExposure().
2681
+ /// See NOTE below.
2682
+ ///
2683
+ /// <br>
2684
+ /// NOTE: The Exposure Time and Frame Delay values are translated to camera specific units which
2685
+ /// are in turn dependent on the current imaging mode of the camera (e.g. LDR vs HDR),
2686
+ /// as well as the camera model.
2687
+ /// The API does its best to perform the necessary conversions automatically
2688
+ /// when the modes are changed. It is recommended, however, to make sure the
2689
+ /// desired exposure times are set after imaging modes have changed using this
2690
+ /// and its counterpart API function #FPROCtrl_GetExposure().
2691
+ ///
2692
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2693
+ LIBFLIPRO_API FPROCtrl_SetExposureEx(int32_t iHandle, uint64_t uiExposureTime, uint64_t uiFrameDelay, bool bImmediate, uint64_t* pActualExposureTime, uint64_t* pActualFrameDelay);
2694
+
2695
+ //////////////////////////////////////////
2696
+ ///
2697
+ /// @brief Enables or disables the external trigger of the camera.
2698
+ ///
2699
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2700
+ /// @param uiFrameCount - The number of images to get (dependent on pTrigInfo setup).
2701
+ /// @param pTrigInfo - External Trigger setup information. See #FPROEXTTRIGINFO and #FPROEXTTRIGTYPE.
2702
+ ///
2703
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2704
+ LIBFLIPRO_API FPROCtrl_SetExternalTriggerEnable(int32_t iHandle, uint32_t uiFrameCount, FPROEXTTRIGINFO *pTrigInfo);
2705
+
2706
+ //////////////////////////////////////////
2707
+ ///
2708
+ /// @brief Turns the Fan on or off.
2709
+ ///
2710
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2711
+ /// @param bOn - true: turns the fan on, false: turns the fan off
2712
+ ///
2713
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2714
+ LIBFLIPRO_API FPROCtrl_SetFanEnable(int32_t iHandle, bool bOn);
2715
+
2716
+ //////////////////////////////////////////
2717
+ ///
2718
+ /// @brief Turns the Heater on or off at the specified power level.
2719
+ ///
2720
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2721
+ /// @param uiPwrPercentage -Specifies the power level as a percentage (0-100)
2722
+ ///
2723
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2724
+ LIBFLIPRO_API FPROCtrl_SetHeaterPower(int32_t iHandle,uint32_t uiPwrPercentage);
2725
+
2726
+ //////////////////////////////////////////
2727
+ ///
2728
+ /// @brief Sets the illumination delay.
2729
+ ///
2730
+ /// The illumination delay is the time between setting the Illumination on/off via
2731
+ /// #FPROCtrl_SetIlluminationOn and when the illumination actually activates.
2732
+ /// Each increment is TBD msecs.
2733
+ ///
2734
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2735
+ /// @param uiOnDelay - Delay for turning the illumination on in TBD msec increments
2736
+ /// @param uiOffDelay - Delay for turning the illumination off in TBD msec increments
2737
+ ///
2738
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2739
+ LIBFLIPRO_API FPROCtrl_SetIlluminationDelay(int32_t iHandle, uint16_t uiOnDelay, uint16_t uiOffDelay);
2740
+
2741
+ //////////////////////////////////////////
2742
+ ///
2743
+ /// @brief Turns External Illumination on or off.
2744
+ ///
2745
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2746
+ /// @param bOn - true: turns illumination on, false: turns illumination off
2747
+ ///
2748
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2749
+ LIBFLIPRO_API FPROCtrl_SetIlluminationOn(int32_t iHandle, bool bOn);
2750
+
2751
+ //////////////////////////////////////////
2752
+ ///
2753
+ /// @brief Turn the LED on or off.
2754
+ ///
2755
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2756
+ /// @param bOn - true: Turns the LED on, false: Turns the LED off
2757
+ /// <br>
2758
+ /// <br>
2759
+ /// Based on the camera model, this function may work in conjunction with the #FPROCtrl_SetLEDDuration()
2760
+ /// API. In those cases, this call must be made with a value of TRUE in order for the
2761
+ /// #FPROCtrl_SetLEDDuration() to toggle the LED.
2762
+ /// <br>
2763
+ ///
2764
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2765
+ LIBFLIPRO_API FPROCtrl_SetLED(int32_t iHandle, bool bOn);
2766
+
2767
+ //////////////////////////////////////////
2768
+ ///
2769
+ /// @brief Set LED Duration during exposure.
2770
+ ///
2771
+ /// @param iHandle - The handle to an open camera device returned from #FPROCam_Open()
2772
+ /// @param uiDurationUSec - Duration in micro seconds. 0xFFFFFFFF = always on.
2773
+ /// <br>
2774
+ /// <br>
2775
+ /// This call sets the duration of the LED flash during exposure. This call is not available on all
2776
+ /// camera models. It was introduced on the 4040 models. This call works in conjunction with the #FPROCtrl_SetLED()
2777
+ /// API. In order for the camera to turn the LED on for the given duration, #FPROCtrl_SetLED() must have been called
2778
+ /// with a value of TRUE.
2779
+ /// <br>
2780
+ /// <br>
2781
+ /// To simply turn the LED on and leave it on, pass a value of 0xFFFFFFFF in the uiDurationUSec parameter. As with other
2782
+ /// duration values, #FPROCtrl_SetLED() must be called with a value of TRUE.
2783
+ /// <br>
2784
+ ///
2785
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2786
+ LIBFLIPRO_API FPROCtrl_SetLEDDuration(int32_t iHandle, uint32_t uiDurationUSec);
2787
+
2788
+ //////////////////////////////////////////
2789
+ ///
2790
+ /// @brief Enables/disables physical reading of the image sensor temperature during exposures.
2791
+ ///
2792
+ /// The sensor temperature is read using the #FPROCtrl_GetSensorTemperature
2793
+ /// API call. If that call is made during an exposure, it will physically read
2794
+ /// the sensor temperature only if this call was made prior to enable the reading.
2795
+ /// If this 'read sensor temperature during exposure' is not enabled, then the
2796
+ /// #FPROCtrl_GetSensorTemperature call will return the previous successful temperature
2797
+ /// read from the imaging sensor.
2798
+ /// <br>NOTE: This enable only pertains to requests during an exposure. If temperature
2799
+ /// readings are requested outside of an exposure boundary, this enable has no effect.
2800
+ ///
2801
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2802
+ /// @param bEnable - true: Enable 'read sensor temperature during exposure'.
2803
+ /// false: Disable 'read sensor temperature during exposure'.
2804
+ ///
2805
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2806
+ LIBFLIPRO_API FPROCtrl_SetSensorTemperatureReadEnable(int32_t iHandle, bool bEnable);
2807
+
2808
+
2809
+ //////////////////////////////////////////
2810
+ ///
2811
+ /// @brief Opens/Close the shutter.
2812
+ ///
2813
+ /// By default the camera controls the shutter during exposures. In order for
2814
+ /// the #FPROCtrl_SetShutterOpen() API to correctly control the shutter,
2815
+ /// the #FPROCtrl_SetShutterOverride() API must be called prior with the override
2816
+ /// parameter set to True.
2817
+ ///
2818
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2819
+ /// @param bOpen - true: opens the shutter, false: closes the shutter
2820
+ ///
2821
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2822
+ LIBFLIPRO_API FPROCtrl_SetShutterOpen(int32_t iHandle, bool bOpen);
2823
+
2824
+ //////////////////////////////////////////
2825
+ ///
2826
+ /// @brief Sets the shutter control override.
2827
+ ///
2828
+ /// By default the camera controls the shutter during exposures. In order for
2829
+ /// the #FPROCtrl_SetShutterOpen() API to correctly control the shutter,
2830
+ /// the shutter override must be set to True.
2831
+ ///
2832
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2833
+ /// @param bOverride - true: Allows user control of shutter, false: Camera controls shutter
2834
+ ///
2835
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2836
+ LIBFLIPRO_API FPROCtrl_SetShutterOverride(int32_t iHandle, bool bOverride);
2837
+
2838
+ //////////////////////////////////////////
2839
+ ///
2840
+ /// @brief Sets the Base Temperature Set Point.
2841
+ ///
2842
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2843
+ /// @param dblSetPoint - The setpoint value to set in -75 to 70 degC.
2844
+ ///
2845
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2846
+ LIBFLIPRO_API FPROCtrl_SetTemperatureSetPoint(int32_t iHandle, double dblSetPoint);
2847
+
2848
+ //////////////////////////////////////////
2849
+ // Sensor Functions
2850
+ //////////////////////////////////////////
2851
+ //////////////////////////////////////////
2852
+ ///
2853
+ /// @brief Retrieves the current pixel bin settings.
2854
+ ///
2855
+ /// The bin setting for horizontal (x direction) and vertical (Y direction) binning.
2856
+ ///
2857
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2858
+ /// @param pXBin - For returned horizontal bin setting.
2859
+ /// @param pYBin - For returned vertical bin setting.
2860
+ ///
2861
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2862
+ LIBFLIPRO_API FPROSensor_GetBinning(int32_t iHandle, uint32_t *pXBin, uint32_t *pYBin);
2863
+
2864
+ //////////////////////////////////////////
2865
+ ///
2866
+ /// @brief Retrieves the Binning table capability from the camera.
2867
+ ///
2868
+ /// The available bin settings for horizontal (x direction) and vertical (Y direction) binning.
2869
+ ///
2870
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2871
+ /// @param pBinTable - User allocated buffer for the bin settings. The size of the table is
2872
+ /// reported in the Capabilities structure returned by #FPROSensor_GetCapabilities().
2873
+ /// @param pTableSizeBytes - On entry, the size of the buffer. On exit, the number of bytes used.
2874
+ ///
2875
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2876
+ /// On success, the returned size may be 0 indicating no binning table exists and
2877
+ /// the only available binning is 1:1.
2878
+ /// <br>
2879
+ /// Each binning table entry is 32 bits wide. The horizontal binning value is contained
2880
+ /// in the upper 16 bits and the vertical binning value is contained in the lower 16 bits. There
2881
+ /// is a binning table entry for each of the horizontal and vertical binning combinations available
2882
+ /// for the camera. One to one (1:1) binning is always allowed. For example, if 2x2 and 2x4 binning
2883
+ /// (horizontal x vertical) is supported, the two binning table entries would be in the binning table as follows:
2884
+ /// 0x00020002, 0x00020004.
2885
+ /// <br>
2886
+ /// If the high bit is set for a given binning, then all binnings up to and including the value with the
2887
+ /// high bit masked are valid. For example, a binning table entry of 0x88008800 would allow all combinations
2888
+ /// of binning values from 1:1 through 2048x2048. A binning table entry of 0x88000001 indicates that all horizontal
2889
+ /// binning values from 1 through 2048 are valid with a vertical binning value of 1;
2890
+ /// <br>
2891
+ /// If not enough room is given for the buffer, the function fails and the
2892
+ /// size required is returned in pTableSizeBytes. If a different failure occurs,
2893
+ /// the returned size is set to zero (0).
2894
+ LIBFLIPRO_API FPROSensor_GetBinningTable(int32_t iHandle, uint32_t *pBinTable, uint32_t *pTableSizeBytes);
2895
+
2896
+ //////////////////////////////////////////
2897
+ ///
2898
+ /// @brief Retrieves the current Black Level Adjustment values.
2899
+ ///
2900
+ /// For the ex (extended) function, a channel must be specified, on of the #FPROBLACKADJUSTCHAN
2901
+ /// enumeration values. Note that not all cameras support multiple channels for the
2902
+ /// Black Level Adjustment values. Consult your users manual for specifics on your device.
2903
+ /// <br>
2904
+ /// If you call the #FPROSensor_GetBlackLevelAdjust() API for a camera that does support
2905
+ /// multiple channels, the channel defaults to the first channel on the device.
2906
+ /// <br>
2907
+ /// If you call the 'ex' (extended) function on a camera that does not support multiple channels,
2908
+ /// the eChan parameter is ignored and the single supported channel is retrieved.
2909
+ /// <br>
2910
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2911
+ /// @param pAdjustValue - For returned adjustment values.
2912
+ ///
2913
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2914
+ LIBFLIPRO_API FPROSensor_GetBlackLevelAdjust(int32_t iHandle, uint32_t *pAdjustValue);
2915
+
2916
+ //////////////////////////////////////////
2917
+ ///
2918
+ /// @brief Retrieves the current Black Level Adjustment values for the given channel.
2919
+ ///
2920
+ /// <br>
2921
+ /// See #FPROSensor_GetBlackLevelAdjust().
2922
+ /// <br>
2923
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2924
+ /// @param eChan - The adjustment channel to retrieve.
2925
+ /// @param pAdjustValue - For returned adjustment values.
2926
+ ///
2927
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2928
+ LIBFLIPRO_API FPROSensor_GetBlackLevelAdjustEx(int32_t iHandle, FPROBLACKADJUSTCHAN eChan, uint32_t *pAdjustValue);
2929
+
2930
+ //////////////////////////////////////////
2931
+ ///
2932
+ /// @brief Retrieves the current Black Sun Adjustment values.
2933
+ ///
2934
+ /// For the ex (extended) function, a channel must be specified, on of the #FPROBLACKADJUSTCHAN
2935
+ /// enumeration values. Note that not all cameras support multiple channels for the
2936
+ /// Black Sun Adjustment values. Consult your users manual for specifics on your device.
2937
+ /// If you call the #FPROSensor_GetBlackSunAdjust() API for a camera that does support
2938
+ /// multiple channels, the channel defaults to the first channel on the device.
2939
+ /// <br>
2940
+ /// <br>
2941
+ /// If you call the 'ex' (extended) function on a camera that does not support multiple channels,
2942
+ /// the eChan parameter is ignored and the single supported channel is retrieved.
2943
+ /// <br>
2944
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2945
+ /// @param pAdjustValue - For returned adjustment values.
2946
+ ///
2947
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2948
+ LIBFLIPRO_API FPROSensor_GetBlackSunAdjust(int32_t iHandle, uint32_t *pAdjustValue);
2949
+
2950
+ //////////////////////////////////////////
2951
+ ///
2952
+ /// @brief Retrieves the current Black Sun Adjustment values for the given channel.
2953
+ ///
2954
+ /// <br>
2955
+ /// See #FPROSensor_GetBlackSunAdjust().
2956
+ /// <br>
2957
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2958
+ /// @param eChan - The adjustment channel to retrieve.
2959
+ /// @param pAdjustValue - For returned adjustment values.
2960
+ ///
2961
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2962
+ LIBFLIPRO_API FPROSensor_GetBlackSunAdjustEx(int32_t iHandle, FPROBLACKADJUSTCHAN eChan, uint32_t *pAdjustValue);
2963
+
2964
+ //////////////////////////////////////////
2965
+ ///
2966
+ /// @brief Retrieves the sensor capabilities structure from the camera.
2967
+ ///
2968
+ /// Note that you
2969
+ /// may pass in a generic buffer in which to store the capabilities rather than a
2970
+ /// strict FPROCAP structure pointer. The pCapLength parameter is the length of
2971
+ /// the buffer you are passing. It is used to determine if there is enough space in
2972
+ /// the buffer prior to reading the capabilities.
2973
+ /// <br><br>
2974
+ /// The camera is asked for the size of the capabilities prior to retrieving them.
2975
+ /// If sufficient space exists (as specified by the pCapLength parameter), then
2976
+ /// the capabilities are retrieved. This sequence allows older API's to work with
2977
+ /// newer cameras and different capabilities structures. The length and version fields
2978
+ /// should be parsed by the caller in order to determine the proper structure format.
2979
+ /// <br><br>
2980
+ /// In the event of failure, if the *pCapLength value is > 0, the call failed because the buffer
2981
+ /// passed in was too small. In this case, the *pCapLength value is the size of the buffer
2982
+ /// required to read the capabilities successfully.
2983
+ ///
2984
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
2985
+ /// @param pCap - Buffer to store the capabilities structure
2986
+ /// @param pCapLength - On entry the size of the buffer pointed to by pCap. On exit,
2987
+ /// the actual size of the structure returned.
2988
+ ///
2989
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
2990
+ LIBFLIPRO_API FPROSensor_GetCapabilities(int32_t iHandle, FPROCAP *pCap, uint32_t *pCapLength);
2991
+
2992
+ //////////////////////////////////////////
2993
+ ///
2994
+ /// @brief Retrieves the current setting for the Gain for the specified table.
2995
+ ///
2996
+ /// Note: The index returned is the index into the table as returned by
2997
+ /// FPROSensor_GetGainTable().
2998
+ ///
2999
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3000
+ /// @param eTable - The table to retrieve.
3001
+ /// @param pGainIndex - Buffer for the returned index.
3002
+ ///
3003
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3004
+ LIBFLIPRO_API FPROSensor_GetGainIndex(int32_t iHandle, FPROGAINTABLE eTable, uint32_t *pGainIndex);
3005
+
3006
+ //////////////////////////////////////////
3007
+ ///
3008
+ /// @brief Retrieves the specified Gain Table.
3009
+ ///
3010
+ /// The pNumEntries command should be derived from the
3011
+ /// uiLDRGain, uiHDRGain, or uiGlobalGain values in the #FPROCAP capabilities structure.
3012
+ ///
3013
+ /// Note: Each gain that is returned is scaled to produce an integer number.
3014
+ /// The scale factor is defined as #FPRO_GAIN_SCALE_FACTOR in the API.
3015
+ ///
3016
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3017
+ /// @param eTable - The table to retrieve.
3018
+ /// @param pGainValues - Buffer for the returned values.
3019
+ /// @param pNumEntries - On entry, the number of locations available in the buffer.
3020
+ /// On exit, the actual number of values inserted in the table.
3021
+ ///
3022
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3023
+ LIBFLIPRO_API FPROSensor_GetGainTable(int32_t iHandle, FPROGAINTABLE eTable, FPROGAINVALUE *pGainValues, uint32_t *pNumEntries);
3024
+
3025
+ //////////////////////////////////////////
3026
+ ///
3027
+ /// @brief Retrieves the current setting for HDR enable.
3028
+ ///
3029
+ /// The HDR setting is enabled/disabled by setting the appropriate mode using the #FPROSensor_SetMode
3030
+ /// API. As such there is no corresponding 'set' function for HDR enable. This
3031
+ /// API is simply a convenience function to allow a user to determine if the selected
3032
+ /// mode has enabled HDR frames. Knowing this is of course critical to determining how much
3033
+ /// image data will be supplied by the camera for each exposure. When HDR is enabled, there will
3034
+ /// be twice the image data returned for a frame (including dummy pixels).
3035
+ ///
3036
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3037
+ /// @param pHDREnable - Buffer for the returned HDR enable flag.
3038
+ ///
3039
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3040
+ LIBFLIPRO_API FPROSensor_GetHDREnable(int32_t iHandle, bool* pHDREnable);
3041
+
3042
+
3043
+ //////////////////////////////////////////
3044
+ ///
3045
+ /// @brief Retrieves the High Gain Only Mode.
3046
+ ///
3047
+ /// Returns the High Gain Only Mode setting.
3048
+ /// <br>
3049
+ /// Note: The High Gain Only Mode is not applicable to all camera models.
3050
+ ///
3051
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3052
+ /// @param pHighGainOnly - High Gain only mode flag.
3053
+ ///
3054
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3055
+ LIBFLIPRO_API FPROSensor_GetHighGainOnlyEnable(int32_t iHandle, bool *pHighGainOnly);
3056
+
3057
+ //////////////////////////////////////////
3058
+ ///
3059
+ /// @brief Retrieves the current mode name for the specified index.
3060
+ ///
3061
+ /// The number of available modes are retrieved using the #FPROSensor_GetModeCount API.
3062
+ ///
3063
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3064
+ /// @param uiModeIndex - The index of the mode to retrieve.
3065
+ /// @param pMode - Buffer for the returned mode information.
3066
+ ///
3067
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3068
+ LIBFLIPRO_API FPROSensor_GetMode(int32_t iHandle, uint32_t uiModeIndex, FPROSENSMODE *pMode);
3069
+
3070
+ //////////////////////////////////////////
3071
+ ///
3072
+ /// @brief Retrieves the current mode count and current mode index setting.
3073
+ ///
3074
+ /// Mode information for a given index is retrieved using the
3075
+ /// #FPROSensor_GetMode() API.
3076
+ ///
3077
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3078
+ /// @param pCount - Buffer for the number of available modes.
3079
+ /// @param pCurrentMode - Buffer for index of the currently assigned mode.
3080
+ ///
3081
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3082
+ LIBFLIPRO_API FPROSensor_GetModeCount(int32_t iHandle, uint32_t *pCount,uint32_t *pCurrentMode);
3083
+
3084
+ //////////////////////////////////////////
3085
+ ///
3086
+ /// @brief Retrieves the current sensor read out configuration on supported models.
3087
+ ///
3088
+ /// For camera models that support sensor channel read out configuration, this API
3089
+ /// retrieves the current setting. For models that do not support this feature, this
3090
+ /// function always returns success with a value of 0 for the configuration.
3091
+ ///
3092
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3093
+ /// @param pReadCfg - Buffer for the configuration.
3094
+ ///
3095
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3096
+ LIBFLIPRO_API FPROSensor_GetReadoutConfiguration(int32_t iHandle, FPROSENSREADCFG *pReadCfg);
3097
+
3098
+ //////////////////////////////////////////
3099
+ ///
3100
+ /// @brief Retrieves the Samples Per Pixel settings on the sensor.
3101
+ /// <br><br>
3102
+ /// NOTE: This function is not supported on on all camera models. Consult
3103
+ /// your documentation for your specific camera.
3104
+ /// <br>
3105
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3106
+ /// @param pSamplesPerPixel - Returned Samples Per Pixel Setting.
3107
+ ///
3108
+ /// @return Greater than or equal to 0 on success, less than 0 on failure. On devices that
3109
+ /// do not support this setting, 0 is always returned with pSamplesPerPixel set to FPROCMS_1.
3110
+ LIBFLIPRO_API FPROSensor_GetSamplesPerPixel(int32_t iHandle, FPROCMS *pSamplesPerPixel);
3111
+
3112
+ //////////////////////////////////////////
3113
+ ///
3114
+ /// @brief Retrieves the current pixel scan direction settings on the sensor.
3115
+ ///
3116
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3117
+ /// @param pHInverted - Returned horizontal scan direction: False = Normal, True = Inverted.
3118
+ /// @param pVInverted - Returned vertical scan direction: False = Normal, True = Inverted.
3119
+ ///
3120
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3121
+ LIBFLIPRO_API FPROSensor_GetScanDirection(int32_t iHandle, bool *pHInverted,bool *pVInverted);
3122
+
3123
+ //////////////////////////////////////////
3124
+ ///
3125
+ /// @brief Returns the sensor re-training setting.
3126
+ ///
3127
+ ///
3128
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3129
+ /// @param pEnable - true: Forces sensor to undergo training. False - stops the sensor training.
3130
+ ///
3131
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3132
+ LIBFLIPRO_API FPROSensor_GetTrainingEnable(int32_t iHandle, bool *pEnable);
3133
+
3134
+ //////////////////////////////////////////
3135
+ ///
3136
+ /// @brief Sets the analog gain for the sensor.
3137
+ ///
3138
+ /// Note: Not all camera models support this feature. Consult you camera
3139
+ /// documentation for details. In addition, cameras do not currently
3140
+ /// support read back of this value so there is no corresponding
3141
+ /// FPROSensor_GetAnalogGain() API.
3142
+ ///
3143
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3144
+ /// @param iGainValue - The analog gain value to set.
3145
+ ///
3146
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3147
+ LIBFLIPRO_API FPROSensor_SetAnalogGain(int32_t iHandle, int32_t iGainValue);
3148
+
3149
+ //////////////////////////////////////////
3150
+ ///
3151
+ /// @brief Sets the desired horizontal and vertical binning.
3152
+ ///
3153
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3154
+ /// @param uiXBin - Horizontal bin setting.
3155
+ /// @param uiYBin - Vertical bin setting.
3156
+ ///
3157
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3158
+ LIBFLIPRO_API FPROSensor_SetBinning(int32_t iHandle, uint32_t uiXBin, uint32_t uiYBin);
3159
+
3160
+ //////////////////////////////////////////
3161
+ ///
3162
+ /// @brief Sets the current Black Level Adjustment values.
3163
+ ///
3164
+ /// For the ex (extended) function, a channel must be specified, on of the #FPROBLACKADJUSTCHAN
3165
+ /// enumeration values. Note that not all cameras support multiple channels for the
3166
+ /// Black Level Adjustment values. Consult your users manual for specifics on your device.
3167
+ /// <br>
3168
+ /// If you call the #FPROSensor_SetBlackLevelAdjust() API for a camera that does support
3169
+ /// multiple channels, the channel defaults to the first channel on the device.
3170
+ /// <br>
3171
+ /// If you call the ex (extended) function on a camera that does not support multiple channels,
3172
+ /// the eChan parameter is ignored and the single support channel is set.
3173
+ /// <br>
3174
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3175
+ /// @param uiAdjustValue - Value to set.
3176
+ ///
3177
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3178
+ LIBFLIPRO_API FPROSensor_SetBlackLevelAdjust(int32_t iHandle, uint32_t uiAdjustValue);
3179
+
3180
+
3181
+ //////////////////////////////////////////
3182
+ ///
3183
+ /// @brief Sets the current Black Level Adjustment value for the given channel.
3184
+ ///
3185
+ /// See #FPROSensor_SetBlackLevelAdjust.
3186
+ /// <br>
3187
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3188
+ /// @param eChan - The adjustment channel to set.
3189
+ /// @param uiAdjustValue - Value to set.
3190
+ ///
3191
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3192
+ LIBFLIPRO_API FPROSensor_SetBlackLevelAdjustEx(int32_t iHandle, FPROBLACKADJUSTCHAN eChan, uint32_t uiAdjustValue);
3193
+
3194
+ //////////////////////////////////////////
3195
+ ///
3196
+ /// @brief Sets the current Black Sun Adjustment value.
3197
+ ///
3198
+ /// For the ex (extended) function, a channel must be specified, on of the #FPROBLACKADJUSTCHAN
3199
+ /// enumeration values. Note that not all cameras support multiple channels for the
3200
+ /// Black Sun Adjustment values. Consult your users manual for specifics on your device.
3201
+ /// If you call the #FPROSensor_SetBlackSunAdjust() API for a camera that does support
3202
+ /// multiple channels, the channel defaults to the first channel on the device.
3203
+ /// <br>
3204
+ /// If you call the 'ex' (extended) function on a camera that does not support multiple channels,
3205
+ /// the eChan parameter is ignored and the single support channel is set.
3206
+ /// <br>
3207
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3208
+ /// @param uiAdjustValue - Value to set.
3209
+ ///
3210
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3211
+ LIBFLIPRO_API FPROSensor_SetBlackSunAdjust(int32_t iHandle, uint32_t uiAdjustValue);
3212
+
3213
+
3214
+ //////////////////////////////////////////
3215
+ ///
3216
+ /// @brief Sets the current Black Sun Adjustment value for the given channel.
3217
+ ///
3218
+ /// See #FPROSensor_SetBlackSunAdjust.
3219
+ /// <br>
3220
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3221
+ /// @param eChan - The adjustment channel to set.
3222
+ /// @param uiAdjustValue - Value to set.
3223
+ ///
3224
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3225
+ LIBFLIPRO_API FPROSensor_SetBlackSunAdjustEx(int32_t iHandle, FPROBLACKADJUSTCHAN eChan, uint32_t uiAdjustValue);
3226
+
3227
+ //////////////////////////////////////////
3228
+ ///
3229
+ /// @brief Sets the High Gain Only Mode.
3230
+ /// <br>
3231
+ /// Note: The High Gain Only Mode is not applicable to all camera models. In addition, it is only
3232
+ /// applicable in HDR modes. When in an HDR mode, if the High Gain Only flag is set, only the High
3233
+ /// Gain image will be returned by the camera.
3234
+ ///
3235
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3236
+ /// @param bHighGainOnly - High Gain only mode flag.
3237
+ ///
3238
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3239
+ LIBFLIPRO_API FPROSensor_SetHighGainOnlyEnable(int32_t iHandle, bool bHighGainOnly);
3240
+
3241
+ //////////////////////////////////////////
3242
+ ///
3243
+ /// @brief Sets the current setting for the Gain for the specified table.
3244
+ ///
3245
+ /// Note: The index is the index into the table as returned by
3246
+ /// FPROSensor_GetGainTable().
3247
+ /// Note: When setting an LDR gain table index, if the camera is in an LDR mode,
3248
+ /// as set by #FPROSensor_SetMode(), the HDR gain index is set to match to maintain
3249
+ /// image integrity. If you attempt
3250
+ /// to set an HDR index when in an LDR mode, the function will return an error. Set the
3251
+ /// mode first using #FPROSensor_SetMode(), then override the gain settings as desired
3252
+ /// using this function.
3253
+ ///
3254
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3255
+ /// @param eTable - The table to retrieve.
3256
+ /// @param uiGainIndex - Index value to set.
3257
+ ///
3258
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3259
+ LIBFLIPRO_API FPROSensor_SetGainIndex(int32_t iHandle, FPROGAINTABLE eTable, uint32_t uiGainIndex);
3260
+
3261
+ //////////////////////////////////////////
3262
+ ///
3263
+ /// @brief Sets the current mode specified by the given index.
3264
+ ///
3265
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3266
+ /// @param uiModeIndex - The index of the mode to set.
3267
+ ///
3268
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3269
+ LIBFLIPRO_API FPROSensor_SetMode(int32_t iHandle, uint32_t uiModeIndex);
3270
+
3271
+ //////////////////////////////////////////
3272
+ ///
3273
+ /// @brief Sets the sensor read out configuration on supported models.
3274
+ ///
3275
+ /// For camera models that support sensor channel read out configuration, this API
3276
+ /// sets the given setting. The function will return failure if the given configuration
3277
+ /// is invalid for the camera model connected. For models that do not support this feature, this
3278
+ /// function has no effect.
3279
+ ///
3280
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3281
+ /// @param eReadCfg - The configuration to set.
3282
+ ///
3283
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3284
+ LIBFLIPRO_API FPROSensor_SetReadoutConfiguration(int32_t iHandle, FPROSENSREADCFG eReadCfg);
3285
+
3286
+ //////////////////////////////////////////
3287
+ ///
3288
+ /// @brief Sets the Samples Per Pixel settings on the sensor.
3289
+ /// <br><br>
3290
+ /// NOTE: This function is not supported on on all camera models. Consult
3291
+ /// your documentation for your specific camera.
3292
+ /// <br>
3293
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3294
+ /// @param eSamplesPerPixel - The Samples Per Pixel Setting to set.
3295
+ ///
3296
+ /// @return Greater than or equal to 0 on success, less than 0 on failure. On devices that
3297
+ /// do not support this setting, 0 is always returned.
3298
+ LIBFLIPRO_API FPROSensor_SetSamplesPerPixel(int32_t iHandle, FPROCMS eSamplesPerPixel);
3299
+
3300
+ //////////////////////////////////////////
3301
+ ///
3302
+ /// @brief Retrieves the current pixel scan direction settings on the sensor.
3303
+ ///
3304
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3305
+ /// @param bHInverted - Horizontal scan direction: False = Normal, True = Inverted.
3306
+ /// @param bVInverted - Vertical scan direction: False = Normal, True = Inverted..
3307
+ ///
3308
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3309
+ LIBFLIPRO_API FPROSensor_SetScanDirection(int32_t iHandle, bool bHInverted, bool bVInverted);
3310
+
3311
+ //////////////////////////////////////////
3312
+ ///
3313
+ /// @brief Enables/Disables sensor re-training.
3314
+ ///
3315
+ ///
3316
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3317
+ /// @param bEnable - true: Forces sensor to undergo training. False - stops the sensor training.
3318
+ ///
3319
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3320
+ LIBFLIPRO_API FPROSensor_SetTrainingEnable(int32_t iHandle, bool bEnable);
3321
+
3322
+
3323
+ //////////////////////////////////////////
3324
+ // Auxiliary I/O Support Functions
3325
+ //////////////////////////////////////////
3326
+ //////////////////////////////////////////
3327
+ ///
3328
+ /// @brief Gets the direction and state for given Auxiliary I/O pin.
3329
+ ///
3330
+ /// For Output pins, the state of the pin will be the value last set with the
3331
+ /// #FPROAuxIO_GetPin() call. For Input pins, the state of the pin reflects the
3332
+ /// state of the physical input signal.
3333
+ ///
3334
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3335
+ /// @param eAuxIO - Auxiliary I/O pin to retrieve.
3336
+ /// @param pDirection - Pin direction.
3337
+ /// @param pState - Pin state. May be NULL if you do not want the state.
3338
+ ///
3339
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3340
+ LIBFLIPRO_API FPROAuxIO_GetPin(int32_t iHandle, FPROAUXIO eAuxIO, FPROAUXIO_DIR *pDirection, FPROAUXIO_STATE *pState);
3341
+
3342
+ //////////////////////////////////////////
3343
+ ///
3344
+ /// @brief Get the Exposure Active Signal Polarity.
3345
+ ///
3346
+ /// This function gets the Exposure Active Signal polarity for the
3347
+ /// Exposure Type Auxiliary output pin. See #FPROAuxIO_SetExposureActiveType for
3348
+ /// additional information.
3349
+ /// Consult your documentation for signal timing details.
3350
+ ///
3351
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3352
+ /// @param eType - Exposure Active Polarity: true= Active High, false= Active Low.
3353
+ ///
3354
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3355
+ LIBFLIPRO_API FPROAuxIO_GetExposureActivePolarity(int32_t iHandle, bool *pActiveHigh);
3356
+
3357
+ //////////////////////////////////////////
3358
+ ///
3359
+ /// @brief Get Exposure Active Type Signal.
3360
+ ///
3361
+ /// This function gets the Exposure Type Signal for the Exposure Type Auxiliary
3362
+ /// output pin. Consult your documentation for signal timing details.
3363
+ ///
3364
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3365
+ /// @param pType - Exposure Active Signal Type.
3366
+ ///
3367
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3368
+ LIBFLIPRO_API FPROAuxIO_GetExposureActiveType(int32_t iHandle, FPROAUXIO_EXPACTIVETYPE *pType);
3369
+
3370
+ //////////////////////////////////////////
3371
+ ///
3372
+ /// @brief Sets the direction and state for given Auxiliary I/O pin.
3373
+ ///
3374
+ /// Note that the state is only applicable to output pins. It is ignored
3375
+ /// for input pins.
3376
+ ///
3377
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3378
+ /// @param eAuxIO - Auxiliary I/O pin to configure.
3379
+ /// @param eDirection - Pin direction to set.
3380
+ /// @param eState - Pin state to set for output pins.
3381
+ ///
3382
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3383
+ LIBFLIPRO_API FPROAuxIO_SetPin(int32_t iHandle, FPROAUXIO eAuxIO, FPROAUXIO_DIR eDirection, FPROAUXIO_STATE eState);
3384
+
3385
+ //////////////////////////////////////////
3386
+ ///
3387
+ /// @brief Exposure Active Signal Polarity.
3388
+ ///
3389
+ /// This function sets the Exposure Active Signal polarity for the
3390
+ /// Exposure Type Auxiliary output pin. See #FPROAuxIO_SetExposureActiveType for
3391
+ /// additional information.
3392
+ /// Consult your documentation for signal timing details.
3393
+ ///
3394
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3395
+ /// @param eType - Exposure Active Polarity: true= Active High, false= Active Low.
3396
+ ///
3397
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3398
+ LIBFLIPRO_API FPROAuxIO_SetExposureActivePolarity(int32_t iHandle, bool bActiveHigh);
3399
+
3400
+ //////////////////////////////////////////
3401
+ ///
3402
+ /// @brief Exposure Active Type Signal.
3403
+ ///
3404
+ /// This function sets the Exposure Type Signal for the Exposure Type Auxiliary
3405
+ /// output pin. Consult your documentation for signal timing details.
3406
+ ///
3407
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3408
+ /// @param eType - Exposure Active Signal Type.
3409
+ ///
3410
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3411
+ LIBFLIPRO_API FPROAuxIO_SetExposureActiveType(int32_t iHandle, FPROAUXIO_EXPACTIVETYPE eType);
3412
+
3413
+
3414
+ //////////////////////////////////////////
3415
+ // Frame Acknowledgment Mode Support Functions
3416
+ //////////////////////////////////////////
3417
+ //////////////////////////////////////////
3418
+ ///
3419
+ /// @brief Get Frame Acknowledgment Mode Enable.
3420
+ ///
3421
+ /// This function gets the Frame Acknowledgment Mode Enable. If true, Frame
3422
+ /// Acknowledgment Mode is enabled.
3423
+ /// <br>
3424
+ /// Frame Acknowledgment Mode is a camera mode that instructs the camera to store
3425
+ /// each frame as it is exposed in an internal memory. The frame in the memory
3426
+ /// may be retransmitted to the host using the #FPROFAck_FrameResend() API. Each frame -must- be
3427
+ /// explicitly acknowledged by the user using the #FPROFAck_FrameAcknowledge() API. This allows
3428
+ /// the camera to delete the frame from its memory queue making it available for the next frame.
3429
+ /// <br>
3430
+ /// This mode is intended for users who require every image to be successfully transmitted to the host
3431
+ /// even in the face of cable and unrecoverable transmission errors. Because of the required acknowledgments,
3432
+ /// this mode is significantly slower with respect to achievable frame rate and dependent on the host computer.
3433
+ ///
3434
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3435
+ /// @param pEnable - The Frame Acknowledgment Mode enable- true if enabled, false otherwise.
3436
+ ///
3437
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3438
+ LIBFLIPRO_API FPROFAck_GetEnable(int32_t iHandle, bool *pEnable);
3439
+
3440
+ //////////////////////////////////////////
3441
+ ///
3442
+ /// @brief Set Frame Acknowledgment Mode Enable.
3443
+ ///
3444
+ /// This function sets the Frame Acknowledgment Mode Enable. If true, Frame
3445
+ /// Acknowledgment Mode is enabled. See #FPROFAck_GetEnable() for a description
3446
+ /// of this mode.
3447
+ ///
3448
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3449
+ /// @param bEnable - The Frame Acknowledgment Mode enable- True if enabled, False otherwise.
3450
+ ///
3451
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3452
+ LIBFLIPRO_API FPROFAck_SetEnable(int32_t iHandle, bool bEnable);
3453
+
3454
+ //////////////////////////////////////////
3455
+ ///
3456
+ /// @brief Acknowledge the last frame sent in Frame Acknowledgment Mode.
3457
+ ///
3458
+ /// This function acknowledges the last from sent to the host.
3459
+ /// See #FPROFAck_GetEnable() for a description of this mode.
3460
+ ///
3461
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3462
+ ///
3463
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3464
+ LIBFLIPRO_API FPROFAck_FrameAcknowledge(int32_t iHandle);
3465
+
3466
+
3467
+ //////////////////////////////////////////
3468
+ ///
3469
+ /// @brief Re-send the last frame in Frame Acknowledgment Mode.
3470
+ ///
3471
+ /// This function instructs the camera to re-send the last image frame to the
3472
+ /// host. Is expected to be called by an application in the event of transmission
3473
+ /// errors or errors detected during parsing of the image data.
3474
+ /// See #FPROFAck_GetEnable() for a description of this mode.
3475
+ /// <br>
3476
+ /// The frame data will be available immediately after this call so it is important
3477
+ /// to call #FPROFrame_GetVideoFrame() with the proper parameters immediately after this call
3478
+ /// returns.
3479
+ ///
3480
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3481
+ ///
3482
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3483
+ LIBFLIPRO_API FPROFAck_FrameResend(int32_t iHandle);
3484
+
3485
+ //////////////////////////////////////////
3486
+ ///
3487
+ /// @brief Flush the in memory frame queue in Frame Acknowledgment Mode.
3488
+ ///
3489
+ /// This function instructs the camera to flush all of the image frames contained
3490
+ /// in its internal image frame queue.
3491
+ /// See #FPROFAck_GetEnable() for a description of this mode.
3492
+ /// <br>
3493
+ ///
3494
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3495
+ ///
3496
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3497
+ LIBFLIPRO_API FPROFAck_FlushImageQueue(int32_t iHandle);
3498
+
3499
+ //////////////////////////////////////////
3500
+ /// Merge algorithm related functions including
3501
+ /// Image Stacking
3502
+ //////////////////////////////////////////
3503
+ //////////////////////////////////////////
3504
+ ///
3505
+ /// @brief Initialize the stacking process
3506
+ ///
3507
+ /// This function initializes the stacking process. It allocates memory based on the given
3508
+ /// size and the current imaging parameters on the camera. You must not change any camera
3509
+ /// parameters after making this call and completing the stacking process.
3510
+ /// This process, when complete, produces
3511
+ /// a high and low gain mean image from a stack of images. The result is suitable for merging
3512
+ /// images both by software or hardware when using the FLI PCIE Fibre connection.
3513
+ /// <br>
3514
+ ///
3515
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3516
+ ///
3517
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3518
+ LIBFLIPRO_API FPROAlgo_StackInitialize(int32_t iHandle);
3519
+
3520
+ //////////////////////////////////////////
3521
+ ///
3522
+ /// @brief Capture and retrieve the next frame to stack from the camera.
3523
+ ///
3524
+ /// This function retrieves and applies the next frame to the stack computations.
3525
+ /// It is expected that you have already called #FPROFrame_CaptureStart() to trigger the
3526
+ /// frame capture on the camera.
3527
+ /// <br>
3528
+ ///
3529
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3530
+ /// @param pFrameData - The buffer to store the original frame data that was stacked.
3531
+ /// @param pSize - Size the of the pFrameData buffer.
3532
+ /// On return, the number of bytes actually received.
3533
+ /// @param uiTimeoutMS - How long to wait for a frame to be available.
3534
+ /// Assuming you make this call very soon after the FPROFrame_CaptureStart()
3535
+ /// call, you should set this to the exposure time. Internally, the API
3536
+ /// blocks (i.e. no communication with the camera) for some time less than
3537
+ /// uiTimeoutMS and then attempts to retrieve the frame.
3538
+ ///
3539
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3540
+ LIBFLIPRO_API FPROAlgo_StackNextFrame(int32_t iHandle, uint8_t* pFrameData, uint32_t* pSize, uint32_t uiTimeoutMS);
3541
+
3542
+ //////////////////////////////////////////
3543
+ ///
3544
+ /// @brief Finish the stacking process and retrieve the mean frames.
3545
+ ///
3546
+ /// This function retrieves finalizes the stack computations and returns the mean frames.
3547
+ /// Assuming you make no changes to the camera settings, after this call a new stack can
3548
+ /// be started by simply starting a new a sequence of #FPROAlgo_StackNextFrame() calls.
3549
+ /// Any time you want to change camera settings, or you are done with the stacking process,
3550
+ /// you must call FPROAlgo_StackDeinitialize() to free the memory allocated during the
3551
+ /// stacking process.
3552
+ /// <br>
3553
+ /// <br>
3554
+ /// NOTE: The returned buffer pointers are allocated by the API and must be free by calling
3555
+ /// the FPROAlgo_StackDeinitialize() function when you are finished with the stacking process.
3556
+ /// If you run multiple stacking procedures between FPROAlgo_Stacknitialize() and
3557
+ /// FPROAlgo_StackDeinitialize(), the API reuses these buffers, so make sure to save
3558
+ /// them if you need to prior to making subsequent #FPROAlgo_StackNextFrame() calls.
3559
+ /// <br>
3560
+ /// The Image frames include the mean data only, no meta data.
3561
+ ///
3562
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3563
+ /// @param ppLowMeanFrame - Buffer pointer for Low Mean Frame.
3564
+ /// @param ppHighMeanFrame - Buffer pointer for High Mean Frame.
3565
+ /// @param pNumPixels - Buffer to return the number of pixels in each frame.
3566
+ /// @param ppMetaData - Buffer pointer for returned meta data (may be NULL).
3567
+ /// @param puiMetaSize - Pointer for returned size of meta data (may be NULL).
3568
+ ///
3569
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3570
+ LIBFLIPRO_API FPROAlgo_StackFinish(int32_t iHandle, uint16_t **ppLowMeanFrame, uint16_t **ppHighMeanFrame, uint32_t* pNumPixels, uint8_t** ppMetaData, uint32_t* puiMetaSize);
3571
+
3572
+ //////////////////////////////////////////
3573
+ ///
3574
+ /// @brief Returns all the resources allocated during the stacking process to the system.
3575
+ ///
3576
+ /// This function must be called when you are done with the stacking process to return
3577
+ /// all of the resources allocated during the process to the system. This includes the
3578
+ /// buffers returned by #FPROAlgo_StackFinish() so make sure you have saved the buffers
3579
+ /// if you need to prior to calling this function.
3580
+ /// <br>
3581
+ ///
3582
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3583
+ ///
3584
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3585
+ LIBFLIPRO_API FPROAlgo_StackDeinitialize(int32_t iHandle);
3586
+
3587
+ //////////////////////////////////////////
3588
+ ///
3589
+ /// @brief Sets the reference frames used in PCIE Fibre hardware image merging.
3590
+ ///
3591
+ /// See #FPRO_REFFRAMES for a description on how to use this function.
3592
+ /// <br>
3593
+ /// <br>
3594
+ /// The examples code also provides guidance for building this structure from
3595
+ /// your reference images. See the StreamingAndHWMerge example for further information.
3596
+ /// <br>
3597
+ ///
3598
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3599
+ /// @param pRefFrames - Pointer to the reference frames to use.
3600
+ ///
3601
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3602
+ LIBFLIPRO_API FPROAlgo_SetHardwareMergeReferenceFrames(int32_t iHandle, FPRO_REFFRAMES* pRefFrames);
3603
+
3604
+ //////////////////////////////////////////
3605
+ ///
3606
+ /// @brief Sets the reference frames used in PCIE Fibre hardware image merging.
3607
+ ///
3608
+ /// This function is analogous to the #FPROAlgo_SetHardwareMergeReferenceFrames API.
3609
+ /// It expects RCD Files as generated by the FLI Pilot application rather than the raw
3610
+ /// reference frame data. It builds the FPRO_REFFRAMES structure from the file data and
3611
+ /// sets the reference frames as if #FPROAlgo_SetHardwareMergeReferenceFrames was called.
3612
+ /// You need only call this API or #FPROAlgo_SetHardwareMergeReferenceFrames, you do not need
3613
+ /// to call both. This API is provided as a built in convenience when using the FLI Pilot
3614
+ /// application to generate the reference data files.
3615
+ /// <br>
3616
+ /// <br>
3617
+ /// At least one of the parameters must point to a valid file name; the other file name may be NULL.
3618
+ /// Passing a NULL pointer for a file name will generate identity reference data for the frame: Zeros (0)
3619
+ /// for the DSNU frames and ones (1) for the PRNU frames.
3620
+ /// <br>
3621
+ /// <br>
3622
+ /// See #FPRO_REFFRAMES for further information.
3623
+ ///
3624
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3625
+ /// @param pDSNUFile - Pointer to the DSNU File.
3626
+ /// @param pPRNUFile - Pointer to the PRNU File.
3627
+ ///
3628
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3629
+ LIBFLIPRO_API FPROAlgo_SetHardwareMergeReferenceFiles(int32_t iHandle, const wchar_t *pDSNUFile, const wchar_t *pPRNUFile);
3630
+
3631
+ //////////////////////////////////////////
3632
+ ///
3633
+ /// @brief Retrieve the current Hardware Merge Threshold values.
3634
+ ///
3635
+ /// Note this functionality only exists on Host PCIE Fibre connections version 2 or later.
3636
+ /// If you use hardware merging, you must call this API prior to calling #FPROFrame_ComputeFrameSize().
3637
+ /// <br>
3638
+ ///
3639
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3640
+ /// @param pHighGainThreshold - The returned high gain pixel value threshold. See #FPROAlgo_SetHardwareMergeThresholds for a description.
3641
+ /// @param pMergeDifferenceThreshold - The returned merge difference threshold. See #FPROAlgo_SetHardwareMergeThresholds for a description.
3642
+ ///
3643
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3644
+ LIBFLIPRO_API FPROAlgo_GetHardwareMergeThresholds(int32_t iHandle, uint16_t *pHighGainThreshold, uint16_t*pMergeDifferenceThreshold);
3645
+
3646
+ //////////////////////////////////////////
3647
+ ///
3648
+ /// @brief Retrieve the current Hardware Merge Threshold values.
3649
+ ///
3650
+ /// Note this functionality only exists on Host PCIE Fibre connections version 2 or later.
3651
+ /// If you use hardware merging, you must call this API prior to calling #FPROFrame_ComputeFrameSize().
3652
+ /// <br>
3653
+ ///
3654
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3655
+ /// @param uiHighGainThreshold - The high gain pixel value threshold (when over, the Low gain pixel is used).
3656
+ /// @param uiMergeDifferenceThreshold - When the High gain pixel value if below the High Gain Threshold, the Low
3657
+ /// pixel is used only if the difference between the is greater than the Merge
3658
+ /// Difference Threshold ((low - high) > merge_difference).
3659
+ ///
3660
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3661
+ LIBFLIPRO_API FPROAlgo_SetHardwareMergeThresholds(int32_t iHandle, uint16_t uiHighGainThreshold, uint16_t uiMergeDifferenceThreshold);
3662
+
3663
+ //////////////////////////////////////////
3664
+ ///
3665
+ /// @brief Retrieve the hardware merge enable settings.
3666
+ ///
3667
+ /// Note this functionality only exists on Host PCIE Fibre connections version 2 or later.
3668
+ /// See #FPROAlgo_SetHardwareMergeEnables().
3669
+ /// <br>
3670
+ ///
3671
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3672
+ /// @param pMergeEnables - The enables for various options. See #FPRO_HWMERGEENABLE for more information.
3673
+ ///
3674
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3675
+ LIBFLIPRO_API FPROAlgo_GetHardwareMergeEnables(int32_t iHandle, FPRO_HWMERGEENABLE *pMergeEnables);
3676
+
3677
+
3678
+ //////////////////////////////////////////
3679
+ ///
3680
+ /// @brief Enable/disable hardware merging options.
3681
+ ///
3682
+ /// Note this functionality only exists on Host PCIE Fibre connections version 2 or later.
3683
+ /// If you use hardware merging, you must call this API prior to calling #FPROFrame_ComputeFrameSize().
3684
+ /// <br>
3685
+ ///
3686
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3687
+ /// @param mergeEnables - The enables for various options. See #FPRO_HWMERGEENABLE for more information.
3688
+ ///
3689
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3690
+ LIBFLIPRO_API FPROAlgo_SetHardwareMergeEnables(int32_t iHandle, FPRO_HWMERGEENABLE mergeEnables);
3691
+
3692
+
3693
+ /// @cond DO_NOT_DOCUMRNT
3694
+ LIBFLIPRO_API FPROAlgo_MergeRcdToFits(wchar_t *pRCDFileName, wchar_t *pDSNURef, wchar_t *pPRNURef);
3695
+ /// @endcond
3696
+
3697
+ //////////////////////////////////////////
3698
+ // NV Storage Functions
3699
+ //////////////////////////////////////////
3700
+ //////////////////////////////////////////
3701
+ ///
3702
+ /// @brief Write the given data to the non volatile storage area on the camera.
3703
+ ///
3704
+ /// This function simply writes the given data to the non volatile storage area on
3705
+ /// the camera. This API allows users to keep proprietary settings
3706
+ /// linked with a given camera. No structure is imposed on the data by this API nor the camera.
3707
+ /// That is, the data is simply treated as a byte stream. It is up to the user to format the
3708
+ /// data as required for their application.
3709
+ /// <br>
3710
+ /// Note that not all cameras may support a non-volatile memory area. You can determine if
3711
+ /// it is available and the size by reading the capabilities of the camera using the
3712
+ /// #FPROSensor_GetCapabilities API. The uiNVStorageAvailable field in this structure contains
3713
+ /// the size in bytes of the NV storage area.
3714
+ ///
3715
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3716
+ /// @param uiOffset - The offset within the NV area to begin the write.
3717
+ /// @param pData - The data to write.
3718
+ /// @param uiLength - The number of bytes to write.
3719
+ ///
3720
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3721
+ LIBFLIPRO_API FPRONV_WriteNVStorage(int32_t iHandle,uint32_t uiOffset, uint8_t *pData, uint32_t uiLength);
3722
+
3723
+ //////////////////////////////////////////
3724
+ ///
3725
+ /// @brief Read the non volatile storage area on the camera.
3726
+ ///
3727
+ /// This function simply reads the non volatile storage area on
3728
+ /// the camera and returns it in the provided buffer. See # FPRONV_WriteNVStorage
3729
+ /// for more information.
3730
+ ///
3731
+ /// @param iHandle - The handle to an open camera device returned from FPROCam_Open()
3732
+ /// @param uiOffset - The offset within the NV area to begin the read.
3733
+ /// @param pData - The buffer for the data.
3734
+ /// @param uiLength - The number of bytes to read.
3735
+ ///
3736
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3737
+ LIBFLIPRO_API FPRONV_ReadNVStorage(int32_t iHandle, uint32_t uiOffset, uint8_t *pData, uint32_t uiLength);
3738
+
3739
+ //////////////////////////////////////////
3740
+ // Low level commands and functions
3741
+ //////////////////////////////////////////
3742
+ /// @private
3743
+ LIBFLIPRO_API FPROCmd_SendRaw(int32_t iHandle, uint8_t *pData, uint32_t uiLength);
3744
+ /// @private
3745
+ LIBFLIPRO_API FPROCmd_SendRecvRaw(int32_t iHandle, uint8_t *pTxData, uint32_t uiTxLength, uint8_t *pRxData, uint32_t *pRxLength);
3746
+ /// @private
3747
+ LIBFLIPRO_API FPROCmd_ReadReg(int32_t iHandle, uint32_t uiReg, uint32_t *pValue);
3748
+ /// @private
3749
+ LIBFLIPRO_API FPROCmd_WriteReg(int32_t iHandle, uint32_t uiReg, uint32_t uiValue, uint32_t uiMask);
3750
+ /// @private
3751
+ LIBFLIPRO_API FPROCmd_PCIEReadReg(int32_t iHandle, uint32_t uiReg, uint32_t* pValue);
3752
+ /// @private
3753
+ LIBFLIPRO_API FPROCmd_PCIEWriteReg(int32_t iHandle, uint32_t uiReg, uint32_t uiValue);
3754
+
3755
+ // Debug Functions
3756
+ /// @cond DO_NOT_DOCUMENT
3757
+ // Conversion strings to aid in debug printing
3758
+ // The Linux part is different because of the way
3759
+ // swprintf() works- when %s is used, the argument is
3760
+ // assumed to be a char pointer. Hence we do not make it wide.
3761
+ #if defined(WIN32) || defined(_WINDOWS)
3762
+ #define STRINGIFY(x) L##x
3763
+ #define MAKEWIDE(x) STRINGIFY(x)
3764
+ #else
3765
+ #define MAKEWIDE(x) (x)
3766
+ #endif
3767
+ /// @endcond
3768
+
3769
+ //////////////////////////////////////////
3770
+ ///
3771
+ /// Enables the given debug level and above.
3772
+ ///
3773
+ /// @param bEnable - Overall enable for debug output
3774
+ /// @param eLevel - The level to enable if bEnable is true;
3775
+ ///
3776
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3777
+ LIBFLIPRO_API FPRODebug_EnableLevel(bool bEnable, FPRODBGLEVEL eLevel);
3778
+ //////////////////////////////////////////
3779
+ ///
3780
+ /// Sets the log file path to the given folder. The file name is auto generated.
3781
+ ///
3782
+ /// @param pPath - Path (folder) in which to place the log file.
3783
+ ///
3784
+ /// @return Greater than or equal to 0 on success, less than 0 on failure.
3785
+ LIBFLIPRO_API FPRODebug_SetLogPath(const wchar_t *pPath);
3786
+ #ifdef WIN32
3787
+ //////////////////////////////////////////
3788
+ ///
3789
+ /// Writes the given information to the log file if the given level is enabled.
3790
+ /// <br>The parameters support the basic printf type of formatting.
3791
+ ///
3792
+ /// @param eLevel - Debug level of the log message.
3793
+ /// @param format - printf style formatting string
3794
+ /// @param ... - printf arguments for the format string
3795
+ ///
3796
+ /// @return None.
3797
+ LIBFLIPRO_VOID _cdecl FPRODebug_Write(FPRODBGLEVEL eLevel, const wchar_t *format, ...);
3798
+ #else
3799
+ //////////////////////////////////////////
3800
+ /// FPRODebug_Write
3801
+ /// Writes the given information to the log file if the given level is enabled.
3802
+ /// <br>The parameters support the basic printf type of formatting.
3803
+ ///
3804
+ /// @param eLevel - Debug level of the log message.
3805
+ /// @param format - printf style formatting string
3806
+ /// @param ... - printf arguments for the format string
3807
+ ///
3808
+ /// @return None.
3809
+ LIBFLIPRO_VOID FPRODebug_Write(FPRODBGLEVEL eLevel, const wchar_t *format, ...);
3810
+ #endif
3811
+
3812
+
3813
+
3814
+
3815
+ #endif // _LIBFLIPRO_H_
3816
+
3817
+ #ifdef __cplusplus
3818
+ }
3819
+
3820
+ #endif