Yao Chunli
2022-06-21 e00d5a1575d26f8fec1be6fa8a844203cd66a24c
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
 
#ifndef _MV_CAMERA_PARAMS_H_
#define _MV_CAMERA_PARAMS_H_
 
#include "PixelType.h"
 
// É豸ÀàÐͶ¨Òå
#define MV_UNKNOW_DEVICE        0x00000000          // Î´ÖªÉ豸ÀàÐÍ£¬±£ÁôÒâÒå
#define MV_GIGE_DEVICE          0x00000001          // GigEÉ豸
#define MV_1394_DEVICE          0x00000002          // 1394-a/b É豸
#define MV_USB_DEVICE           0x00000004          // USB3.0 É豸
#define MV_CAMERALINK_DEVICE    0x00000008          // CameraLinkÉ豸
 
typedef struct _MV_GIGE_DEVICE_INFO_
{
    unsigned int        nIpCfgOption;        
    unsigned int        nIpCfgCurrent;       //IP configuration:bit31-static bit30-dhcp bit29-lla          
    unsigned int        nCurrentIp;          //curtent ip          
    unsigned int        nCurrentSubNetMask;  //curtent subnet mask             
    unsigned int        nDefultGateWay;      //current gateway
    unsigned char       chManufacturerName[32];
    unsigned char       chModelName[32];
    unsigned char       chDeviceVersion[32];
    unsigned char       chManufacturerSpecificInfo[48];
    unsigned char       chSerialNumber[16];
    unsigned char       chUserDefinedName[16];      
 
    unsigned int        nNetExport;         // Íø¿ÚIPµØÖ·
 
    unsigned int        nReserved[4];
 
}MV_GIGE_DEVICE_INFO;
 
#define INFO_MAX_BUFFER_SIZE 64
typedef struct _MV_USB3_DEVICE_INFO_
{
    unsigned char           CrtlInEndPoint;                        //¿ØÖÆÊäÈë¶Ëµã
    unsigned char           CrtlOutEndPoint;                       //¿ØÖÆÊä³ö¶Ëµã
    unsigned char           StreamEndPoint;                        //Á÷¶Ëµã
    unsigned char           EventEndPoint;                         //ʼþ¶Ëµã
    unsigned short          idVendor;                              //¹©Ó¦ÉÌIDºÅ
    unsigned short          idProduct;                             //²úÆ·IDºÅ
    unsigned int            nDeviceNumber;                         //É豸ÐòÁкŠ
    unsigned char           chDeviceGUID[INFO_MAX_BUFFER_SIZE];    //É豸GUIDºÅ
    unsigned char           chVendorName[INFO_MAX_BUFFER_SIZE];    //¹©Ó¦ÉÌÃû×Ö
    unsigned char           chModelName[INFO_MAX_BUFFER_SIZE];     //ÐͺÅÃû×Ö
    unsigned char           chFamilyName[INFO_MAX_BUFFER_SIZE];    //¼Ò×åÃû×Ö
    unsigned char           chDeviceVersion[INFO_MAX_BUFFER_SIZE];  //É豸°æ±¾ºÅ
    unsigned char           chManufacturerName[INFO_MAX_BUFFER_SIZE]; //ÖÆÔìÉÌÃû×Ö
    unsigned char           chSerialNumber[INFO_MAX_BUFFER_SIZE];      //ÐòÁкÅ
    unsigned char           chUserDefinedName[INFO_MAX_BUFFER_SIZE];  //Óû§×Ô¶¨ÒåÃû×Ö
    unsigned int            nbcdUSB;                               //Ö§³ÖµÄUSBЭÒé
    unsigned int            nReserved[3];                             //±£Áô×Ö½Ú
}MV_USB3_DEVICE_INFO;
 
// É豸ÐÅÏ¢
typedef struct _MV_CC_DEVICE_INFO_
{
    // common info 
    unsigned short      nMajorVer;
    unsigned short      nMinorVer;
    unsigned int        nMacAddrHigh;               // MAC µØÖ·
    unsigned int        nMacAddrLow;
 
    unsigned int        nTLayerType;                // É豸´«Êä²ãЭÒéÀàÐÍ£¬e.g. MV_GIGE_DEVICE
 
    unsigned int        nReserved[4];
 
    union
    {
        MV_GIGE_DEVICE_INFO stGigEInfo;
        MV_USB3_DEVICE_INFO stUsb3VInfo; 
        // more ...
    }SpecialInfo;
 
}MV_CC_DEVICE_INFO;
 
// ÍøÂç´«ÊäµÄÏà¹ØÐÅÏ¢
typedef struct _MV_NETTRANS_INFO_
{
    int64_t         nReviceDataSize;    // ÒѽÓÊÕÊý¾Ý´óС  [ͳ¼ÆStartGrabbingºÍStopGrabbingÖ®¼äµÄÊý¾ÝÁ¿]
    int             nThrowFrameCount;   // ¶ªÖ¡ÊýÁ¿
    unsigned int    nReserved[5];
 
}MV_NETTRANS_INFO;
 
 
// ×î¶àÖ§³ÖµÄ´«Êä²ãʵÀý¸öÊý
#define MV_MAX_TLS_NUM          8
// ×î´óÖ§³ÖµÄÉ豸¸öÊý
#define MV_MAX_DEVICE_NUM      256
 
// É豸ÐÅÏ¢Áбí
typedef struct _MV_CC_DEVICE_INFO_LIST_
{
    unsigned int            nDeviceNum;                         // ÔÚÏßÉ豸ÊýÁ¿
    MV_CC_DEVICE_INFO*      pDeviceInfo[MV_MAX_DEVICE_NUM];     // Ö§³Ö×î¶à256¸öÉ豸
 
}MV_CC_DEVICE_INFO_LIST;
 
 
// Êä³öÖ¡µÄÐÅÏ¢
typedef struct _MV_FRAME_OUT_INFO_
{
    unsigned short      nWidth;             // Í¼Ïñ¿í
    unsigned short      nHeight;            // Í¼Ïñ¸ß
    enum MvGvspPixelType     enPixelType;        // ÏñËظñʽ
 
    /*ÒÔÏÂ×Ö¶ÎÔݲ»Ö§³Ö*/
    unsigned int        nFrameNum;          // Ö¡ºÅ
    unsigned int        nDevTimeStampHigh;  // Ê±¼ä´Á¸ß32λ
    unsigned int        nDevTimeStampLow;   // Ê±¼ä´ÁµÍ32λ
    unsigned int        nReserved0;         // ±£Áô£¬8×Ö½Ú¶ÔÆë
    int64_t             nHostTimeStamp;     // Ö÷»úÉú³ÉµÄʱ¼ä´Á
 
    unsigned int        nFrameLen;
 
    unsigned int        nLostPacket;  // ±¾Ö¡¶ª°üÊý
    unsigned int        nReserved[2];
}MV_FRAME_OUT_INFO;
 
// Êä³öÖ¡µÄÐÅÏ¢
typedef struct _MV_FRAME_OUT_INFO_EX_
{
    unsigned short      nWidth;             // Í¼Ïñ¿í
    unsigned short      nHeight;            // Í¼Ïñ¸ß
    enum MvGvspPixelType     enPixelType;        // ÏñËظñʽ
 
    /*ÒÔÏÂ×Ö¶ÎÔݲ»Ö§³Ö*/
    unsigned int        nFrameNum;          // Ö¡ºÅ
    unsigned int        nDevTimeStampHigh;  // Ê±¼ä´Á¸ß32λ
    unsigned int        nDevTimeStampLow;   // Ê±¼ä´ÁµÍ32λ
    unsigned int        nReserved0;         // ±£Áô£¬8×Ö½Ú¶ÔÆë
    int64_t             nHostTimeStamp;     // Ö÷»úÉú³ÉµÄʱ¼ä´Á
 
    unsigned int        nFrameLen;
 
    // ÒÔÏÂΪchunkÐÂÔöˮӡÐÅÏ¢
    // É豸ˮӡʱ±ê
    unsigned int        nSecondCount;
    unsigned int        nCycleCount;
    unsigned int        nCycleOffset;
 
    float               fGain;
    float               fExposureTime;
    unsigned int        nAverageBrightness;     //ƽ¾ùÁÁ¶È
 
    // °×ƽºâÏà¹Ø
    unsigned int        nRed;
    unsigned int        nGreen;
    unsigned int        nBlue;
 
    unsigned int        nFrameCounter;
    unsigned int        nTriggerIndex;      //´¥·¢¼ÆÊý
 
    //Line ÊäÈë/Êä³ö
    unsigned int        nInput;        //ÊäÈë
    unsigned int        nOutput;       //Êä³ö
 
    // ROIÇøÓò
    unsigned short      nOffsetX;
    unsigned short      nOffsetY;
    unsigned short      nChunkWidth;
    unsigned short      nChunkHeight;
 
    unsigned int        nLostPacket;  // ±¾Ö¡¶ª°üÊý
 
    unsigned int        nReserved[39];       // ±£Áô
}MV_FRAME_OUT_INFO_EX;
 
typedef struct _MV_DISPLAY_FRAME_INFO_
{
    void*                    hWnd;
    unsigned char*           pData;
    unsigned int             nDataLen;
    unsigned short           nWidth;             // Í¼Ïñ¿í
    unsigned short           nHeight;            // Í¼Ïñ¸ß
    enum MvGvspPixelType     enPixelType;        // ÏñËظñʽ
    unsigned int             nRes[4];
 
}MV_DISPLAY_FRAME_INFO;
 
// ±£´æͼƬ¸ñʽ
enum MV_SAVE_IAMGE_TYPE
{
    MV_Image_Undefined                 = 0,
    MV_Image_Bmp                       = 1,
    MV_Image_Jpeg                      = 2,
    MV_Image_Png                       = 3,     //²»Ö§³Ö
    MV_Image_Tif                       = 4,     //²»Ö§³Ö
};
// ±£´æͼƬ²ÎÊý
typedef struct _MV_SAVE_IMAGE_PARAM_T_
{
    unsigned char*        pData;              // [IN]     ÊäÈëÊý¾Ý»º´æ
    unsigned int          nDataLen;           // [IN]     ÊäÈëÊý¾Ý´óС
    enum MvGvspPixelType       enPixelType;        // [IN]     ÊäÈëÊý¾ÝµÄÏñËظñʽ
    unsigned short        nWidth;             // [IN]     Í¼Ïñ¿í
    unsigned short        nHeight;            // [IN]     Í¼Ïñ¸ß
 
    unsigned char*        pImageBuffer;       // [OUT]    Êä³öͼƬ»º´æ
    unsigned int          nImageLen;          // [OUT]    Êä³öͼƬ´óС
    unsigned int          nBufferSize;        // [IN]     ÌṩµÄÊä³ö»º³åÇø´óС
    enum MV_SAVE_IAMGE_TYPE    enImageType;        // [IN]     Êä³öͼƬ¸ñʽ
 
}MV_SAVE_IMAGE_PARAM;
 
// Í¼Æ¬±£´æ²ÎÊý
typedef struct _MV_SAVE_IMAGE_PARAM_T_EX_
{
    unsigned char*      pData;              // [IN]     ÊäÈëÊý¾Ý»º´æ
    unsigned int        nDataLen;           // [IN]     ÊäÈëÊý¾Ý´óС
    enum MvGvspPixelType     enPixelType;        // [IN]     ÊäÈëÊý¾ÝµÄÏñËظñʽ
    unsigned short      nWidth;             // [IN]     Í¼Ïñ¿í
    unsigned short      nHeight;            // [IN]     Í¼Ïñ¸ß
 
    unsigned char*      pImageBuffer;       // [OUT]    Êä³öͼƬ»º´æ
    unsigned int        nImageLen;          // [OUT]    Êä³öͼƬ´óС
    unsigned int        nBufferSize;        // [IN]     ÌṩµÄÊä³ö»º³åÇø´óС
    enum MV_SAVE_IAMGE_TYPE  enImageType;        // [IN]     Êä³öͼƬ¸ñʽ
    unsigned int        nJpgQuality;        // [IN]     ±àÂëÖÊÁ¿, (50-99]
 
    // [IN]     Bayer¸ñʽתΪRGB24µÄ²åÖµ·½·¨  0-×î½üÁÚ 1-Ë«ÏßÐÔ 2-Hamilton
    unsigned int        iMethodValue;
    unsigned int        nReserved[3];
 
}MV_SAVE_IMAGE_PARAM_EX;
 
// Í¼Ïñת»»½á¹¹Ìå
typedef struct _MV_PIXEL_CONVERT_PARAM_T_
{
    unsigned short      nWidth;             // [IN]     Í¼Ïñ¿í
    unsigned short      nHeight;            // [IN]     Í¼Ïñ¸ß
 
    enum MvGvspPixelType    enSrcPixelType;     // [IN]     Ô´ÏñËظñʽ
    unsigned char*      pSrcData;           // [IN]     ÊäÈëÊý¾Ý»º´æ
    unsigned int        nSrcDataLen;        // [IN]     ÊäÈëÊý¾Ý´óС
 
    enum MvGvspPixelType    enDstPixelType;     // [IN]     Ä¿±êÏñËظñʽ
    unsigned char*      pDstBuffer;         // [OUT]    Êä³öÊý¾Ý»º´æ
    unsigned int        nDstLen;            // [OUT]    Êä³öÊý¾Ý´óС
    unsigned int        nDstBufferSize;     // [IN]     ÌṩµÄÊä³ö»º³åÇø´óС
    unsigned int        nRes[4];
}MV_CC_PIXEL_CONVERT_PARAM;
 
 
 
// ²É¼¯Ä£Ê½
typedef enum _MV_CAM_ACQUISITION_MODE_
{
    MV_ACQ_MODE_SINGLE      = 0,            // µ¥Ö¡Ä£Ê½
    MV_ACQ_MODE_MUTLI       = 1,            // ¶à֡ģʽ
    MV_ACQ_MODE_CONTINUOUS  = 2,            // ³ÖÐø²É¼¯Ä£Ê½
 
}MV_CAM_ACQUISITION_MODE;
 
// ÔöÒæģʽ
typedef enum _MV_CAM_GAIN_MODE_
{
    MV_GAIN_MODE_OFF        = 0,            // ¹Ø±Õ
    MV_GAIN_MODE_ONCE       = 1,            // Ò»´Î
    MV_GAIN_MODE_CONTINUOUS = 2,            // Á¬Ðø
 
}MV_CAM_GAIN_MODE;
 
// Æعâģʽ
typedef enum _MV_CAM_EXPOSURE_MODE_
{
    MV_EXPOSURE_MODE_TIMED          = 0,            // Timed
    MV_EXPOSURE_MODE_TRIGGER_WIDTH  = 1,            // TriggerWidth
}MV_CAM_EXPOSURE_MODE;
 
// ×Ô¶¯Æعâģʽ
typedef enum _MV_CAM_EXPOSURE_AUTO_MODE_
{
    MV_EXPOSURE_AUTO_MODE_OFF        = 0,            // ¹Ø±Õ
    MV_EXPOSURE_AUTO_MODE_ONCE       = 1,            // Ò»´Î
    MV_EXPOSURE_AUTO_MODE_CONTINUOUS = 2,            // Á¬Ðø
 
}MV_CAM_EXPOSURE_AUTO_MODE;
 
typedef enum _MV_CAM_TRIGGER_MODE_
{
    MV_TRIGGER_MODE_OFF         = 0,            // ¹Ø±Õ
    MV_TRIGGER_MODE_ON          = 1,            // ´ò¿ª
 
}MV_CAM_TRIGGER_MODE;
 
typedef enum _MV_CAM_GAMMA_SELECTOR_
{
    MV_GAMMA_SELECTOR_USER      = 1,
    MV_GAMMA_SELECTOR_SRGB      = 2,
 
}MV_CAM_GAMMA_SELECTOR;
 
typedef enum _MV_CAM_BALANCEWHITE_AUTO_
{
    MV_BALANCEWHITE_AUTO_OFF            = 0,
    MV_BALANCEWHITE_AUTO_ONCE           = 2,
    MV_BALANCEWHITE_AUTO_CONTINUOUS     = 1,            // Á¬Ðø
 
}MV_CAM_BALANCEWHITE_AUTO;
 
typedef enum _MV_CAM_TRIGGER_SOURCE_
{
    MV_TRIGGER_SOURCE_LINE0             = 0,
    MV_TRIGGER_SOURCE_LINE1             = 1,
    MV_TRIGGER_SOURCE_LINE2             = 2,
    MV_TRIGGER_SOURCE_LINE3             = 3,
    MV_TRIGGER_SOURCE_COUNTER0          = 4,
 
    MV_TRIGGER_SOURCE_SOFTWARE          = 7,
    MV_TRIGGER_SOURCE_FrequencyConverter= 8,
 
}MV_CAM_TRIGGER_SOURCE;
 
 
// GigEVision IP Configuration
#define MV_IP_CFG_STATIC        0x05000000
#define MV_IP_CFG_DHCP          0x06000000
#define MV_IP_CFG_LLA           0x04000000
 
// GigEVision Net Transfer Mode
#define MV_NET_TRANS_DRIVER     0x00000001
#define MV_NET_TRANS_SOCKET     0x00000002
 
 
// ÐÅÏ¢ÀàÐÍ
#define MV_MATCH_TYPE_NET_DETECT             0x00000001      // ÍøÂçÁ÷Á¿ºÍ¶ª°üÐÅÏ¢
#define MV_MATCH_TYPE_USB_DETECT             0x00000002      // host½ÓÊÕµ½À´×ÔU3VÉ豸µÄ×Ö½Ú×ÜÊý
 
 
// Ä³¸ö½Úµã¶ÔÓ¦µÄ×Ó½Úµã¸öÊý×î´óÖµ
#define MV_MAX_XML_NODE_NUM_C       128
 
// ½ÚµãÃû³Æ×Ö·û´®×î´ó³¤¶È
#define MV_MAX_XML_NODE_STRLEN_C    64
 
//½ÚµãStringÖµ×î´ó³¤¶È
#define MV_MAX_XML_STRVALUE_STRLEN_C 64
 
// ½ÚµãÃèÊö×Ö¶Î×î´ó³¤¶È
#define MV_MAX_XML_DISC_STRLEN_C    512
 
// ×î¶àµÄµ¥ÔªÊý
#define MV_MAX_XML_ENTRY_NUM        10
 
// ¸¸½Úµã¸öÊýÉÏÏÞ
#define MV_MAX_XML_PARENTS_NUM      8
 
//ÿ¸öÒѾ­ÊµÏÖµ¥ÔªµÄÃû³Æ³¤¶È
#define MV_MAX_XML_SYMBOLIC_STRLEN_C 64
 
#define MV_MAX_XML_SYMBOLIC_NUM      64
 
//ÖØ·¢°üĬÈÏ×î´ó°üÊýÁ¿
 
// È«Æ¥ÅäµÄÒ»ÖÖÐÅÏ¢½á¹¹Ìå
typedef struct _MV_ALL_MATCH_INFO_
{
    unsigned int    nType;          // ÐèÒªÊä³öµÄÐÅÏ¢ÀàÐÍ£¬e.g. MV_MATCH_TYPE_NET_DETECT
    void*           pInfo;          // Êä³öµÄÐÅÏ¢»º´æ£¬Óɵ÷ÓÃÕß·ÖÅä
    unsigned int    nInfoSize;      // ÐÅÏ¢»º´æµÄ´óС
 
}MV_ALL_MATCH_INFO;
 
//  ÍøÂçÁ÷Á¿ºÍ¶ª°üÐÅÏ¢·´À¡½á¹¹Ì壬¶ÔÓ¦ÀàÐÍΪ MV_MATCH_TYPE_NET_DETECT
typedef struct _MV_MATCH_INFO_NET_DETECT_
{
    int64_t         nReviceDataSize;    // ÒѽÓÊÕÊý¾Ý´óС  [ͳ¼ÆStartGrabbingºÍStopGrabbingÖ®¼äµÄÊý¾ÝÁ¿]
    int64_t         nLostPacketCount;   // ¶ªÊ§µÄ°üÊýÁ¿
    unsigned int    nLostFrameCount;    // ¶ªÖ¡ÊýÁ¿
    unsigned int    nReserved[5];          // ±£Áô
}MV_MATCH_INFO_NET_DETECT;
 
// hostÊÕµ½´Óu3vÉ豸¶ËµÄ×Ü×Ö½ÚÊý£¬¶ÔÓ¦ÀàÐÍΪ MV_MATCH_TYPE_USB_DETECT
typedef struct _MV_MATCH_INFO_USB_DETECT_
{
    int64_t         nReviceDataSize;      // ÒѽÓÊÕÊý¾Ý´óС    [ͳ¼ÆOpenDevicceºÍCloseDeviceÖ®¼äµÄÊý¾ÝÁ¿]
    unsigned int    nRevicedFrameCount;   // ÒÑÊÕµ½µÄÖ¡Êý
    unsigned int    nErrorFrameCount;     // ´íÎóÖ¡Êý
    unsigned int    nReserved[2];         // ±£Áô
}MV_MATCH_INFO_USB_DETECT;
 
typedef struct _MV_IMAGE_BASIC_INFO_
{
    // width
    unsigned short      nWidthValue;
    unsigned short      nWidthMin;
    unsigned int        nWidthMax;
    unsigned int        nWidthInc;
 
    // height
    unsigned int        nHeightValue;
    unsigned int        nHeightMin;
    unsigned int        nHeightMax;
    unsigned int        nHeightInc;
 
    // framerate
    float               fFrameRateValue;
    float               fFrameRateMin;
    float               fFrameRateMax;
 
    // ÏñËظñʽ
    unsigned int        enPixelType;                // µ±Ç°µÄÏñËظñʽ
    unsigned int        nSupportedPixelFmtNum;      // Ö§³ÖµÄÏñËظñʽÖÖÀà
    unsigned int        enPixelList[MV_MAX_XML_SYMBOLIC_NUM];
    unsigned int        nReserved[8];
 
}MV_IMAGE_BASIC_INFO;
 
//  Òì³£ÏûÏ¢ÀàÐÍ
#define MV_EXCEPTION_DEV_DISCONNECT     0x00008001      // É豸¶Ï¿ªÁ¬½Ó
#define MV_EXCEPTION_VERSION_CHECK      0x00008002      // SDKÓëÇý¶¯°æ±¾²»Æ¥Åä
 
 
// É豸µÄ·ÃÎÊģʽ
// ¶ÀռȨÏÞ£¬ÆäËûAPPÖ»ÔÊÐí¶ÁCCP¼Ä´æÆ÷
#define MV_ACCESS_Exclusive                                         1
// ¿ÉÒÔ´Ó5ģʽÏÂÇÀռȨÏÞ£¬È»ºóÒÔ¶ÀռȨÏÞ´ò¿ª
#define MV_ACCESS_ExclusiveWithSwitch                               2
// ¿ØÖÆȨÏÞ£¬ÆäËûAPPÔÊÐí¶ÁËùÓмĴæÆ÷
#define MV_ACCESS_Control                                           3
// ¿ÉÒÔ´Ó5µÄģʽÏÂÇÀռȨÏÞ£¬È»ºóÒÔ¿ØÖÆȨÏÞ´ò¿ª
#define MV_ACCESS_ControlWithSwitch                                 4
// ÒԿɱ»ÇÀÕ¼µÄ¿ØÖÆȨÏÞ´ò¿ª
#define MV_ACCESS_ControlSwitchEnable                               5
// ¿ÉÒÔ´Ó5µÄģʽÏÂÇÀռȨÏÞ£¬È»ºóÒԿɱ»ÇÀÕ¼µÄ¿ØÖÆȨÏÞ´ò¿ª
#define MV_ACCESS_ControlSwitchEnableWithKey                        6
// ¶Áģʽ´ò¿ªÉ豸£¬ÊÊÓÃÓÚ¿ØÖÆȨÏÞÏÂ
#define MV_ACCESS_Monitor                                           7
 
 
/************************************************************************/
/* ·â×°ÁËGenICamµÄC½Ó¿ÚÏà¹Ø²ÎÊý¶¨Òå                                     */
/************************************************************************/
 
// Ã¿¸ö½Úµã¶ÔÓ¦µÄ½Ó¿ÚÀàÐÍ
enum MV_XML_InterfaceType
{
    IFT_IValue,         //!> IValue interface
    IFT_IBase,          //!> IBase interface
    IFT_IInteger,       //!> IInteger interface
    IFT_IBoolean,       //!> IBoolean interface
    IFT_ICommand,       //!> ICommand interface
    IFT_IFloat,         //!> IFloat interface
    IFT_IString,        //!> IString interface
    IFT_IRegister,      //!> IRegister interface
    IFT_ICategory,      //!> ICategory interface
    IFT_IEnumeration,   //!> IEnumeration interface
    IFT_IEnumEntry,     //!> IEnumEntry interface
    IFT_IPort,          //!> IPort interface
};
 
// ½ÚµãµÄ·ÃÎÊģʽ
enum MV_XML_AccessMode
{
    AM_NI,          //!< Not implemented
    AM_NA,          //!< Not available
    AM_WO,          //!< Write Only
    AM_RO,          //!< Read Only
    AM_RW,          //!< Read and Write
    AM_Undefined,   //!< Object is not yet initialized
    AM_CycleDetect, //!< used internally for AccessMode cycle detection
 
};
 
enum MV_XML_Visibility
{
    V_Beginner      = 0,    //!< Always visible
    V_Expert        = 1,    //!< Visible for experts or Gurus
    V_Guru          = 2,    //!< Visible for Gurus
    V_Invisible     = 3,    //!< Not Visible
    V_Undefined     = 99    //!< Object is not yet initialized
};
 
typedef enum _MV_GIGE_EVENT_
{
    MV_EVENT_ExposureEnd                 = 1,           // Ã¿Ö¡µÄÆعâ½áÊø
    MV_EVENT_FrameStartOvertrigger       = 2,           // Ö¡¿ªÊ¼´¥·¢
    MV_EVENT_AcquisitionStartOvertrigger = 3,           // È¡Á÷¿ªÊ¼¹ý´¥·¢
    MV_EVENT_FrameStart                  = 4,           // Ã¿Ö¡µÄ¿ªÊ¼
    MV_EVENT_AcquisitionStart            = 5,           // ¿ªÊ¼È¡Á÷£¨Á¬Ðø»òµ¥Ö¡Ä£Ê½£©
    MV_EVENT_EventOverrun                = 6            // Ê¼þ¹ý´¥·¢
}MV_GIGE_EVENT;
 
 
//
 
// µ¥¸ö½Úµã»ù±¾ÊôÐÔ
typedef struct _MV_XML_NODE_FEATURE_
{
    enum MV_XML_InterfaceType    enType;                             // ½ÚµãÀàÐÍ
    enum MV_XML_Visibility       enVisivility;                       //ÊÇ·ñ¿É¼û
    char                    strDescription[MV_MAX_XML_DISC_STRLEN_C];//½ÚµãÃèÊö     Ä¿Ç°Ôݲ»Ö§³Ö
    char                    strDisplayName[MV_MAX_XML_NODE_STRLEN_C];//ÏÔʾÃû³Æ
    char                    strName[MV_MAX_XML_NODE_STRLEN_C];  // ½ÚµãÃû
    char                    strToolTip[MV_MAX_XML_DISC_STRLEN_C];  //Ìáʾ
 
    unsigned int            nReserved[4];
}MV_XML_NODE_FEATURE;
 
// ½ÚµãÁбí
typedef struct _MV_XML_NODES_LIST_
{
    unsigned int            nNodeNum;       // ½Úµã¸öÊý
    MV_XML_NODE_FEATURE     stNodes[MV_MAX_XML_NODE_NUM_C];
}MV_XML_NODES_LIST;
 
 
 
typedef struct _MV_XML_FEATURE_Value_
{
    enum MV_XML_InterfaceType    enType;                             // ½ÚµãÀàÐÍ
    char                    strDescription[MV_MAX_XML_DISC_STRLEN_C];//½ÚµãÃèÊö     Ä¿Ç°Ôݲ»Ö§³Ö
    char                    strDisplayName[MV_MAX_XML_NODE_STRLEN_C];//ÏÔʾÃû³Æ
    char                    strName[MV_MAX_XML_NODE_STRLEN_C];  // ½ÚµãÃû
    char                    strToolTip[MV_MAX_XML_DISC_STRLEN_C];  //Ìáʾ
    unsigned int            nReserved[4];
}MV_XML_FEATURE_Value;
 
typedef struct _MV_XML_FEATURE_Base_
{
    enum MV_XML_AccessMode   enAccessMode;       // ·ÃÎÊģʽ
}MV_XML_FEATURE_Base;
 
typedef struct _MV_XML_FEATURE_Integer_
{
    char                strName[MV_MAX_XML_NODE_STRLEN_C];
    char                strDisplayName[MV_MAX_XML_NODE_STRLEN_C];
    char                strDescription[MV_MAX_XML_DISC_STRLEN_C];   // Ä¿Ç°Ôݲ»Ö§³Ö
    char                strToolTip[MV_MAX_XML_DISC_STRLEN_C];
 
    enum MV_XML_Visibility   enVisivility;                       //ÊÇ·ñ¿É¼û
    enum MV_XML_AccessMode   enAccessMode;       // ·ÃÎÊģʽ
    int                 bIsLocked;          // ÊÇ·ñËø¶¨¡£0-·ñ£»1-ÊÇ    Ä¿Ç°Ôݲ»Ö§³Ö
    int64_t             nValue;             // µ±Ç°Öµ
    int64_t             nMinValue;          // ×îСֵ
    int64_t             nMaxValue;          // ×î´óÖµ
    int64_t             nIncrement;         // ÔöÁ¿
 
    unsigned int        nReserved[4];
 
}MV_XML_FEATURE_Integer;
 
typedef struct _MV_XML_FEATURE_Boolean_
{
    char                strName[MV_MAX_XML_NODE_STRLEN_C];
    char                strDisplayName[MV_MAX_XML_NODE_STRLEN_C];
    char                strDescription[MV_MAX_XML_DISC_STRLEN_C];   // Ä¿Ç°Ôݲ»Ö§³Ö
    char                strToolTip[MV_MAX_XML_DISC_STRLEN_C];
 
    enum MV_XML_Visibility   enVisivility;                       //ÊÇ·ñ¿É¼û
    enum MV_XML_AccessMode   enAccessMode;       // ·ÃÎÊģʽ
    int                 bIsLocked;          // ÊÇ·ñËø¶¨¡£0-·ñ£»1-ÊÇ    Ä¿Ç°Ôݲ»Ö§³Ö
    bool                bValue;             // µ±Ç°Öµ
 
    unsigned int        nReserved[4];
}MV_XML_FEATURE_Boolean;
 
typedef struct _MV_XML_FEATURE_Command_
{
    char                strName[MV_MAX_XML_NODE_STRLEN_C];
    char                strDisplayName[MV_MAX_XML_NODE_STRLEN_C];
    char                strDescription[MV_MAX_XML_DISC_STRLEN_C];   // Ä¿Ç°Ôݲ»Ö§³Ö
    char                strToolTip[MV_MAX_XML_DISC_STRLEN_C];
 
    enum MV_XML_Visibility   enVisivility;                       //ÊÇ·ñ¿É¼û
    enum MV_XML_AccessMode   enAccessMode;       // ·ÃÎÊģʽ
    int                 bIsLocked;          // ÊÇ·ñËø¶¨¡£0-·ñ£»1-ÊÇ    Ä¿Ç°Ôݲ»Ö§³Ö
 
    unsigned int        nReserved[4];
}MV_XML_FEATURE_Command;
 
typedef struct _MV_XML_FEATURE_Float_
{
    char                strName[MV_MAX_XML_NODE_STRLEN_C];
    char                strDisplayName[MV_MAX_XML_NODE_STRLEN_C];
    char                strDescription[MV_MAX_XML_DISC_STRLEN_C];   // Ä¿Ç°Ôݲ»Ö§³Ö
    char                strToolTip[MV_MAX_XML_DISC_STRLEN_C];
 
    enum MV_XML_Visibility       enVisivility;                       //ÊÇ·ñ¿É¼û
    enum MV_XML_AccessMode   enAccessMode;       // ·ÃÎÊģʽ
    int                 bIsLocked;          // ÊÇ·ñËø¶¨¡£0-·ñ£»1-ÊÇ    Ä¿Ç°Ôݲ»Ö§³Ö
    double              dfValue;             // µ±Ç°Öµ
    double              dfMinValue;          // ×îСֵ
    double              dfMaxValue;          // ×î´óÖµ
    double              dfIncrement;         // ÔöÁ¿
 
    unsigned int        nReserved[4];
}MV_XML_FEATURE_Float;
 
typedef struct _MV_XML_FEATURE_String_
{
    char                strName[MV_MAX_XML_NODE_STRLEN_C];
    char                strDisplayName[MV_MAX_XML_NODE_STRLEN_C];
    char                strDescription[MV_MAX_XML_DISC_STRLEN_C];   // Ä¿Ç°Ôݲ»Ö§³Ö
    char                strToolTip[MV_MAX_XML_DISC_STRLEN_C];
 
    enum MV_XML_Visibility       enVisivility;                       //ÊÇ·ñ¿É¼û
    enum MV_XML_AccessMode   enAccessMode;       // ·ÃÎÊģʽ
    int                 bIsLocked;          // ÊÇ·ñËø¶¨¡£0-·ñ£»1-ÊÇ    Ä¿Ç°Ôݲ»Ö§³Ö
    char                strValue[MV_MAX_XML_STRVALUE_STRLEN_C];// µ±Ç°Öµ
 
    unsigned int        nReserved[4];
}MV_XML_FEATURE_String;
 
typedef struct _MV_XML_FEATURE_Register_
{
    char                strName[MV_MAX_XML_NODE_STRLEN_C];
    char                strDisplayName[MV_MAX_XML_NODE_STRLEN_C];
    char                strDescription[MV_MAX_XML_DISC_STRLEN_C];   // Ä¿Ç°Ôݲ»Ö§³Ö
    char                strToolTip[MV_MAX_XML_DISC_STRLEN_C];
 
    enum MV_XML_Visibility       enVisivility;                       //ÊÇ·ñ¿É¼û
    enum MV_XML_AccessMode   enAccessMode;       // ·ÃÎÊģʽ
    int                 bIsLocked;          // ÊÇ·ñËø¶¨¡£0-·ñ£»1-ÊÇ    Ä¿Ç°Ôݲ»Ö§³Ö
    int64_t             nAddrValue;             // µ±Ç°Öµ
 
    unsigned int        nReserved[4];
}MV_XML_FEATURE_Register;
 
typedef struct _MV_XML_FEATURE_Category_
{
    char                    strDescription[MV_MAX_XML_DISC_STRLEN_C];//½ÚµãÃèÊö Ä¿Ç°Ôݲ»Ö§³Ö
    char                    strDisplayName[MV_MAX_XML_NODE_STRLEN_C];//ÏÔʾÃû³Æ
    char                    strName[MV_MAX_XML_NODE_STRLEN_C];  // ½ÚµãÃû
    char                    strToolTip[MV_MAX_XML_DISC_STRLEN_C];  //Ìáʾ
 
    enum MV_XML_Visibility       enVisivility;                       //ÊÇ·ñ¿É¼û
 
    unsigned int            nReserved[4];
}MV_XML_FEATURE_Category;
 
typedef struct _MV_XML_FEATURE_EnumEntry_
{
    char                strName[MV_MAX_XML_NODE_STRLEN_C];
    char                strDisplayName[MV_MAX_XML_NODE_STRLEN_C];
    char                strDescription[MV_MAX_XML_DISC_STRLEN_C];   // Ä¿Ç°Ôݲ»Ö§³Ö
    char                strToolTip[MV_MAX_XML_DISC_STRLEN_C];
    int                 bIsImplemented;
    int                 nParentsNum;
    MV_XML_NODE_FEATURE stParentsList[MV_MAX_XML_PARENTS_NUM];
 
    enum MV_XML_Visibility       enVisivility;                       //ÊÇ·ñ¿É¼û
    int64_t             nValue;             // µ±Ç°Öµ
    enum MV_XML_AccessMode   enAccessMode;       // ·ÃÎÊģʽ
    int                 bIsLocked;          // ÊÇ·ñËø¶¨¡£0-·ñ£»1-ÊÇ    Ä¿Ç°Ôݲ»Ö§³Ö
    int                 nReserved[8];
 
}MV_XML_FEATURE_EnumEntry;
 
 
typedef struct _MV_XML_FEATURE_Enumeration_
{
    enum MV_XML_Visibility       enVisivility;                       //ÊÇ·ñ¿É¼û
    char                    strDescription[MV_MAX_XML_DISC_STRLEN_C];//½ÚµãÃèÊö Ä¿Ç°Ôݲ»Ö§³Ö
    char                    strDisplayName[MV_MAX_XML_NODE_STRLEN_C];//ÏÔʾÃû³Æ
    char                    strName[MV_MAX_XML_NODE_STRLEN_C];  // ½ÚµãÃû
    char                    strToolTip[MV_MAX_XML_DISC_STRLEN_C];  //Ìáʾ
 
    int                 nSymbolicNum;          // SymbolicÊý
    char                strCurrentSymbolic[MV_MAX_XML_SYMBOLIC_STRLEN_C];          // µ±Ç°SymbolicË÷Òý
    char                strSymbolic[MV_MAX_XML_SYMBOLIC_NUM][MV_MAX_XML_SYMBOLIC_STRLEN_C];
    enum MV_XML_AccessMode   enAccessMode;       // ·ÃÎÊģʽ
    int                 bIsLocked;          // ÊÇ·ñËø¶¨¡£0-·ñ£»1-ÊÇ    Ä¿Ç°Ôݲ»Ö§³Ö
    int64_t             nValue;             // µ±Ç°Öµ
 
    unsigned int        nReserved[4];
}MV_XML_FEATURE_Enumeration;
 
 
typedef struct _MV_XML_FEATURE_Port_
{
    enum MV_XML_Visibility       enVisivility;                       //ÊÇ·ñ¿É¼û
    char                    strDescription[MV_MAX_XML_DISC_STRLEN_C];//½ÚµãÃèÊö Ä¿Ç°Ôݲ»Ö§³Ö
    char                    strDisplayName[MV_MAX_XML_NODE_STRLEN_C];//ÏÔʾÃû³Æ
    char                    strName[MV_MAX_XML_NODE_STRLEN_C];  // ½ÚµãÃû
    char                    strToolTip[MV_MAX_XML_DISC_STRLEN_C];  //Ìáʾ
 
    enum MV_XML_AccessMode       enAccessMode;       // ·ÃÎÊģʽ
    int                     bIsLocked;          // ÊÇ·ñËø¶¨¡£0-·ñ£»1-ÊÇ    Ä¿Ç°Ôݲ»Ö§³Ö
 
    unsigned int            nReserved[4];
}MV_XML_FEATURE_Port;
 
 
 
typedef struct _MV_XML_CAMERA_FEATURE_
{
    enum MV_XML_InterfaceType    enType;
    union
    {
        MV_XML_FEATURE_Integer      stIntegerFeature;
        MV_XML_FEATURE_Float        stFloatFeature;
        MV_XML_FEATURE_Enumeration  stEnumerationFeature;
        MV_XML_FEATURE_String       stStringFeature;
    }SpecialFeature;
 
}MV_XML_CAMERA_FEATURE;
 
 
typedef struct _MVCC_ENUMVALUE_T
{
    unsigned int    nCurValue;      // µ±Ç°Öµ
    unsigned int    nSupportedNum;  // Êý¾ÝµÄÓÐЧÊý¾Ý¸öÊý
    unsigned int    nSupportValue[MV_MAX_XML_SYMBOLIC_NUM];
 
    unsigned int    nReserved[4];
}MVCC_ENUMVALUE;
 
typedef struct _MVCC_INTVALUE_T
{
    unsigned int    nCurValue;      // µ±Ç°Öµ
    unsigned int    nMax;
    unsigned int    nMin;
    unsigned int    nInc;
 
    unsigned int    nReserved[4];
}MVCC_INTVALUE;
 
typedef struct _MVCC_FLOATVALUE_T
{
    float           fCurValue;      // µ±Ç°Öµ
    float           fMax;
    float           fMin;
 
    unsigned int    nReserved[4];
}MVCC_FLOATVALUE;
 
typedef struct _MVCC_STRINGVALUE_T
{
    char   chCurValue[256];      // µ±Ç°Öµ
 
    unsigned int    nReserved[4];
}MVCC_STRINGVALUE;
 
#endif /* _MV_CAMERA_PARAMS_H_ */