PGI Feature Set#
The main purpose of the PGI feature set is to optimize images to meet the needs of human vision. It combines up to four image optimization processes.
Using the Feature#
How it Works#
Depending on your camera model, a selection of the following image optimizations will be performed:
Noise Reduction#
The noise reduction (also called "denoising") reduces random variations in brightness or color information in your images.
Improved Sharpness#
This optimization increases the sharpness of the images. The higher the sharpness, the more distinct the contours of the image objects will be. This is especially useful in applications where cameras must correctly identify numbers or letters.
5×5 Demosaicing#
5×5 demosaicing (also called "debayering") carries out color interpolation on regions of 5×5 pixels on the sensor and is therefore more elaborate than the "simple" 2×2 demosaicing used otherwise by the camera.
Color Anti-Aliasing#
Color errors, especially on sharp edges and in sections of the image with high spatial frequencies, are a common side effect of demosaicing algorithms. Even colorless structures can suddenly appear to have color. The color anti-aliasing optimization analyzes and corrects the discolorations.
For more information about the PGI image optimizations, see the Better Image Quality with Basler PGI white paper.
Enabling the PGI Feature Set#
dart and pulse Cameras#
To enable the PGI image optimizations (if available) on Basler dart and pulse cameras:
- If your camera is a color camera, set the pixel format to a non-Bayer color pixel format, i.e., to one of the available RGB, BGR, or YUV pixel formats.
- If you want to manually configure noise reduction, set the PgiMode parameter to On_ManualNoiseReduction. You can now configure noise reduction and improved sharpness.
- If you want the noise reduction to be applied automatically, set the PgiMode parameter to On_AutomaticNoiseReduction. You can now configure improved sharpness.
ace Cameras#
To enable the PGI image optimizations (if available) on Basler ace cameras:
If your camera is a mono camera, set the PgiMode parameter to On.
If your camera is a color camera:
- Set the pixel format to a non-Bayer color pixel format, i.e., to one of the available RGB, BGR, or YUV pixel formats. On some camera models, the PGI feature set is only available for one of the YUV pixel formats.
- Set the DemosaicingMode parameter to BaslerPGI.
Setting the PGI Image Optimizations#
Once you have enabled the PGI feature set, you can configure the individual image optimization processes.
Which image optimizations are available and can be configured depends on your camera model.
Configuring Noise Reduction#
If this optimization is configurable, you can use the NoiseReduction parameter to specify the desired noise reduction. The higher the parameter value, the more noise reduction is applied.
If this optimization is not configurable, noise reduction is applied automatically.
Noise reduction is best used together with improved sharpness. If the parameter value is set too high, fine structure in the image can become indistinct or even disappear.
Configuring Improved Sharpness#
If this optimization is configurable, you can use the SharpnessEnhancement parameter to specify the desired level of sharpness. The higher the parameter value, the more sharpening is applied.
If this optimization is not configurable, sharpness is improved automatically.
In most cases, best results are obtained at low parameter value settings and when using noise reduction at the same time.
Configuring 5×5 Demosaicing#
If available, 5×5 demosaicing is performed automatically whenever the PGI feature set is enabled. You can't configure this optimization.
Configuring Color Anti-Aliasing#
If available, color anti-aliasing is performed automatically whenever the PGI feature set is enabled. You can't configure this optimization.
Specifics#
Camera Model | Available Image Optimizations | Configurable Image Optimizations |
---|---|---|
a2A1920-51gcBAS | PGI Feature Set not supported | None |
a2A1920-51gmBAS | PGI Feature Set not supported | None |
a2A1920-160ucBAS | PGI Feature Set not supported | None |
a2A1920-160umBAS | PGI Feature Set not supported | None |
acA640-90gc | PGI Feature Set not supported | None |
acA640-90gm | PGI Feature Set not supported | None |
acA640-90uc | PGI Feature Set not supported | None |
acA640-90um | PGI Feature Set not supported | None |
acA640-120gc | PGI Feature Set not supported | None |
acA640-120gm | PGI Feature Set not supported | None |
acA640-120uc | PGI Feature Set not supported | None |
acA640-120um | PGI Feature Set not supported | None |
acA640-121gm | Noise Reduction Improved Sharpness | Noise Reduction Improve Sharpness |
acA640-300gc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA640-300gm | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA640-750uc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA640-750um | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA720-290gc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA720-290gm | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA720-520uc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA720-520um | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA780-75gc | PGI Feature Set not supported | None |
acA780-75gm | PGI Feature Set not supported | None |
acA800-200gc | Noise Reduction Improved Sharpness 5*5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA800-200gm | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA800-510uc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA800-510um | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA1280-60gc | PGI Feature Set not supported | None |
acA1280-60gm | PGI Feature Set not supported | None |
acA1300-22gc | PGI Feature Set not supported | None |
acA1300-22gm | PGI Feature Set not supported | None |
acA1300-30gc | PGI Feature Set not supported | None |
acA1300-30gm | PGI Feature Set not supported | None |
acA1300-30uc | PGI Feature Set not supported | None |
acA1300-30um | PGI Feature Set not supported | None |
acA1300-60gc | PGI Feature Set not supported | None |
acA1300-60gm | PGI Feature Set not supported | None |
acA1300-60gmNIR | PGI Feature Set not supported | None |
acA1300-75gc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA1300-75gm | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA1300-200uc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA1300-200um | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA1440-73gc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA1440-73gm | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA1440-220uc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA1440-220um | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA1600-20gc | PGI Feature Set not supported | None |
acA1600-20gm | PGI Feature Set not supported | None |
acA1600-20uc | PGI Feature Set not supported | None |
acA1600-20um | PGI Feature Set not supported | None |
acA1600-60gc | PGI Feature Set not supported | None |
acA1600-60gm | PGI Feature Set not supported | None |
acA1920-25gc | PGI Feature Set not supported | None |
acA1920-25gm | PGI Feature Set not supported | None |
acA1920-25uc | PGI Feature Set not supported | None |
acA1920-25um | PGI Feature Set not supported | None |
acA1920-40gc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA1920-40gm | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA1920-40uc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA1920-40ucMED | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA1920-40um | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA1920-40umMED | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA1920-48gc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA1920-48gm | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA1920-50gc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA1920-50gm | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA1920-150uc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA1920-150um | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA1920-155uc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA1920-155ucMED | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA1920-155um | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA1920-155umMED | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA2000-50gc | PGI Feature Set not supported | None |
acA2000-50gm | PGI Feature Set not supported | None |
acA2000-50gmNIR | PGI Feature Set not supported | None |
acA2000-165uc | PGI Feature Set not supported | None |
acA2000-165um | PGI Feature Set not supported | None |
acA2000-165umNIR | PGI Feature Set not supported | None |
acA2040-25gc | PGI Feature Set not supported | None |
acA2040-25gm | PGI Feature Set not supported | None |
acA2040-25gmNIR | PGI Feature Set not supported | None |
acA2040-35gc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA2040-35gm | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA2040-55uc | Noise Reduction Improved Sharpness 5*5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA2040-55um | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA2040-90uc | PGI Feature Set not supported | None |
acA2040-90um | PGI Feature Set not supported | None |
acA2040-90umNIR | PGI Feature Set not supported | None |
acA2040-120uc | Noise Reduction Improved Sharpness 5*5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA2040-120um | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA2440-20gc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA2440-20gm | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA2440-35uc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA2440-35ucMED | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA2440-35um | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA2440-35umMED | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA2440-75uc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA2440-75ucMED | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA2440-75um | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA2440-75umMED | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA2500-14gc | PGI Feature Set not supported | None |
acA2500-14gm | PGI Feature Set not supported | None |
acA2500-14uc | PGI Feature Set not supported | None |
acA2500-14um | PGI Feature Set not supported | None |
acA2500-20gc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA2500-20gcMED | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA2500-20gm | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA2500-20gmMED | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA2500-60uc | Noise Reduction Improved Sharpness 5*5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA2500-60um | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA3088-16gc | Noise Reduction Improved Sharpness 5*5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA3088-16gm | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA3088-57uc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA3088-57um | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA3800-10gc | PGI Feature Set not supported | None |
acA3800-10gm | PGI Feature Set not supported | None |
acA3800-14uc | PGI Feature Set not supported | None |
acA3800-14um | PGI Feature Set not supported | None |
acA4024-8gc | Noise Reduction Improved Sharpness 5x5 Democaising Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA4024-8gm | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA4024-29uc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA4024-29um | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA4096-11gc | Noise Reduction Improved Sharpness 5*5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA4096-11gm | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA4096-30uc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA4096-30ucMED | Noise Reduction Improved Sharpness 5*5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA4096-30um | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA4096-30umMED | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA4096-40uc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA4096-40ucMED | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA4096-40um | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA4096-40umMED | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA4112-8gc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA4112-8gm | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA4112-20uc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA4112-20ucMED | Noise Reduction Improved Sharpness 5*5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA4112-20um | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA4112-20umMED | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA4112-30uc | Noise Reduction Improved Sharpness 5*5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA4112-30ucMED | Noise Reduction Improved Sharpness 5*5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA4112-30um | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA4112-30umMED | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA4600-7gc | PGI Feature Set not supported | None |
acA4600-10uc | PGI Feature Set not supported | None |
acA5472-5gc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA5472-5gm | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
acA5472-17uc | Noise Reduction Improved Sharpness 5x5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
acA5472-17um | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
boA4096-93cc | PGI Feature Set not supported | None |
boA4096-93cm | PGI Feature Set not supported | None |
boA4112-68cc | PGI Feature Set not supported | None |
boA4112-68cm | PGI Feature Set not supported | None |
daA1280-54lc | Noise Reduction Improved Sharpness 5*5 Demosaicing Color Anti-Aliasing | Noise Reduction Improved Sharpness |
daA1280-54lm | Noise Reduction Improved Sharpness | Noise Reduction[^a] Improved Sharpness[^b] |
daA1280-54uc | Noise Reduction Improved Sharpness 5*5 Demosaicing Color Anti-Aliasing | Noise Reduction[^a] Improved Sharpness[^b] |
daA1280-54um | Noise Reduction Improved Sharpness | Noise Reduction[^a] Improved Sharpness[^b] |
daA1600-60lc | Noise Reduction Improved Sharpness 5*5 Demosaicing Color Anti-Aliasing | Noise Reduction[^a] Improved Sharpness[^b] |
daA1600-60lm | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
daA1600-60uc | Noise Reduction Improved Sharpness 5*5 Demosaicing Color Anti-Aliasing | Noise Reduction[^a] Improved Sharpness[^b] |
daA1600-60um | Noise Reduction Improved Sharpness | Noise Reduction[^a] Improved Sharpness[^b] |
daA1920-15um | Noise Reduction Improved Sharpness | Noise Reduction[^a] Improved Sharpness[^b] |
daA1920-30uc | Noise Reduction Improved Sharpness 5*5 Demosaicing Color Anti-Aliasing | Noise Reduction[^a] Improved Sharpness[^b] |
daA1920-30um | Noise Reduction Improved Sharpness | Noise Reduction[^a] Improved Sharpness[^b] |
daA2500-14lc | Noise Reduction Improved Sharpness 5*5 Demosaicing Color Anti-Aliasing | Noise Reduction[^a] Improved Sharpness[^b] |
daA2500-14lm | Noise Reduction Improved Sharpness | Noise Reduction Improved Sharpness |
daA2500-14uc | Noise Reduction Improved Sharpness 5*5 Demosaicing Color Anti-Aliasing | Noise Reduction[^a] Improved Sharpness[^b] |
daA2500-14um | Noise Reduction Improved Sharpness | Noise Reduction[^a] Improved Sharpness[^b] |
daA2500-60mc | PGI Feature Set not supported | None |
puA1280-54uc | Noise Reduction Improved Sharpness 5*5 Demosaicing Color Anti-Aliasing | Noise Reduction[^a] Improved Sharpness[^b] |
puA1280-54um | Noise Reduction Improved Sharpness | Noise Reduction[^a] Improved Sharpness[^b] |
puA1600-60uc | Noise Reduction Improved Sharpness | Noise Reduction[^a] Improved Sharpness[^b] |
puA1600-60um | Noise Reduction Improved Sharpness | Noise Reduction[^a] Improved Sharpness[^b] |
puA1920-30uc | Noise Reduction Improved Sharpness 5*5 Demosaicing Color Anti-Aliasing | Noise Reduction[^a] Improved Sharpness[^b] |
puA1920-30um | Noise Reduction Improved Sharpness 5*5 Demosaicing Color Anti-Aliasing | Noise Reduction[^a] Improved Sharpness[^b] |
puA2500-14uc | Noise Reduction Improved Sharpness 5*5 Demosaicing Color Anti-Aliasing | Noise Reduction[^a] Improved Sharpness[^b] |
puA2500-14um | Noise Reduction Improved Sharpness | Noise Reduction[^a] Improved Sharpness[^b] |
Sample Code#
dart and pulse Cameras#
// Enable the PGI feature set with manual noise reduction camera.PgiMode.SetValue(PgiMode_Manual); // Configure noise reduction camera.NoiseReduction.SetValue(0.2); // Configure improved sharpness camera.SharpnessEnhancement.SetValue(1.0);
INodeMap& nodemap = camera.GetNodeMap(); // Enable the PGI feature set with manual noise reduction CEnumerationPtr(nodemap.GetNode("PgiMode"))->FromString("Manual"); // Configure noise reduction CFloatPtr(nodemap.GetNode("NoiseReduction"))->SetValue(0.2); // Configure improved sharpness CFloatPtr(nodemap.GetNode("SharpnessEnhancement"))->SetValue(1.0);
INodeMap& nodemap = camera.GetNodeMap(); // Enable the PGI feature set with manual noise reduction CEnumParameter(nodemap, "PgiMode").SetValue("Manual"); // Configure noise reduction CFloatParameter(nodemap, "NoiseReduction").SetValue(0.2); // Configure improved sharpness CFloatParameter(nodemap, "SharpnessEnhancement").SetValue(1.0);
// Enable the PGI feature set with manual noise reduction camera.Parameters[PLCamera.PgiMode].SetValue(PLCamera.PgiMode.Manual); // Configure noise reduction camera.Parameters[PLCamera.NoiseReduction].SetValue(0.2); // Configure improved sharpness camera.Parameters[PLCamera.SharpnessEnhancement].SetValue(1.0);
// Enable the PGI feature set with manual noise reduction Pylon.DeviceFeatureFromString(hdev, "PgiMode", "Manual"); // Configure noise reduction Pylon.DeviceSetFloatFeature(hdev, "NoiseReduction", 0.2); // Configure improved sharpness Pylon.DeviceSetFloatFeature(hdev, "SharpnessEnhancement", 1.0);
/* Macro to check for errors */ #define CHECK(errc) if (GENAPI_E_OK != errc) printErrorAndExit(errc) GENAPIC_RESULT errRes = GENAPI_E_OK; /* Return value of pylon methods */ /* Enable the PGI feature set with manual noise reduction */ errRes = PylonDeviceFeatureFromString(hdev, "PgiMode", "Manual"); CHECK(errRes); /* Configure noise reduction */ errRes = PylonDeviceSetFloatFeature(hdev, "NoiseReduction", 0.2); CHECK(errRes); /* Configure improved sharpness */ errRes = PylonDeviceSetFloatFeature(hdev, "SharpnessEnhancement", 1.0); CHECK(errRes);
ace classic/U/L USB 3.0 Cameras#
// Enable the PGI feature set (mono cameras only) camera.PgiMode.SetValue(PgiMode_On); // Enable the PGI feature set (color cameras only) camera.DemosaicingMode.SetValue(DemosaicingMode_BaslerPGI); // Configure noise reduction (if available) camera.NoiseReduction.SetValue(0.2); // Configure improved sharpness (if available) camera.SharpnessEnhancement.SetValue(1.0);
INodeMap& nodemap = camera.GetNodeMap(); // Enable the PGI feature set (mono cameras only) CEnumerationPtr(nodemap.GetNode("PgiMode"))->FromString("On"); // Enable the PGI feature set (color cameras only) CEnumerationPtr(nodemap.GetNode("DemosaicingMode"))->FromString("BaslerPGI"); // Configure noise reduction (if available) CFloatPtr(nodemap.GetNode("NoiseReduction"))->SetValue(0.2); // Configure improved sharpness (if available) CFloatPtr(nodemap.GetNode("SharpnessEnhancement"))->SetValue(1.0);
INodeMap& nodemap = camera.GetNodeMap(); // Enable the PGI feature set (mono cameras only) CEnumParameter(nodemap, "PgiMode").SetValue("On"); // Enable the PGI feature set (color cameras only) CEnumParameter(nodemap, "DemosaicingMode").SetValue("BaslerPGI"); // Configure noise reduction (if available) CFloatParameter(nodemap, "NoiseReduction").SetValue(0.2); // Configure improved sharpness (if available) CFloatParameter(nodemap, "SharpnessEnhancement").SetValue(1.0);
// Enable the PGI feature set (mono cameras only) camera.Parameters[PLCamera.PgiMode].SetValue(PLCamera.PgiMode.On); // Enable the PGI feature set (color cameras only) camera.Parameters[PLCamera.DemosaicingMode].SetValue(PLCamera.DemosaicingMode.BaslerPGI); // Configure noise reduction (if available) camera.Parameters[PLCamera.NoiseReduction].SetValue(0.2); // Configure improved sharpness (if available) camera.Parameters[PLCamera.SharpnessEnhancement].SetValue(1.0);
// Enable the PGI feature set (mono cameras only) Pylon.DeviceFeatureFromString(hdev, "PgiMode", "On"); // Enable the PGI feature set (color cameras only) Pylon.DeviceFeatureFromString(hdev, "DemosaicingMode", "BaslerPGI"); // Configure noise reduction (if available) Pylon.DeviceSetFloatFeature(hdev, "NoiseReduction", 0.2); // Configure improved sharpness (if available) Pylon.DeviceSetFloatFeature(hdev, "SharpnessEnhancement", 1.0);
/* Macro to check for errors */ #define CHECK(errc) if (GENAPI_E_OK != errc) printErrorAndExit(errc) GENAPIC_RESULT errRes = GENAPI_E_OK; /* Return value of pylon methods */ /* Enable the PGI feature set (mono cameras only) */ errRes = PylonDeviceFeatureFromString(hdev, "PgiMode", "On"); CHECK(errRes); /* Enable the PGI feature set (color cameras only) */ errRes = PylonDeviceFeatureFromString(hdev, "DemosaicingMode", "BaslerPGI"); CHECK(errRes); /* Configure noise reduction (if available) */ errRes = PylonDeviceSetFloatFeature(hdev, "NoiseReduction", 0.2); CHECK(errRes); /* Configure improved sharpness (if available) */ errRes = PylonDeviceSetFloatFeature(hdev, "SharpnessEnhancement", 1.0); CHECK(errRes);
ace classic/U/L GigE Cameras#
// Enable the PGI feature set (mono cameras only) camera.PgiMode.SetValue(PgiMode_On); // Enable the PGI feature set (color cameras only) camera.DemosaicingMode.SetValue(DemosaicingMode_BaslerPGI); // Configure noise reduction (if available) camera.NoiseReductionAbs.SetValue(0.2); // Configure improved sharpness (if available) camera.SharpnessEnhancementAbs.SetValue(1.0);
INodeMap& nodemap = camera.GetNodeMap(); // Enable the PGI feature set (mono cameras only) CEnumerationPtr(nodemap.GetNode("PgiMode"))->FromString("On"); // Enable the PGI feature set (color cameras only) CEnumerationPtr(nodemap.GetNode("DemosaicingMode"))->FromString("BaslerPGI"); // Configure noise reduction (if available) CFloatPtr(nodemap.GetNode("NoiseReductionAbs"))->SetValue(0.2); // Configure improved sharpness (if available) CFloatPtr(nodemap.GetNode("SharpnessEnhancementAbs"))->SetValue(1.0);
INodeMap& nodemap = camera.GetNodeMap(); // Enable the PGI feature set (mono cameras only) CEnumParameter(nodemap, "PgiMode").SetValue("On"); // Enable the PGI feature set (color cameras only) CEnumParameter(nodemap, "DemosaicingMode").SetValue("BaslerPGI"); // Configure noise reduction (if available) CFloatParameter(nodemap, "NoiseReductionAbs").SetValue(0.2); // Configure improved sharpness (if available) CFloatParameter(nodemap, "SharpnessEnhancementAbs").SetValue(1.0);
// Enable the PGI feature set (mono cameras only) camera.Parameters[PLCamera.PgiMode].SetValue(PLCamera.PgiMode.On); // Enable the PGI feature set (color cameras only) camera.Parameters[PLCamera.DemosaicingMode].SetValue(PLCamera.DemosaicingMode.BaslerPGI); // Configure noise reduction (if available) camera.Parameters[PLCamera.NoiseReductionAbs].SetValue(0.2); // Configure improved sharpness (if available) camera.Parameters[PLCamera.SharpnessEnhancementAbs].SetValue(1.0);
// Enable the PGI feature set (mono cameras only) Pylon.DeviceFeatureFromString(hdev, "PgiMode", "On"); // Enable the PGI feature set (color cameras only) Pylon.DeviceFeatureFromString(hdev, "DemosaicingMode", "BaslerPGI"); // Configure noise reduction (if available) Pylon.DeviceSetFloatFeature(hdev, "NoiseReductionAbs", 0.2); // Configure improved sharpness (if available) Pylon.DeviceSetFloatFeature(hdev, "SharpnessEnhancementAbs", 1.0);
/* Macro to check for errors */ #define CHECK(errc) if (GENAPI_E_OK != errc) printErrorAndExit(errc) GENAPIC_RESULT errRes = GENAPI_E_OK; /* Return value of pylon methods */ /* Enable the PGI feature set (mono cameras only) */ errRes = PylonDeviceFeatureFromString(hdev, "PgiMode", "On"); CHECK(errRes); /* Enable the PGI feature set (color cameras only) */ errRes = PylonDeviceFeatureFromString(hdev, "DemosaicingMode", "BaslerPGI"); CHECK(errRes); /* Configure noise reduction (if available) */ errRes = PylonDeviceSetFloatFeature(hdev, "NoiseReductionAbs", 0.2); CHECK(errRes); /* Configure improved sharpness (if available) */ errRes = PylonDeviceSetFloatFeature(hdev, "SharpnessEnhancementAbs", 1.0); CHECK(errRes);
You can also use the pylon Viewer to easily set the parameters.