0% found this document useful (0 votes)
28 views24 pages

Samples Manual

Displays the related parameter information of the camera, such as the camera model, serial number, etc. 2.3. Precautions  The sample code is only for reference, and the specific operation needs to be modified according to the actual device.  The trigger mode and related parameters need to be set according to the actual device.  The image display and saving path need to be modified according to the actual environment.  For monochrome cameras, the image data is 8-bit grayscale data, and the pixel format is PixelFormatMono8. China Daheng Group, Inc. Beijing Image Vision Technology Branch 2 3
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
28 views24 pages

Samples Manual

Displays the related parameter information of the camera, such as the camera model, serial number, etc. 2.3. Precautions  The sample code is only for reference, and the specific operation needs to be modified according to the actual device.  The trigger mode and related parameters need to be set according to the actual device.  The image display and saving path need to be modified according to the actual environment.  For monochrome cameras, the image data is 8-bit grayscale data, and the pixel format is PixelFormatMono8. China Daheng Group, Inc. Beijing Image Vision Technology Branch 2 3
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 24

China Daheng Group, Inc.

Beijing Image Vision Technology Branch

Samples Manual

Version:V1.1.3
Date:2017-01-18
Notice

All rights reserved. No parts of this manual may be used or reproduced, in any forms or by any means,
without prior written permission of China Daheng Group, Inc. Beijing Image Vision Technology Branch.

The right is also reserved to modify or change any parts of this manual in the future without prior
notification.

All other trademarks are the properties of their respective owners.

© 2020 China Daheng Group, Inc. Beijing Image Vision Technology Branch
Web: http://www.daheng-imaging.com
Sales Email: isales@daheng-imaging.com
Sales Tel: +86 10 8282 8878
Support Email: isupport@daheng-imaging.com
Contents
1. Introduction ..................................................................................................................... 1
2. GxSingleCamMono ......................................................................................................... 2
2.1. Function introduction ................................................................................................2
2.2. UI Interface ...............................................................................................................2
2.3. Precautions ..............................................................................................................2
3. GxSingleCamColor ......................................................................................................... 3
3.1. Function introduction ................................................................................................3
3.2. UI Interface ...............................................................................................................3
3.3. Precautions ..............................................................................................................3
4. GxMultiCam ..................................................................................................................... 5
4.1. Function introduction ................................................................................................5
4.2. UI Interface ...............................................................................................................5
4.3. Precautions ..............................................................................................................6
5. GxGetImage .................................................................................................................... 7
5.1. Function introduction ................................................................................................7
5.2. UI Interface ...............................................................................................................7
5.3. Precautions ..............................................................................................................7
6. GxIOSample .................................................................................................................... 8
6.1. Function introduction ................................................................................................8
6.2. UI Interface ...............................................................................................................8
6.3. Precautions ..............................................................................................................8
7. GxStoreAVI ...................................................................................................................... 9
7.1. Function introduction ................................................................................................9
7.2. UI Interface ...............................................................................................................9
7.3. Precautions ..............................................................................................................9
8. GxAutoFuncCtrl ............................................................................................................. 11
8.1. Function introduction .............................................................................................. 11
8.2. UI Interface ............................................................................................................. 11
8.3. Precautions ............................................................................................................ 11
9. GxUSBSnapPnp ............................................................................................................ 12
9.1. Function introduction ..............................................................................................12
9.2. UI Interface .............................................................................................................12
9.3. Precautions ............................................................................................................12
10. GxViewer ..................................................................................................................... 13
10.1. Function introduction ............................................................................................13
10.2. UI Interface ...........................................................................................................13
10.3. Precautions ..........................................................................................................13
11. GxSnapRaw16 ............................................................................................................. 14
11.1. Function introduction ............................................................................................14
11.2. UI Interface ...........................................................................................................14
11.3. Precautions ...........................................................................................................14
12. GxCameraEvents ........................................................................................................ 15
12.1. Function introduction ............................................................................................15
12.2. UI Interface ...........................................................................................................15
12.3. Precautions ..........................................................................................................15
13. GxGigeRecovery ......................................................................................................... 16
13.1. Function introduction ............................................................................................16
13.2. UI Interface ...........................................................................................................16
13.3. Precautions ..........................................................................................................16
14. GxImageProcess......................................................................................................... 17
14.1. Function introduction ............................................................................................17
14.2. UI Interface ...........................................................................................................17
14.3. Precautions ..........................................................................................................18
15. GxTransferDelay ......................................................................................................... 19
15.1. Function introduction ............................................................................................19
15.2. UI Interface ...........................................................................................................19
15.3. Precautions ..........................................................................................................19
16. Revision History ......................................................................................................... 20
1.Introduction

1. Introduction
In this samples manual, the demos of samples are for some type of the cameras, which cannot cover the
operation of all models. The parameter information on the interface after the programs runs is only used
as the user's reference, and the specific parameter information is based on the device that the user
actually opens.

China Daheng Group, Inc. Beijing Image Vision Technology Branch 1


2.GxSingleCamMono

2. GxSingleCamMono
2.1. Function introduction
The GxSingleCamMono is the sample written for monochrome camera, the program code mainly
demonstrates how to allocate the buffers, images display, processing images, and save the image data
into a bmp file for the monochrome images.

2.2. UI Interface
 Demonstration process demo

Figure 2-1 GxSingleCamMono demonstration process demo

 Parameter description

Trigger Control: Demonstrates how to set the related parameter in trigger mode, and the trigger control
function is valid only when the trigger mode is On.

Save Image: Demonstrates the process how to save the monochrome image data into a bmp file, and the
bmp file is named with the system time that the image saved, the specific format is
"year_month_day_hour_minute_second_millisecond.bmp".

Basic Parameter: Demonstrates how to adjust the exposure time/gain.

2.3. Precautions
 The image is saved in the GxSingleCamMonoImages folder which is in the same level directory as
the executable program. The folder is created by the program automatically, and the folder name and
the path cannot be modified manually.
 When saving the images, the program will not detect the disk space where the storage path is located,
so when the storage space is full, it will only generate the 0kB size BMP empty file.
 When compiling in VS2005 development platform, prompt "manifest authoring warning 81010002:
Unrecognized Element "requestedPrivileges" in namespace "urn:schemas-microsoft-com:asm.v3"."
warning information, this is because of adding the manifest administrator identity, there is no effect.

China Daheng Group, Inc. Beijing Image Vision Technology Branch 2


3.GxSingleCamColor

3. GxSingleCamColor
3.1. Function introduction
And corresponding to the GxSingleCamMono, the GxSingleCamColor is written for the color cameras.
The program code demonstrates how to allocate the buffers, images display, image RGB conversion,
image quality improvement, automatic and manual white balance adjustment, and save the image data
into a bmp file for the color images.

3.2. UI Interface
 Demonstration process demo

Figure 3-1 GxSingleCamColor Demonstration process demo

 Parameter description

White Balance Adjustment: Demonstrates how to adjust the white balance manually/ automatically. The
manual adjustment is effective by setting the white balance channel and the white balance coefficient.

Image Quality Improvement: Demonstrates how to improve the image quality. And the image quality is
best when cooperated with the white balance adjustment function.

Trigger Control: Demonstrates how to set the related parameter in trigger mode, and the trigger control
function is valid only when the trigger mode is On.

Save Image: Demonstrates the process how to save the color image data which has been a RGB
conversion into a bmp file, and the bmp file is named with the system time that the image saved, the
specific format is "year_month_day_hour_minute_second_millisecond.bmp".

Basic Parameter: Demonstrates how to adjust the exposure time/ gain.

3.3. Precautions
 The image is saved in the GxSingleCamColorImages folder which is in the same level directory as
the executable program. The folder is created by the program automatically, and the folder name and
the path cannot be modified manually.

China Daheng Group, Inc. Beijing Image Vision Technology Branch 3


3.GxSingleCamColor

 When saving the images, the program will not detect the disk space where the storage path is located,
so when the storage space is full, it will only generate the 0kB size BMP empty file.
 When compiling in VS2005 development platform, prompt "manifest authoring warning 81010002:
Unrecognized Element "requestedPrivileges" in namespace "urn: schemas-microsoft-com: asm.v3"."
warning information, this is because of adding the manifest administrator identity, there is no effect.

China Daheng Group, Inc. Beijing Image Vision Technology Branch 4


4.GxMultiCam

4. GxMultiCam
4.1. Function introduction
The GxMultiCam sample mainly demonstrates how to capture, process, and display images with multiple
cameras simultaneously. This sample supports up to four cameras at the same time.

4.2. UI Interface
 Demonstration process demo

Figure 4-1 Four cameras capture simultaneously demonstration demo

Figure 4-2 Parameter setting

 Parameter description

Acquisition speed level: Demonstrates how to set the acquisition speed level, multiple cameras capture at
the same time may be affected by the PC performance, leading to a camera cannot output images, and
the display frame rate is 0.0fps, in this case, you can try to reduce the acquisition speed level and reduce
the acquisition frame rate, in order to let all the cameras output images.

Exposure/Gain: Demonstrates how to adjust exposure time/ gain parameters.

White Balance: Demonstrates how to set auto white balance function.

China Daheng Group, Inc. Beijing Image Vision Technology Branch 5


4.GxMultiCam

4.3. Precautions
 When compiling in VS2005/VS2008/VS2010 development platform, prompt "warning C4996: 'itoa'
was declared deprecated", if you replace the function itoa as _itoa_s, the message will not occur.
Because the VC6.0 development platform does not support the _itoa_s function, so it is unchanged
and has no effect.
 When compiling in VS2005 development platform, prompt "manifest authoring warning 81010002:
Unrecognized Element "requestedPrivileges" in namespace "urn: schemas-microsoft-com: asm.v3"."
warning information, this is because of adding the manifest administrator identity, there is no effect.

China Daheng Group, Inc. Beijing Image Vision Technology Branch 6


5.GxGetImage

5. GxGetImage
5.1. Function introduction
This sample mainly demonstrates the way to call the GxGetImage interface to get the image: send a
software trigger and call the GxGetImage (you need to enter waiting time) to get an image. Note that the
way to call the GxGetImage interface for images cannot be the same way as to call callback acquisition,
and the GX_STATUS_INVALID_CALL error will be returned if the GXGetImage interface is called after the
callback is registered.

5.2. UI Interface
 Demonstration process demo

Figure 5-1 GxGetImage demonstrate process demo

 Parameter description

Timeout Time: By calling the GxGetImage interface to get the maximum waiting time.

Time Statistical: The statistical time is the time interval between sending software trigger command and
calling the GetImage interface to get the images, and the maximum value, minimum value and mean
value are calculated according to the recorded data.

5.3. Precautions
 When compiling in VS2005 development platform, prompt "manifest authoring warning 81010002:
Unrecognized Element "requestedPrivileges" in namespace "urn: schemas-microsoft-com: asm.v3"."
warning information, this is because of adding the manifest administrator identity, there is no effect.

China Daheng Group, Inc. Beijing Image Vision Technology Branch 7


6.GxIOSample

6. GxIOSample
6.1. Function introduction
The GxIOSample sample mainly demonstrates the setting process of basic parameters such as trigger
acquisition function, IO control function, and exposure/gain.

6.2. UI Interface
 Demonstration process demo

Figure 6-1 GxIOSample demonstrate process demo

 Parameter description

Trigger Control: Demonstrates how to set the related parameter in trigger mode, and the trigger control
function is valid only when the trigger mode is On.

Basic Parameter: Demonstrates how to adjust the exposure time/ gain.

Output Control: Demonstrates how to set the related parameters of output control, where the user-defined
output value is true for high level and false for low level.

6.3. Precautions
 When compiling in VS2005 development platform, prompt "manifest authoring warning 81010002:
Unrecognized Element "requestedPrivileges" in namespace "urn: schemas-microsoft-com: asm.v3"."
warning information, this is because of adding the manifest administrator identity, there is no effect.

China Daheng Group, Inc. Beijing Image Vision Technology Branch 8


7.GxStoreAVI

7. GxStoreAVI
7.1. Function introduction
The GxStoreAVI sample mainly demonstrates how to save the AVI video stream by means of
compression and non-compression mode. To save the AVI video stream by the compression mode, you
need to choose the video compressor. The sample also demonstrates how to select the video encoder.

7.2. UI Interface
 Demonstration process demo

Figure 7-1 GxStoreAVI sample demonstrate process demo

 Parameter description

Open Device: The operation simultaneously performs the opening the device, registering the callback
function and starting the acquisition process.

Start Recording: After starting recording is successful, the operation of writing AVI Video files is executed
in the callback function.

Broadcast frame rate: This parameter is used to set the broadcast frame rate of the AVI video, which is
recommended to match the frame rate of the current camera connected.

Storage Path: The AVI video is saved by default in the current directory of the executable program, if you
want to modify the storage directory, you can click the path modified button " " before recording.

Storage Name: The AVI video file is named with system time that the video obtained, and the specific
format is "year_month_day_hour_minute_second_millisecond.avi".

7.3. Precautions
 When storage in the compression mode, if selecting video encoder failure or starting recording failure,
you can try to choose other video encoder. The color camera is recommended to use the "DIVX"
video encoder and the monochrome camera is recommended to use "Indeo video 5.10" encoder.
 During the recording process, the program storage the AVI file by the unit of 2GB/block.

China Daheng Group, Inc. Beijing Image Vision Technology Branch 9


7.GxStoreAVI

 During the AVI video saving process, the application will detect the store path of disk space, when the
free disk space is not enough to save the AVI video, the program will automatically stop recording.
 When compiling in VS2005 development platform, prompt "manifest authoring warning 81010002:
Unrecognized Element "requestedPrivileges" in namespace "urn: schemas-microsoft-com: asm.v3"."
warning information, this is because of adding the manifest administrator identity, there is no effect.

China Daheng Group, Inc. Beijing Image Vision Technology Branch 10


8.GxAutoFuncCtrl

8. GxAutoFuncCtrl
8.1. Function introduction
The GxAutoFuncCtrl sample mainly demonstrates the exposure adjustment (manual/automatic), gain
adjustment (manual/automatic), and the 2A ROI, expect gray value, 2A lighting environment functions
settings that are related to automatic gain/automatic exposure adjustment.

8.2. UI Interface
 Demonstration process demo

Figure 8-1 GxAutoFuncCtrl demonstration process demo

 Parameter description

2A ROI: Demonstrates how to set the range of statistical area, and the range is a statistical area for the
calculation of automatic functions.

Gain Adjustment: Demonstrates how to adjust the gain manually or automatically.

Exposure Adjustment: Demonstrates how to adjust the exposure time manually or automatically.

Expected gray value: Demonstrates how to set the gray value. The value is a benchmark parameter of
automatic exposure and automatic gain adjustment, and the final expectation of automatic function
adjustment is to meet the desired gray value of the user set.

2A lighting environment: Demonstrates how to set the external lighting environment, and when the
automatic function adjustment is enable, it will adapt to adjust according to the light environment.

8.3. Precautions
 When compiling in VS2005 development platform, prompt "manifest authoring warning 81010002:
Unrecognized Element "requestedPrivileges" in namespace "urn: schemas-microsoft-com: asm.v3"."
warning information, this is because of adding the manifest administrator identity, there is no effect.

China Daheng Group, Inc. Beijing Image Vision Technology Branch 11


9.GxUSBSnapPnp

9. GxUSBSnapPnp
9.1. Function introduction
The GxUSBSnapPnp sample is mainly demonstrates how to detect the camera’s hot plug state, the
implementation principle is according to the captured windows message WM_DEVICECHANGE of the
windows, by judging the message parameter and selecting the plug in or pull out message of the
registered device. The GxUSBSnapPnp sample behavior is that when a device is detected plug in or pull
out, it again enumerates the device and update the list of devices displayed on the interface, and the
interface only shows the current connected device information.

9.2. UI Interface
 Demonstration process demo

Figure 9-1 GxUSBSnapPnp interface

 Parameter description

Name: When connecting the device, the name column displays the device model and serial number
information.

9.3. Precautions
 When compiling in VS2005 development platform, prompt "manifest authoring warning 81010002:
Unrecognized Element "requestedPrivileges" in namespace "urn: schemas-microsoft-com: asm.v3"."
warning information, this is because of adding the manifest administrator identity, there is no effect.
 When the camera is continuously plugged in or pulled out, it is necessary to wait for the device to be
stable before the next plug in / pull out operation, in which the device manager will no longer refresh
the operation indicating that the device has been stable.

China Daheng Group, Inc. Beijing Image Vision Technology Branch 12


10.GxViewer

10. GxViewer
10.1. Function introduction
The GxViewer sample is mainly demonstrates the capture, processing and display functions of the 8-bit
images in the form of a single document.

10.2. UI Interface
 Demonstration process demo

Figure 10-1 GxViewer demonstration process demo

 Parameter description

Not have.

10.3. Precautions
 When compiling in VS2005 development platform, prompt "manifest authoring warning 81010002:
Unrecognized Element "requestedPrivileges" in namespace "urn: schemas-microsoft-com: asm.v3"."
warning information, this is because of adding the manifest administrator identity, there is no effect.

China Daheng Group, Inc. Beijing Image Vision Technology Branch 13


11.GxSnapRaw16

11. GxSnapRaw16
11.1. Function introduction
The GxSnapRaw16 sample is mainly demonstrates the capture, processing, and display functions of the
non 8-bit images and the process of how to save the image data to a raw file.

11.2. UI Interface
 Demonstration process demo

Figure 11-1 GxSnapRaw16 demonstration process demo

 Parameter description

Save Image: Demonstrates the process how to save the non-8bit image data which output by the camera
into a Raw file, and the Raw file is named with the system time that the image saved, the specific format is
"year_month_day_hour_minute_second_millisecond.raw".

11.3. Precautions
 The image is saved in the GxSnapRaw16Images folder which is in the same level directory as the
executable program. The folder is created by the program automatically, and the folder name and the
path cannot be modified manually.
 When saving the images, the program will not detect the disk space where the storage path is located,
so when the storage space is full, it will only generate the 0kB size BMP empty file.
 When compiling in VS2005 development platform, prompt "manifest authoring warning 81010002:
Unrecognized Element "requestedPrivileges" in namespace "urn: schemas-microsoft-com: asm.v3"."
warning information, this is because of adding the manifest administrator identity, there is no effect.

China Daheng Group, Inc. Beijing Image Vision Technology Branch 14


12.GxCameraEvents

12. GxCameraEvents
12.1. Function introduction
The GXCameraEvents sample mainly demonstrates the exposure end event in software trigger mode.

12.2. UI Interface
 Demonstration process demo

Figure 12-1 GXCameraEvents demonstration process demo

 Parameter description

Record the time: Record the time when sending the software trigger command, the time between sending
software trigger command and the exposure end event, and the time between sending software trigger
command and receiving the image successfully.

12.3. Precautions
 When compiling in VS2005 development platform, prompt "manifest authoring warning 81010002:
Unrecognized Element "requestedPrivileges" in namespace "urn: schemas-microsoft-com: asm.v3"."
warning information, this is because of adding the manifest administrator identity, there is no effect.

China Daheng Group, Inc. Beijing Image Vision Technology Branch 15


13.GxGigeRecovery

13. GxGigeRecovery
13.1. Function introduction
The GxGigeRecovery sample demonstrates the process of camera offline and reconnection, and the
import and export of configuration file.

13.2. UI Interface
 Demonstration process demo

Figure 13-1 GxGigeRecovery demonstration process demo

 Parameter description
Not have.

13.3. Precautions
 When compiling in VS2005 development platform, prompt "manifest authoring warning 81010002:
Unrecognized Element "requestedPrivileges" in namespace "urn: schemas-microsoft-com: asm.v3"."
warning information, this is because of adding the manifest administrator identity, there is no effect.

China Daheng Group, Inc. Beijing Image Vision Technology Branch 16


14.GxImageProcess

14. GxImageProcess
14.1. Function introduction
The GxImageProcess sample demonstrates the use of image integrated processing functions for color
cameras.

14.2. UI Interface
 Demonstration process demo

Figure 14-1 GxImageProcess demonstration process demo

 Parameter description

Automatic White Balance: Demonstrates how to set the automatic white balance function.

Automatic White Balance light source: Demonstrates how to set the automatic white balance light source.

Algorithm Acceleration: Demonstrates how to operate the algorithm acceleration.

Color Correction: Demonstrates how to operate the color correction.

Bad Pixel Correction: Demonstrates how to operate the bad pixel correction.

Image Denoise: Demonstrates how to reduce the noise of the image.

Sharpness: Demonstrates how to make sharpening adjustment.

Gamma: Demonstrates how to make Gamma adjustment.

Contrast: Demonstrates how to make contrast adjustment.

Brightness: Demonstrates how to make brightness adjustment.

Saturability: Demonstrates how to make saturability adjustment.

China Daheng Group, Inc. Beijing Image Vision Technology Branch 17


14.GxImageProcess

14.3. Precautions
 When compiling in VS2005 development platform, prompt "manifest authoring warning 81010002:
Unrecognized Element "requestedPrivileges" in namespace "urn: schemas-microsoft-com: asm.v3"."
warning information, due to add the manifest administrator identity, there is no effect.

China Daheng Group, Inc. Beijing Image Vision Technology Branch 18


15.GxTransferDelay

15. GxTransferDelay
15.1. Function introduction
The GxTransferDelay sample mainly demonstrates the transmission delay function of four cameras in
trigger mode.

15.2. UI Interface
 Demonstration process demo

Figure 15-1 GxTransferDelay demonstration process demo

 Parameter description
Not have.

15.3. Precautions
 There must to connect four cameras simultaneously, the sample can be run successfully.
 When compiling in VS2005 development platform, prompt "manifest authoring warning 81010002:
Unrecognized Element "requestedPrivileges" in namespace "urn: schemas-microsoft-com: asm.v3"."
warning information, this is because of adding the manifest administrator identity, there is no effect.

China Daheng Group, Inc. Beijing Image Vision Technology Branch 19


16.Revision History

16. Revision History


No. Version Changes Date

1 V1.0.1 Initial release 2013-06-09

2 V1.0.7 Modify the GxMutiCam sample program 2014-02-17

3 V1.0.8 Add the sample program 2014-12-03

Delete the description section of GxGigeSetPersistent


4 V1.1.3 2017-01-18
sample program

China Daheng Group, Inc. Beijing Image Vision Technology Branch 20

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy