-
Notifications
You must be signed in to change notification settings - Fork 0
/
xiApiPlusOcv.hpp
2102 lines (1544 loc) · 80.6 KB
/
xiApiPlusOcv.hpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
//-------------------------------------------------------------------------------------------------------------------
// xiAPIplus header file - created from gen_xiAPIplus_h_file.xslt
// XIMEA Application Programming Interface Object Oriented Approach
//-------------------------------------------------------------------------------------------------------------------
#pragma once
//#ifdef WIN32
//#ifdef WIN32
#include <xiApi.h>
//#else
//#include <m3api/xiApi.h> // Linux, OSX
//#endif // Windows
//#else
//#include <m3api/xiApi.h> // Linux, OSX
//#endif
#include <stdio.h>
#include <opencv2/core.hpp>
#include <opencv2/highgui/highgui.hpp>
#include <stdint.h>
#include <vector>
// debug support
#define DBFIN "xAPIp:"
#define DBFOUT "res: "
#define xiAPIPlusDP(x) {if (is_debug_enabled) {printf x;}}
#define CheckCamHandle(place) {xiAPIPlusDP((DBFIN "%s ... ",place));if (!camera_handle) CheckResult(XI_INVALID_HANDLE, place);}
#define CheckCamHandleInt(place,i) {xiAPIPlusDP((DBFIN "%s(%d) ... ",place,i));if (!camera_handle) CheckResult(XI_INVALID_HANDLE, place);}
// forward declarations
void ReportException(XI_RETURN res, const char* location);
// -----------------------------------------------
// xiAPIplus
// -----------------------------------------------
class xiAPIplus
{
public:
unsigned long GetNumberOfConnectedCameras();
};
class xiAPIplus_Exception
{
public:
xiAPIplus_Exception(XI_RETURN code, char* desc)
{
description = desc;
error_code = code;
}
XI_RETURN GetErrorNumber() {return error_code;}
void GetDescription(char* name, size_t name_max_size);
void PrintError();
private:
char* description;
XI_RETURN error_code;
};
// -----------------------------------------------
// general parametes interface
// working with set of parameters
// -----------------------------------------------
class xiAPIplus_Camera_Parameters
{
public:
void Save_to_File(char* filename);
void Load_from_File(char* filename);
void Save_to_Preset(int id);
void Load_from_Preset(int id);
int Get_Count();
void Get_Name(int id, char* name, size_t name_max_size);
void Get_Value(int id, char* value, size_t value_max_size);
void Set_Value(int id, char* value);
private:
};
// -----------------------------------------------
// class xiAPIplus - Image
// -----------------------------------------------
class xiAPIplus_Image
{
public:
xiAPIplus_Image();
virtual ~xiAPIplus_Image();
// functions
XI_IMG_FORMAT GetDataFormat() {return image.frm;}
unsigned char* GetPixels() {return (unsigned char*)image.bp;}
float* GetPixelsFloat() { return (float*)image.bp; }
int GetWidth() {return image.width;}
int GetHeight() {return image.height;}
int GetPadding_X();
XI_IMG* GetXI_IMG();
int GetBytesPerPixel();
int GetFrameNumber(){ return image.nframe;};
int GetPixelsArraySize() {return ((image.width + GetPadding_X()) * image.height * GetBytesPerPixel());}
int GetBitCount();
virtual void CopyTo(xiAPIplus_Image* image_copy);
bool IsCopy() {return is_copy;}
void SetCopy(bool en) {is_copy=en;}
private:
XI_IMG image;
bool is_copy; // =1 if image bitmap is allocated, 0= if it is area in memory, that is not allocated in API
};
// -----------------------------------------------
// class xiAPIplus - Camera
// -----------------------------------------------
class xiAPIplus_Camera
{
public:
xiAPIplus_Camera();
~xiAPIplus_Camera();
// API
unsigned long GetNumberOfConnectedCameras();
// open/close
void OpenFirst();
void OpenByID(const unsigned long id);
void OpenBySN(const char* serial_number);
void OpenByPath(const char* device_path);
void OpenByUserID(const char* user_id);
void OpenByLocation(const char* location);
void Close();
// debug
void EnableDebug() {is_debug_enabled=true;}
void DisableDebug() {is_debug_enabled=false;}
bool IsDebugEnabled() {return is_debug_enabled;}
// acquisition
void StartAcquisition();
void StopAcquisition();
bool IsAcquisitionActive();
// image
void SetNextImageTimeout_ms(int timeout_ms);
int GetNextImageTimeout_ms();
xiAPIplus_Image* GetNextImage(xiAPIplus_Image* app_image);
xiAPIplus_Image* GetLastImage();
HANDLE GetCameraHandle() {return camera_handle;}
void SetCameraHandle(HANDLE handle) {camera_handle = handle;}
// parameters
xiAPIplus_Camera_Parameters* GetParameters() {return ¶meters;}
void GetXIAPIParamString(char* xiapi_param_name, char* value, int value_max_size);
void SetXIAPIParamString(char* xiapi_param_name, char* value, unsigned int value_size);
void GetXIAPIParamInt(char* xiapi_param_name, int* value);
void SetXIAPIParamInt(char* xiapi_param_name, int value);
void GetXIAPIParamFloat(char* xiapi_param_name, float* value);
void SetXIAPIParamFloat(char* xiapi_param_name, float value);
void GetXIAPIParam(char* xiapi_param_name, void* value, size_t * value_size, XI_PRM_TYPE * type);
void SetXIAPIParam(char* xiapi_param_name, void* value, size_t value_size, XI_PRM_TYPE type);
//-------------------------------------------------------------------------------------------------------------------
// xiApi parameters
//-------------------------------------------------------------------------------------------------------------------
// ---- Parameter Group: Basic
//-------------------------------------------------------------------------------------------------------------------
// Exposure time in microseconds (XI_PRM_EXPOSURE)
float GetExposureTime();
float GetExposureTime_Maximum();
float GetExposureTime_Minimum();
float GetExposureTime_Increment();
void SetExposureTime(float ExposureTime);
// Selector for Exposure parameter (XI_PRM_EXPOSURE_TIME_SELECTOR)
XI_EXPOSURE_TIME_SELECTOR_TYPE GetExposureTimeSelector();
XI_EXPOSURE_TIME_SELECTOR_TYPE GetExposureTimeSelector_Maximum();
XI_EXPOSURE_TIME_SELECTOR_TYPE GetExposureTimeSelector_Minimum();
int GetExposureTimeSelector_Increment();
void SetExposureTimeSelector(XI_EXPOSURE_TIME_SELECTOR_TYPE ExposureTimeSelector);
// Sets the number of times of exposure in one frame. (XI_PRM_EXPOSURE_BURST_COUNT)
int GetExposureBurstCount();
int GetExposureBurstCount_Maximum();
int GetExposureBurstCount_Minimum();
int GetExposureBurstCount_Increment();
void SetExposureBurstCount(int ExposureBurstCount);
// Gain selector for parameter Gain allows to select different type of gains. (XI_PRM_GAIN_SELECTOR)
XI_GAIN_SELECTOR_TYPE GetGainSelector();
XI_GAIN_SELECTOR_TYPE GetGainSelector_Maximum();
XI_GAIN_SELECTOR_TYPE GetGainSelector_Minimum();
int GetGainSelector_Increment();
void SetGainSelector(XI_GAIN_SELECTOR_TYPE GainSelector);
// Gain in dB (XI_PRM_GAIN)
float GetGain();
float GetGain_Maximum();
float GetGain_Minimum();
float GetGain_Increment();
void SetGain(float Gain);
// Change image resolution by binning or skipping. (XI_PRM_DOWNSAMPLING)
XI_DOWNSAMPLING_VALUE GetDownsampling();
XI_DOWNSAMPLING_VALUE GetDownsampling_Maximum();
XI_DOWNSAMPLING_VALUE GetDownsampling_Minimum();
int GetDownsampling_Increment();
void SetDownsampling(XI_DOWNSAMPLING_VALUE Downsampling);
// Change image downsampling type. (XI_PRM_DOWNSAMPLING_TYPE)
XI_DOWNSAMPLING_TYPE GetDownsamplingType();
XI_DOWNSAMPLING_TYPE GetDownsamplingType_Maximum();
XI_DOWNSAMPLING_TYPE GetDownsamplingType_Minimum();
int GetDownsamplingType_Increment();
void SetDownsamplingType(XI_DOWNSAMPLING_TYPE DownsamplingType);
// Selects which test pattern generator is controlled by the test pattern feature. (XI_PRM_TEST_PATTERN_GENERATOR_SELECTOR)
XI_TEST_PATTERN_GENERATOR GetTestPatternGeneratorSelector();
XI_TEST_PATTERN_GENERATOR GetTestPatternGeneratorSelector_Maximum();
XI_TEST_PATTERN_GENERATOR GetTestPatternGeneratorSelector_Minimum();
int GetTestPatternGeneratorSelector_Increment();
void SetTestPatternGeneratorSelector(XI_TEST_PATTERN_GENERATOR TestPatternGeneratorSelector);
// Selects which test pattern type is generated by the selected generator. (XI_PRM_TEST_PATTERN)
XI_TEST_PATTERN GetTestPattern();
XI_TEST_PATTERN GetTestPattern_Maximum();
XI_TEST_PATTERN GetTestPattern_Minimum();
int GetTestPattern_Increment();
void SetTestPattern(XI_TEST_PATTERN TestPattern);
// Output data format. (XI_PRM_IMAGE_DATA_FORMAT)
XI_IMG_FORMAT GetImageDataFormat();
XI_IMG_FORMAT GetImageDataFormat_Maximum();
XI_IMG_FORMAT GetImageDataFormat_Minimum();
int GetImageDataFormat_Increment();
void SetImageDataFormat(XI_IMG_FORMAT ImageDataFormat);
// Change sensor shutter type(CMOS sensor). (XI_PRM_SHUTTER_TYPE)
XI_SHUTTER_TYPE GetShutterType();
XI_SHUTTER_TYPE GetShutterType_Maximum();
XI_SHUTTER_TYPE GetShutterType_Minimum();
int GetShutterType_Increment();
void SetShutterType(XI_SHUTTER_TYPE ShutterType);
// Number of taps (XI_PRM_SENSOR_TAPS)
XI_SENSOR_TAP_CNT GetSensorTaps();
XI_SENSOR_TAP_CNT GetSensorTaps_Maximum();
XI_SENSOR_TAP_CNT GetSensorTaps_Minimum();
int GetSensorTaps_Increment();
void SetSensorTaps(XI_SENSOR_TAP_CNT SensorTaps);
// Automatic exposure/gain (XI_PRM_AEAG)
bool IsAutoExposureAutoGain();
void EnableAutoExposureAutoGain();
void DisableAutoExposureAutoGain();
// Automatic exposure/gain ROI offset X (XI_PRM_AEAG_ROI_OFFSET_X)
int GetAutoExposureAutoGainROIoffsetX();
int GetAutoExposureAutoGainROIoffsetX_Maximum();
int GetAutoExposureAutoGainROIoffsetX_Minimum();
int GetAutoExposureAutoGainROIoffsetX_Increment();
void SetAutoExposureAutoGainROIoffsetX(int AutoExposureAutoGainROIoffsetX);
// Automatic exposure/gain ROI offset Y (XI_PRM_AEAG_ROI_OFFSET_Y)
int GetAutoExposureAutoGainROIoffsetY();
int GetAutoExposureAutoGainROIoffsetY_Maximum();
int GetAutoExposureAutoGainROIoffsetY_Minimum();
int GetAutoExposureAutoGainROIoffsetY_Increment();
void SetAutoExposureAutoGainROIoffsetY(int AutoExposureAutoGainROIoffsetY);
// Automatic exposure/gain ROI Width (XI_PRM_AEAG_ROI_WIDTH)
int GetAutoExposureAutoGainROIWidth();
int GetAutoExposureAutoGainROIWidth_Maximum();
int GetAutoExposureAutoGainROIWidth_Minimum();
int GetAutoExposureAutoGainROIWidth_Increment();
void SetAutoExposureAutoGainROIWidth(int AutoExposureAutoGainROIWidth);
// Automatic exposure/gain ROI Height (XI_PRM_AEAG_ROI_HEIGHT)
int GetAutoExposureAutoGainROIHeight();
int GetAutoExposureAutoGainROIHeight_Maximum();
int GetAutoExposureAutoGainROIHeight_Minimum();
int GetAutoExposureAutoGainROIHeight_Increment();
void SetAutoExposureAutoGainROIHeight(int AutoExposureAutoGainROIHeight);
// Selector of list used by Sensor Defects Correction parameter (XI_PRM_SENS_DEFECTS_CORR_LIST_SELECTOR)
XI_SENS_DEFFECTS_CORR_LIST_SELECTOR GetSensorDefectsCorrectionListSelector();
XI_SENS_DEFFECTS_CORR_LIST_SELECTOR GetSensorDefectsCorrectionListSelector_Maximum();
XI_SENS_DEFFECTS_CORR_LIST_SELECTOR GetSensorDefectsCorrectionListSelector_Minimum();
int GetSensorDefectsCorrectionListSelector_Increment();
void SetSensorDefectsCorrectionListSelector(XI_SENS_DEFFECTS_CORR_LIST_SELECTOR SensorDefectsCorrectionListSelector);
// Sets/Gets sensor defects list in special text format (XI_PRM_SENS_DEFECTS_CORR_LIST_CONTENT)
void GetSensDefectsCorrListContent(char* buffer, int buffer_lenght);
void SetSensDefectsCorrListContent(char* SensDefectsCorrListContent);
// Correction of sensor defects (pixels, columns, rows) enable/disable (XI_PRM_SENS_DEFECTS_CORR)
bool IsSensorDefectsCorrection();
void EnableSensorDefectsCorrection();
void DisableSensorDefectsCorrection();
// Automatic white balance (XI_PRM_AUTO_WB)
bool IsWhiteBalanceAuto();
void EnableWhiteBalanceAuto();
void DisableWhiteBalanceAuto();
// Calculates White Balance(xiGetImage function must be called) (XI_PRM_MANUAL_WB)
void SetWhiteBalanceManualNow(int WhiteBalanceManualNow);
// White balance offset X (XI_PRM_WB_ROI_OFFSET_X)
int GetWhiteBalanceROIoffsetX();
int GetWhiteBalanceROIoffsetX_Maximum();
int GetWhiteBalanceROIoffsetX_Minimum();
int GetWhiteBalanceROIoffsetX_Increment();
void SetWhiteBalanceROIoffsetX(int WhiteBalanceROIoffsetX);
// White balance offset Y (XI_PRM_WB_ROI_OFFSET_Y)
int GetWhiteBalanceROIoffsetY();
int GetWhiteBalanceROIoffsetY_Maximum();
int GetWhiteBalanceROIoffsetY_Minimum();
int GetWhiteBalanceROIoffsetY_Increment();
void SetWhiteBalanceROIoffsetY(int WhiteBalanceROIoffsetY);
// White balance width (XI_PRM_WB_ROI_WIDTH)
int GetWhiteBalanceROIWidth();
int GetWhiteBalanceROIWidth_Maximum();
int GetWhiteBalanceROIWidth_Minimum();
int GetWhiteBalanceROIWidth_Increment();
void SetWhiteBalanceROIWidth(int WhiteBalanceROIWidth);
// White balance height (XI_PRM_WB_ROI_HEIGHT)
int GetWhiteBalanceROIHeight();
int GetWhiteBalanceROIHeight_Maximum();
int GetWhiteBalanceROIHeight_Minimum();
int GetWhiteBalanceROIHeight_Increment();
void SetWhiteBalanceROIHeight(int WhiteBalanceROIHeight);
// White balance red coefficient (XI_PRM_WB_KR)
float GetWhiteBalanceRed();
float GetWhiteBalanceRed_Maximum();
float GetWhiteBalanceRed_Minimum();
float GetWhiteBalanceRed_Increment();
void SetWhiteBalanceRed(float WhiteBalanceRed);
// White balance green coefficient (XI_PRM_WB_KG)
float GetWhiteBalanceGreen();
float GetWhiteBalanceGreen_Maximum();
float GetWhiteBalanceGreen_Minimum();
float GetWhiteBalanceGreen_Increment();
void SetWhiteBalanceGreen(float WhiteBalanceGreen);
// White balance blue coefficient (XI_PRM_WB_KB)
float GetWhiteBalanceBlue();
float GetWhiteBalanceBlue_Maximum();
float GetWhiteBalanceBlue_Minimum();
float GetWhiteBalanceBlue_Increment();
void SetWhiteBalanceBlue(float WhiteBalanceBlue);
// Width of the Image provided by the device (in pixels). (XI_PRM_WIDTH)
int GetWidth();
int GetWidth_Maximum();
int GetWidth_Minimum();
int GetWidth_Increment();
void SetWidth(int Width);
// Height of the Image provided by the device (in pixels). (XI_PRM_HEIGHT)
int GetHeight();
int GetHeight_Maximum();
int GetHeight_Minimum();
int GetHeight_Increment();
void SetHeight(int Height);
// Horizontal offset from the origin to the area of interest (in pixels). (XI_PRM_OFFSET_X)
int GetOffsetX();
int GetOffsetX_Maximum();
int GetOffsetX_Minimum();
int GetOffsetX_Increment();
void SetOffsetX(int OffsetX);
// Vertical offset from the origin to the area of interest (in pixels). (XI_PRM_OFFSET_Y)
int GetOffsetY();
int GetOffsetY_Maximum();
int GetOffsetY_Minimum();
int GetOffsetY_Increment();
void SetOffsetY(int OffsetY);
// Selects Region in Multiple ROI which parameters are set by width, height, ... ,region mode (XI_PRM_REGION_SELECTOR)
int GetRegion_selector();
int GetRegion_selector_Maximum();
int GetRegion_selector_Minimum();
int GetRegion_selector_Increment();
void SetRegion_selector(int Region_selector);
// Activates/deactivates Region selected by Region Selector (XI_PRM_REGION_MODE)
int GetRegion_mode();
int GetRegion_mode_Maximum();
int GetRegion_mode_Minimum();
int GetRegion_mode_Increment();
void SetRegion_mode(int Region_mode);
// Horizontal flip enable (XI_PRM_HORIZONTAL_FLIP)
bool IsHorizontalFlip();
void EnableHorizontalFlip();
void DisableHorizontalFlip();
// Vertical flip enable (XI_PRM_VERTICAL_FLIP)
bool IsVerticalFlip();
void EnableVerticalFlip();
void DisableVerticalFlip();
// Selector for Exposure parameter (XI_PRM_INTERLINE_EXPOSURE_MODE)
XI_INTERLINE_EXPOSURE_MODE_TYPE GetInterlineExposureMode();
XI_INTERLINE_EXPOSURE_MODE_TYPE GetInterlineExposureMode_Maximum();
XI_INTERLINE_EXPOSURE_MODE_TYPE GetInterlineExposureMode_Minimum();
int GetInterlineExposureMode_Increment();
void SetInterlineExposureMode(XI_INTERLINE_EXPOSURE_MODE_TYPE InterlineExposureMode);
// Image flat field correction (XI_PRM_FFC)
bool IsFlatFieldCorrection();
void EnableFlatFieldCorrection();
void DisableFlatFieldCorrection();
// Set name of file to be applied for FFC processor. (XI_PRM_FFC_FLAT_FIELD_FILE_NAME)
void GetFFCFlatFieldFileName(char* buffer, int buffer_lenght);
void SetFFCFlatFieldFileName(char* FFCFlatFieldFileName);
// Set name of file to be applied for FFC processor. (XI_PRM_FFC_DARK_FIELD_FILE_NAME)
void GetFFCDarkFieldFileName(char* buffer, int buffer_lenght);
void SetFFCDarkFieldFileName(char* FFCDarkFieldFileName);
//-------------------------------------------------------------------------------------------------------------------
// ---- Parameter Group: Image Format
//-------------------------------------------------------------------------------------------------------------------
// Binning engine selector. (XI_PRM_BINNING_SELECTOR)
XI_BIN_SELECTOR GetBinningSelector();
XI_BIN_SELECTOR GetBinningSelector_Maximum();
XI_BIN_SELECTOR GetBinningSelector_Minimum();
int GetBinningSelector_Increment();
void SetBinningSelector(XI_BIN_SELECTOR BinningSelector);
// Sets the mode to use to combine vertical pixel together. (XI_PRM_BINNING_VERTICAL_MODE)
XI_BIN_MODE GetBinningVerticalMode();
XI_BIN_MODE GetBinningVerticalMode_Maximum();
XI_BIN_MODE GetBinningVerticalMode_Minimum();
int GetBinningVerticalMode_Increment();
void SetBinningVerticalMode(XI_BIN_MODE BinningVerticalMode);
// Vertical Binning - number of vertical photo-sensitive cells to combine together. (XI_PRM_BINNING_VERTICAL)
int GetBinningVertical();
int GetBinningVertical_Maximum();
int GetBinningVertical_Minimum();
int GetBinningVertical_Increment();
void SetBinningVertical(int BinningVertical);
// Sets the mode to use to combine horizontal pixel together. (XI_PRM_BINNING_HORIZONTAL_MODE)
XI_BIN_MODE GetBinningHorizontalMode();
XI_BIN_MODE GetBinningHorizontalMode_Maximum();
XI_BIN_MODE GetBinningHorizontalMode_Minimum();
int GetBinningHorizontalMode_Increment();
void SetBinningHorizontalMode(XI_BIN_MODE BinningHorizontalMode);
// Horizontal Binning - number of horizontal photo-sensitive cells to combine together. (XI_PRM_BINNING_HORIZONTAL)
int GetBinningHorizontal();
int GetBinningHorizontal_Maximum();
int GetBinningHorizontal_Minimum();
int GetBinningHorizontal_Increment();
void SetBinningHorizontal(int BinningHorizontal);
// Binning horizontal pattern type. (XI_PRM_BINNING_HORIZONTAL_PATTERN)
XI_BIN_PATTERN GetBinningHorizontalPattern();
XI_BIN_PATTERN GetBinningHorizontalPattern_Maximum();
XI_BIN_PATTERN GetBinningHorizontalPattern_Minimum();
int GetBinningHorizontalPattern_Increment();
void SetBinningHorizontalPattern(XI_BIN_PATTERN BinningHorizontalPattern);
// Binning vertical pattern type. (XI_PRM_BINNING_VERTICAL_PATTERN)
XI_BIN_PATTERN GetBinningVerticalPattern();
XI_BIN_PATTERN GetBinningVerticalPattern_Maximum();
XI_BIN_PATTERN GetBinningVerticalPattern_Minimum();
int GetBinningVerticalPattern_Increment();
void SetBinningVerticalPattern(XI_BIN_PATTERN BinningVerticalPattern);
// Decimation engine selector. (XI_PRM_DECIMATION_SELECTOR)
XI_DEC_SELECTOR GetDecimationSelector();
XI_DEC_SELECTOR GetDecimationSelector_Maximum();
XI_DEC_SELECTOR GetDecimationSelector_Minimum();
int GetDecimationSelector_Increment();
void SetDecimationSelector(XI_DEC_SELECTOR DecimationSelector);
// Vertical Decimation - vertical sub-sampling of the image - reduces the vertical resolution of the image by the specified vertical decimation factor. (XI_PRM_DECIMATION_VERTICAL)
int GetDecimationVertical();
int GetDecimationVertical_Maximum();
int GetDecimationVertical_Minimum();
int GetDecimationVertical_Increment();
void SetDecimationVertical(int DecimationVertical);
// Horizontal Decimation - horizontal sub-sampling of the image - reduces the horizontal resolution of the image by the specified vertical decimation factor. (XI_PRM_DECIMATION_HORIZONTAL)
int GetDecimationHorizontal();
int GetDecimationHorizontal_Maximum();
int GetDecimationHorizontal_Minimum();
int GetDecimationHorizontal_Increment();
void SetDecimationHorizontal(int DecimationHorizontal);
// Decimation horizontal pattern type. (XI_PRM_DECIMATION_HORIZONTAL_PATTERN)
XI_DEC_PATTERN GetDecimationHorizontalPattern();
XI_DEC_PATTERN GetDecimationHorizontalPattern_Maximum();
XI_DEC_PATTERN GetDecimationHorizontalPattern_Minimum();
int GetDecimationHorizontalPattern_Increment();
void SetDecimationHorizontalPattern(XI_DEC_PATTERN DecimationHorizontalPattern);
// Decimation vertical pattern type. (XI_PRM_DECIMATION_VERTICAL_PATTERN)
XI_DEC_PATTERN GetDecimationVerticalPattern();
XI_DEC_PATTERN GetDecimationVerticalPattern_Maximum();
XI_DEC_PATTERN GetDecimationVerticalPattern_Minimum();
int GetDecimationVerticalPattern_Increment();
void SetDecimationVerticalPattern(XI_DEC_PATTERN DecimationVerticalPattern);
//-------------------------------------------------------------------------------------------------------------------
// ---- Parameter Group: AE Setup
//-------------------------------------------------------------------------------------------------------------------
// Exposure priority (0.8 - exposure 80%, gain 20%). (XI_PRM_EXP_PRIORITY)
float GetAutoExposureAutoGainExposurePriority();
float GetAutoExposureAutoGainExposurePriority_Maximum();
float GetAutoExposureAutoGainExposurePriority_Minimum();
float GetAutoExposureAutoGainExposurePriority_Increment();
void SetAutoExposureAutoGainExposurePriority(float AutoExposureAutoGainExposurePriority);
// Maximum limit of gain in AEAG procedure (XI_PRM_AG_MAX_LIMIT)
float GetAutoGainTopLimit();
float GetAutoGainTopLimit_Maximum();
float GetAutoGainTopLimit_Minimum();
float GetAutoGainTopLimit_Increment();
void SetAutoGainTopLimit(float AutoGainTopLimit);
// Maximum time (us) used for exposure in AEAG procedure (XI_PRM_AE_MAX_LIMIT)
int GetAutoExposureTopLimit();
int GetAutoExposureTopLimit_Maximum();
int GetAutoExposureTopLimit_Minimum();
int GetAutoExposureTopLimit_Increment();
void SetAutoExposureTopLimit(int AutoExposureTopLimit);
// Average intensity of output signal AEAG should achieve(in %) (XI_PRM_AEAG_LEVEL)
int GetAutoExposureAutoGainTargetLevel();
int GetAutoExposureAutoGainTargetLevel_Maximum();
int GetAutoExposureAutoGainTargetLevel_Minimum();
int GetAutoExposureAutoGainTargetLevel_Increment();
void SetAutoExposureAutoGainTargetLevel(int AutoExposureAutoGainTargetLevel);
//-------------------------------------------------------------------------------------------------------------------
// ---- Parameter Group: Performance
//-------------------------------------------------------------------------------------------------------------------
// Set/get bandwidth(data rate in Megabits) (XI_PRM_LIMIT_BANDWIDTH)
int GetBandwidthLimit();
int GetBandwidthLimit_Maximum();
int GetBandwidthLimit_Minimum();
int GetBandwidthLimit_Increment();
void SetBandwidthLimit(int BandwidthLimit);
// Bandwidth limit enabled (XI_PRM_LIMIT_BANDWIDTH_MODE)
XI_SWITCH GetBandwidthLimitMode();
XI_SWITCH GetBandwidthLimitMode_Maximum();
XI_SWITCH GetBandwidthLimitMode_Minimum();
int GetBandwidthLimitMode_Increment();
void SetBandwidthLimitMode(XI_SWITCH BandwidthLimitMode);
// Sensor output data bit depth. (XI_PRM_SENSOR_DATA_BIT_DEPTH)
XI_BIT_DEPTH GetSensorDataBitDepth();
XI_BIT_DEPTH GetSensorDataBitDepth_Maximum();
XI_BIT_DEPTH GetSensorDataBitDepth_Minimum();
int GetSensorDataBitDepth_Increment();
void SetSensorDataBitDepth(XI_BIT_DEPTH SensorDataBitDepth);
// Device output data bit depth. (XI_PRM_OUTPUT_DATA_BIT_DEPTH)
XI_BIT_DEPTH GetDeviceOutputDataBitDepth();
XI_BIT_DEPTH GetDeviceOutputDataBitDepth_Maximum();
XI_BIT_DEPTH GetDeviceOutputDataBitDepth_Minimum();
int GetDeviceOutputDataBitDepth_Increment();
void SetDeviceOutputDataBitDepth(XI_BIT_DEPTH DeviceOutputDataBitDepth);
// bit depth of data returned by function xiGetImage (XI_PRM_IMAGE_DATA_BIT_DEPTH)
XI_BIT_DEPTH GetImageDataBitDepth();
XI_BIT_DEPTH GetImageDataBitDepth_Maximum();
XI_BIT_DEPTH GetImageDataBitDepth_Minimum();
int GetImageDataBitDepth_Increment();
void SetImageDataBitDepth(XI_BIT_DEPTH ImageDataBitDepth);
// Device output data packing (or grouping) enabled. Packing could be enabled if output_data_bit_depth > 8 and packing capability is available. (XI_PRM_OUTPUT_DATA_PACKING)
bool IsDeviceOutputDataPacking();
void EnableDeviceOutputDataPacking();
void DisableDeviceOutputDataPacking();
// Data packing type. Some cameras supports only specific packing type. (XI_PRM_OUTPUT_DATA_PACKING_TYPE)
XI_OUTPUT_DATA_PACKING_TYPE GetDeviceOutputDataPackingType();
XI_OUTPUT_DATA_PACKING_TYPE GetDeviceOutputDataPackingType_Maximum();
XI_OUTPUT_DATA_PACKING_TYPE GetDeviceOutputDataPackingType_Minimum();
int GetDeviceOutputDataPackingType_Increment();
void SetDeviceOutputDataPackingType(XI_OUTPUT_DATA_PACKING_TYPE DeviceOutputDataPackingType);
//-------------------------------------------------------------------------------------------------------------------
// ---- Parameter Group: Temperature
//-------------------------------------------------------------------------------------------------------------------
// Returns 1 for cameras that support cooling. (XI_PRM_IS_COOLED)
bool IsCooled();
// Temperature control mode. (XI_PRM_COOLING)
XI_TEMP_CTRL_MODE_SELECTOR GetCooling();
XI_TEMP_CTRL_MODE_SELECTOR GetCooling_Maximum();
XI_TEMP_CTRL_MODE_SELECTOR GetCooling_Minimum();
int GetCooling_Increment();
void SetCooling(XI_TEMP_CTRL_MODE_SELECTOR Cooling);
// Set sensor target temperature for cooling. (XI_PRM_TARGET_TEMP)
float GetTargetTemperature();
float GetTargetTemperature_Maximum();
float GetTargetTemperature_Minimum();
float GetTargetTemperature_Increment();
void SetTargetTemperature(float TargetTemperature);
// Selector of mechanical point where thermometer is located. (XI_PRM_TEMP_SELECTOR)
XI_TEMP_SELECTOR GetTemperatureSelector();
XI_TEMP_SELECTOR GetTemperatureSelector_Maximum();
XI_TEMP_SELECTOR GetTemperatureSelector_Minimum();
int GetTemperatureSelector_Increment();
void SetTemperatureSelector(XI_TEMP_SELECTOR TemperatureSelector);
// Camera temperature (selected by XI_PRM_TEMP_SELECTOR) (XI_PRM_TEMP)
float GetTemperature();
float GetTemperature_Maximum();
float GetTemperature_Minimum();
float GetTemperature_Increment();
// Temperature control mode. (XI_PRM_TEMP_CONTROL_MODE)
XI_TEMP_CTRL_MODE_SELECTOR GetTemperatureControlMode();
XI_TEMP_CTRL_MODE_SELECTOR GetTemperatureControlMode_Maximum();
XI_TEMP_CTRL_MODE_SELECTOR GetTemperatureControlMode_Minimum();
int GetTemperatureControlMode_Increment();
void SetTemperatureControlMode(XI_TEMP_CTRL_MODE_SELECTOR TemperatureControlMode);
// Camera sensor temperature (XI_PRM_CHIP_TEMP)
float GetTemperatureSensor();
float GetTemperatureSensor_Maximum();
float GetTemperatureSensor_Minimum();
float GetTemperatureSensor_Increment();
// Camera housing temperature (XI_PRM_HOUS_TEMP)
float GetTemperatureHousing();
float GetTemperatureHousing_Maximum();
float GetTemperatureHousing_Minimum();
float GetTemperatureHousing_Increment();
// Camera housing back side temperature (XI_PRM_HOUS_BACK_SIDE_TEMP)
float GetTemperatureHousingBackSide();
float GetTemperatureHousingBackSide_Maximum();
float GetTemperatureHousingBackSide_Minimum();
float GetTemperatureHousingBackSide_Increment();
// Camera sensor board temperature (XI_PRM_SENSOR_BOARD_TEMP)
float GetTemperatureSensorBoard();
float GetTemperatureSensorBoard_Maximum();
float GetTemperatureSensorBoard_Minimum();
float GetTemperatureSensorBoard_Increment();
// Temperature element selector (TEC(Peltier), Fan). (XI_PRM_TEMP_ELEMENT_SEL)
XI_TEMP_ELEMENT_SELECTOR GetTemperatureElementSelector();
XI_TEMP_ELEMENT_SELECTOR GetTemperatureElementSelector_Maximum();
XI_TEMP_ELEMENT_SELECTOR GetTemperatureElementSelector_Minimum();
int GetTemperatureElementSelector_Increment();
void SetTemperatureElementSelector(XI_TEMP_ELEMENT_SELECTOR TemperatureElementSelector);
// Temperature element value in percents of full control range (XI_PRM_TEMP_ELEMENT_VALUE)
float GetTemperatureElementValue();
float GetTemperatureElementValue_Maximum();
float GetTemperatureElementValue_Minimum();
float GetTemperatureElementValue_Increment();
void SetTemperatureElementValue(float TemperatureElementValue);
//-------------------------------------------------------------------------------------------------------------------
// ---- Parameter Group: Color Correction
//-------------------------------------------------------------------------------------------------------------------
// Mode of color management system. (XI_PRM_CMS)
XI_CMS_MODE GetColorManagementMode();
XI_CMS_MODE GetColorManagementMode_Maximum();
XI_CMS_MODE GetColorManagementMode_Minimum();
int GetColorManagementMode_Increment();
void SetColorManagementMode(XI_CMS_MODE ColorManagementMode);
// Intent of color management system. (XI_PRM_CMS_INTENT)
XI_CMS_INTENT GetColorManagementIntent();
XI_CMS_INTENT GetColorManagementIntent_Maximum();
XI_CMS_INTENT GetColorManagementIntent_Minimum();
int GetColorManagementIntent_Increment();
void SetColorManagementIntent(XI_CMS_INTENT ColorManagementIntent);
// Enable applying of CMS profiles to xiGetImage (see XI_PRM_INPUT_CMS_PROFILE, XI_PRM_OUTPUT_CMS_PROFILE). (XI_PRM_APPLY_CMS)
bool IsColorManagementApply();
void EnableColorManagementApply();
void DisableColorManagementApply();
// Filename for input cms profile (e.g. input.icc) (XI_PRM_INPUT_CMS_PROFILE)
void GetColorManagementInputProfile(char* buffer, int buffer_lenght);
void SetColorManagementInputProfile(char* ColorManagementInputProfile);
// Filename for output cms profile (e.g. input.icc) (XI_PRM_OUTPUT_CMS_PROFILE)
void GetColorManagementOutputProfile(char* buffer, int buffer_lenght);
void SetColorManagementOutputProfile(char* ColorManagementOutputProfile);
// Returns 1 for color cameras. (XI_PRM_IMAGE_IS_COLOR)
bool IsSensorColor();
// Returns color filter array type of RAW data. (XI_PRM_COLOR_FILTER_ARRAY)
XI_COLOR_FILTER_ARRAY GetSensorColorFilterArray();
XI_COLOR_FILTER_ARRAY GetSensorColorFilterArray_Maximum();
XI_COLOR_FILTER_ARRAY GetSensorColorFilterArray_Minimum();
int GetSensorColorFilterArray_Increment();
// Luminosity gamma (XI_PRM_GAMMAY)
float GetGammaLuminosity();
float GetGammaLuminosity_Maximum();
float GetGammaLuminosity_Minimum();
float GetGammaLuminosity_Increment();
void SetGammaLuminosity(float GammaLuminosity);
// Chromaticity gamma (XI_PRM_GAMMAC)
float GetGammaChromaticity();
float GetGammaChromaticity_Maximum();
float GetGammaChromaticity_Minimum();
float GetGammaChromaticity_Increment();
void SetGammaChromaticity(float GammaChromaticity);
// Sharpness strength (XI_PRM_SHARPNESS)
float GetSharpness();
float GetSharpness_Maximum();
float GetSharpness_Minimum();
float GetSharpness_Increment();
void SetSharpness(float Sharpness);
// Color Correction Matrix element [0][0] (XI_PRM_CC_MATRIX_00)
float GetColorCorrectionMatrix00();
float GetColorCorrectionMatrix00_Maximum();
float GetColorCorrectionMatrix00_Minimum();
float GetColorCorrectionMatrix00_Increment();
void SetColorCorrectionMatrix00(float ColorCorrectionMatrix00);
// Color Correction Matrix element [0][1] (XI_PRM_CC_MATRIX_01)
float GetColorCorrectionMatrix01();
float GetColorCorrectionMatrix01_Maximum();
float GetColorCorrectionMatrix01_Minimum();
float GetColorCorrectionMatrix01_Increment();
void SetColorCorrectionMatrix01(float ColorCorrectionMatrix01);
// Color Correction Matrix element [0][2] (XI_PRM_CC_MATRIX_02)
float GetColorCorrectionMatrix02();
float GetColorCorrectionMatrix02_Maximum();
float GetColorCorrectionMatrix02_Minimum();
float GetColorCorrectionMatrix02_Increment();
void SetColorCorrectionMatrix02(float ColorCorrectionMatrix02);
// Color Correction Matrix element [0][3] (XI_PRM_CC_MATRIX_03)
float GetColorCorrectionMatrix03();
float GetColorCorrectionMatrix03_Maximum();
float GetColorCorrectionMatrix03_Minimum();
float GetColorCorrectionMatrix03_Increment();
void SetColorCorrectionMatrix03(float ColorCorrectionMatrix03);
// Color Correction Matrix element [1][0] (XI_PRM_CC_MATRIX_10)
float GetColorCorrectionMatrix10();
float GetColorCorrectionMatrix10_Maximum();
float GetColorCorrectionMatrix10_Minimum();
float GetColorCorrectionMatrix10_Increment();
void SetColorCorrectionMatrix10(float ColorCorrectionMatrix10);
// Color Correction Matrix element [1][1] (XI_PRM_CC_MATRIX_11)
float GetColorCorrectionMatrix11();
float GetColorCorrectionMatrix11_Maximum();
float GetColorCorrectionMatrix11_Minimum();
float GetColorCorrectionMatrix11_Increment();
void SetColorCorrectionMatrix11(float ColorCorrectionMatrix11);
// Color Correction Matrix element [1][2] (XI_PRM_CC_MATRIX_12)
float GetColorCorrectionMatrix12();
float GetColorCorrectionMatrix12_Maximum();
float GetColorCorrectionMatrix12_Minimum();
float GetColorCorrectionMatrix12_Increment();
void SetColorCorrectionMatrix12(float ColorCorrectionMatrix12);
// Color Correction Matrix element [1][3] (XI_PRM_CC_MATRIX_13)
float GetColorCorrectionMatrix13();
float GetColorCorrectionMatrix13_Maximum();
float GetColorCorrectionMatrix13_Minimum();
float GetColorCorrectionMatrix13_Increment();
void SetColorCorrectionMatrix13(float ColorCorrectionMatrix13);
// Color Correction Matrix element [2][0] (XI_PRM_CC_MATRIX_20)
float GetColorCorrectionMatrix20();
float GetColorCorrectionMatrix20_Maximum();
float GetColorCorrectionMatrix20_Minimum();
float GetColorCorrectionMatrix20_Increment();
void SetColorCorrectionMatrix20(float ColorCorrectionMatrix20);
// Color Correction Matrix element [2][1] (XI_PRM_CC_MATRIX_21)
float GetColorCorrectionMatrix21();
float GetColorCorrectionMatrix21_Maximum();
float GetColorCorrectionMatrix21_Minimum();
float GetColorCorrectionMatrix21_Increment();
void SetColorCorrectionMatrix21(float ColorCorrectionMatrix21);
// Color Correction Matrix element [2][2] (XI_PRM_CC_MATRIX_22)
float GetColorCorrectionMatrix22();
float GetColorCorrectionMatrix22_Maximum();
float GetColorCorrectionMatrix22_Minimum();
float GetColorCorrectionMatrix22_Increment();
void SetColorCorrectionMatrix22(float ColorCorrectionMatrix22);
// Color Correction Matrix element [2][3] (XI_PRM_CC_MATRIX_23)
float GetColorCorrectionMatrix23();
float GetColorCorrectionMatrix23_Maximum();
float GetColorCorrectionMatrix23_Minimum();
float GetColorCorrectionMatrix23_Increment();
void SetColorCorrectionMatrix23(float ColorCorrectionMatrix23);
// Color Correction Matrix element [3][0] (XI_PRM_CC_MATRIX_30)
float GetColorCorrectionMatrix30();
float GetColorCorrectionMatrix30_Maximum();
float GetColorCorrectionMatrix30_Minimum();
float GetColorCorrectionMatrix30_Increment();
void SetColorCorrectionMatrix30(float ColorCorrectionMatrix30);
// Color Correction Matrix element [3][1] (XI_PRM_CC_MATRIX_31)
float GetColorCorrectionMatrix31();
float GetColorCorrectionMatrix31_Maximum();
float GetColorCorrectionMatrix31_Minimum();
float GetColorCorrectionMatrix31_Increment();
void SetColorCorrectionMatrix31(float ColorCorrectionMatrix31);
// Color Correction Matrix element [3][2] (XI_PRM_CC_MATRIX_32)
float GetColorCorrectionMatrix32();
float GetColorCorrectionMatrix32_Maximum();
float GetColorCorrectionMatrix32_Minimum();
float GetColorCorrectionMatrix32_Increment();
void SetColorCorrectionMatrix32(float ColorCorrectionMatrix32);
// Color Correction Matrix element [3][3] (XI_PRM_CC_MATRIX_33)
float GetColorCorrectionMatrix33();
float GetColorCorrectionMatrix33_Maximum();
float GetColorCorrectionMatrix33_Minimum();
float GetColorCorrectionMatrix33_Increment();
void SetColorCorrectionMatrix33(float ColorCorrectionMatrix33);
// Set default Color Correction Matrix (XI_PRM_DEFAULT_CC_MATRIX)
void SetColorCorrectionMatrixDefault(int ColorCorrectionMatrixDefault);
// Normalize color correction matrix (XI_PRM_CC_MATRIX_NORM)
bool IsColorCorrectionMatrixNorm();
void EnableColorCorrectionMatrixNorm();
void DisableColorCorrectionMatrixNorm();