Skip to content

Stacked ROI#

The Stacked ROI camera feature allows you to define multiple zones of varying heights and equal width on the sensor array that will be transmitted as a single image.

Only the pixel data from those zones will be transmitted. This increases the camera's frame rate.

The Stacked ROI feature is similar to the Stacked Zone Imaging feature, which is only available on ace Classic cameras.

Using the Feature#

How It Works#

The Stacked ROI feature allows you to define vertically aligned zones of equal width on the sensor array. The maximum number of zones depends on your camera model.

When an image is acquired, only the pixel information from within the defined zones is read out of the sensor. The pixel information is then stacked together and transmitted as a single image.

ROI Zones Example

The zones always have the same width and are vertically aligned. To configure the zones, Basler recommends the following procedure:

  1. Define a width and a horizontal offset that is valid for all zones.
  2. Define the heights and vertical offsets of the individual zones.

Configuring the ROI Zones#

  1. Make sure the camera is idle, i.e., not capturing images.
  2. Set the OffsetX parameter to the desired horizontal offset. The value is applied to all zones.
  3. Set the Width parameter to the desired zone width. The value is applied to all zones.
  4. Set the ROIZoneSelector parameter to the zone that you want to configure, e.g., Zone0.
  5. Set the ROIZoneOffset parameter to the desired vertical offset. The value is applied to the zone selected in step 4.
  6. Set the ROIZoneSize parameter to the desired zone height. The value is applied to the zone selected in step 4.
  7. Set the ROIZoneMode parameter to On to enable the zone.
  8. Repeat steps 4 to 7 for every zone you want to configure.

Considerations When Using the Stacked ROI Feature#

  • You can enable the zones in any order you like. For example, you can enable zones 1, 3, and 5 and disable zones 0, 2, and 4.
  • You can place the zones freely around the sensor. For example, you can place zone 0 near the bottom, zone 2 near the top, and zone 1 in the middle. However, the camera always starts reading out and transmitting pixel data from the topmost zone on the sensor and then proceeds towards the bottom.
  • You can define vertically overlapping zones. If two zones overlap, they are transmitted as a single merged zone. The pixel data from the area of overlap is read out and transmitted only once.
  • When at least one zone has been defined, the following parameters become read-only:
    • OffsetY: The parameter is set to the vertical offset of the topmost zone.
    • Height: The parameter is set to the height of the final image, i.e., the sum of the heights of all zones.
    • CenterY
    • All parameters related to the Sequencer feature.
  • If you have configured a zone and then enable binning, the position and the size of the zone are adapted automatically. The parameter values are divided by the corresponding binning factor and rounded down.
  • If you disable all zones after using the Stacked ROI feature, the size and position of the image ROI is set to the size and position of the zone that was disabled last. For example, assume zones 0, 1, and 2 are enabled. Then, you disable the zones in the following order: 2, 1, 0. As a result, the size and position of the image ROI is set to the size and position of the disabled zone 0.

Specifics#

Show all camera models

Camera Model Maximum Number of ROI Zones
a2A640-240gmSWIR Stacked ROI feature not supported
a2A640-240umSWIR Stacked ROI feature not supported
a2A1280-80gmSWIR Stacked ROI feature not supported
a2A1280-125umSWIR Stacked ROI feature not supported
a2A1920-51gcBAS Stacked ROI feature not supported
a2A1920-51gcPRO Stacked ROI feature not supported
a2A1920-51gmBAS Stacked ROI feature not supported
a2A1920-51gmPRO Stacked ROI feature not supported
a2A1920-160ucBAS Stacked ROI feature not supported
a2A1920-160ucPRO Stacked ROI feature not supported
a2A1920-160umBAS Stacked ROI feature not supported
a2A1920-160umPRO Stacked ROI feature not supported
a2A1920-165g5cBAS Stacked ROI feature not supported
a2A1920-165g5mBAS Stacked ROI feature not supported
a2A2440-98g5cBAS Stacked ROI feature not supported
a2A2440-98g5mBAS Stacked ROI feature not supported
a2A2448-23gcBAS Stacked ROI feature not supported
a2A2448-23gcPRO Stacked ROI feature not supported
a2A2448-23gmBAS Stacked ROI feature not supported
a2A2448-23gmPRO Stacked ROI feature not supported
a2A2448-75ucBAS Stacked ROI feature not supported
a2A2448-75ucPRO Stacked ROI feature not supported
a2A2448-75umBAS Stacked ROI feature not supported
a2A2448-75umPRO Stacked ROI feature not supported
a2A2448-105g5cBAS Stacked ROI feature not supported
a2A2448-105g5mBAS Stacked ROI feature not supported
a2A2590-22gcBAS Stacked ROI feature not supported
a2A2590-22gcPRO Stacked ROI feature not supported
a2A2590-22gmBAS Stacked ROI feature not supported
a2A2590-22gmPRO Stacked ROI feature not supported
a2A2590-60ucBAS Stacked ROI feature not supported
a2A2590-60ucPRO Stacked ROI feature not supported
a2A2590-60umBAS Stacked ROI feature not supported
a2A2590-60umPRO Stacked ROI feature not supported
a2A2600-20gcBAS Stacked ROI feature not supported
a2A2600-20gcPRO Stacked ROI feature not supported
a2A2600-20gmBAS Stacked ROI feature not supported
a2A2600-20gmPRO Stacked ROI feature not supported
a2A2600-64ucBAS Stacked ROI feature not supported
a2A2600-64ucPRO Stacked ROI feature not supported
a2A2600-64umBAS Stacked ROI feature not supported
a2A2600-64umPRO Stacked ROI feature not supported
a2A2840-14gcBAS Stacked ROI feature not supported
a2A2840-14gcPRO Stacked ROI feature not supported
a2A2840-14gmBAS Stacked ROI feature not supported
a2A2840-14gmPRO Stacked ROI feature not supported
a2A2840-48ucBAS Stacked ROI feature not supported
a2A2840-48ucPRO Stacked ROI feature not supported
a2A2840-48umBAS Stacked ROI feature not supported
a2A2840-48umPRO Stacked ROI feature not supported
a2A2840-67g5cBAS Stacked ROI feature not supported
a2A2840-67g5mBAS Stacked ROI feature not supported
a2A3840-13gcBAS Stacked ROI feature not supported
a2A3840-13gcPRO Stacked ROI feature not supported
a2A3840-13gmBAS Stacked ROI feature not supported
a2A3840-13gmPRO Stacked ROI feature not supported
a2A3840-45ucBAS Stacked ROI feature not supported
a2A3840-45ucPRO Stacked ROI feature not supported
a2A3840-45umBAS Stacked ROI feature not supported
a2A3840-45umPRO Stacked ROI feature not supported
a2A4096-9gcBAS Stacked ROI feature not supported
a2A4096-9gcPRO Stacked ROI feature not supported
a2A4096-9gmBAS Stacked ROI feature not supported
a2A4096-9gmPRO Stacked ROI feature not supported
a2A4096-30ucBAS Stacked ROI feature not supported
a2A4096-30ucPRO Stacked ROI feature not supported
a2A4096-30umBAS Stacked ROI feature not supported
a2A4096-30umPRO Stacked ROI feature not supported
a2A4096-44g5cBAS Stacked ROI feature not supported
a2A4096-44g5mBAS Stacked ROI feature not supported
a2A4200-12gcBAS Stacked ROI feature not supported
a2A4200-12gcPRO Stacked ROI feature not supported
a2A4200-12gmBAS Stacked ROI feature not supported
a2A4200-12gmPRO Stacked ROI feature not supported
a2A4200-40ucBAS Stacked ROI feature not supported
a2A4200-40ucPRO Stacked ROI feature not supported
a2A4200-40umBAS Stacked ROI feature not supported
a2A4200-40umPRO Stacked ROI feature not supported
a2A4504-5gcBAS Stacked ROI feature not supported
a2A4504-5gcPRO Stacked ROI feature not supported
a2A4504-5gmBAS Stacked ROI feature not supported
a2A4504-5gmPRO Stacked ROI feature not supported
a2A4504-18ucBAS Stacked ROI feature not supported
a2A4504-18ucPRO Stacked ROI feature not supported
a2A4504-18umBAS Stacked ROI feature not supported
a2A4504-18umPRO Stacked ROI feature not supported
a2A4504-27g5cBAS Stacked ROI feature not supported
a2A4504-27g5mBAS Stacked ROI feature not supported
a2A4508-6gcBAS Stacked ROI feature not supported
a2A4508-6gcPRO Stacked ROI feature not supported
a2A4508-6gmBAS Stacked ROI feature not supported
a2A4508-6gmPRO Stacked ROI feature not supported
a2A4508-20ucBAS Stacked ROI feature not supported
a2A4508-20ucPRO Stacked ROI feature not supported
a2A4508-20umBAS Stacked ROI feature not supported
a2A4508-20umPRO Stacked ROI feature not supported
a2A5320-7gcBAS Stacked ROI feature not supported
a2A5320-7gcPRO Stacked ROI feature not supported
a2A5320-7gmBAS Stacked ROI feature not supported
a2A5320-7gmPRO Stacked ROI feature not supported
a2A5320-23ucBAS Stacked ROI feature not supported
a2A5320-23ucPRO Stacked ROI feature not supported
a2A5320-23umBAS Stacked ROI feature not supported
a2A5320-23umPRO Stacked ROI feature not supported
a2A5320-34g5cBAS Stacked ROI feature not supported
a2A5320-34g5mBAS Stacked ROI feature not supported
a2A5328-4gcBAS Stacked ROI feature not supported
a2A5328-4gcPRO Stacked ROI feature not supported
a2A5328-4gmBAS Stacked ROI feature not supported
a2A5328-4gmPRO Stacked ROI feature not supported
a2A5328-15ucBAS Stacked ROI feature not supported
a2A5328-15ucPRO Stacked ROI feature not supported
a2A5328-15umBAS Stacked ROI feature not supported
a2A5328-15umPRO Stacked ROI feature not supported
a2A5328-22g5cBAS Stacked ROI feature not supported
a2A5328-22g5mBAS Stacked ROI feature not supported
acA640-121gm Stacked ROI feature not supported
acA640-300gc 8
acA640-300gm 8
acA640-750uc 8
acA640-750um 8
acA720-290gc Stacked ROI feature not supported
acA720-290gm Stacked ROI feature not supported
acA720-520uc Stacked ROI feature not supported
acA720-520um Stacked ROI feature not supported
acA800-200gc 8
acA800-200gm 8
acA800-510uc 8
acA800-510um 8
acA1280-60gc Stacked ROI feature not supported
acA1280-60gm Stacked ROI feature not supported
acA1300-60gc Stacked ROI feature not supported
acA1300-60gm Stacked ROI feature not supported
acA1300-60gmNIR Stacked ROI feature not supported
acA1300-75gc Stacked ROI feature not supported
acA1300-75gm Stacked ROI feature not supported
acA1300-200uc 8
acA1300-200um 8
acA1440-73gc Stacked ROI feature not supported
acA1440-73gm Stacked ROI feature not supported
acA1440-220uc 2
acA1440-220um 2
acA1600-20gc Stacked ROI feature not supported
acA1600-20uc Stacked ROI feature not supported
acA1600-60gc Stacked ROI feature not supported
acA1600-60gm Stacked ROI feature not supported
acA1920-25gc Stacked ROI feature not supported
acA1920-25gm Stacked ROI feature not supported
acA1920-25uc Stacked ROI feature not supported
acA1920-25um Stacked ROI feature not supported
acA1920-40gc Stacked ROI feature not supported
acA1920-40gm Stacked ROI feature not supported
acA1920-40uc Stacked ROI feature not supported
acA1920-40ucMED Stacked ROI feature not supported
acA1920-40um Stacked ROI feature not supported
acA1920-40umMED Stacked ROI feature not supported
acA1920-48gc Stacked ROI feature not supported
acA1920-48gm Stacked ROI feature not supported
acA1920-50gc Stacked ROI feature not supported
acA1920-50gm Stacked ROI feature not supported
acA1920-150uc 8
acA1920-150um 8
acA1920-155uc 4
acA1920-155ucMED 4
acA1920-155um 4
acA1920-155umMED 4
acA2000-50gc Stacked ROI feature not supported
acA2000-50gm Stacked ROI feature not supported
acA2000-165uc Stacked ROI feature not supported
acA2000-165um Stacked ROI feature not supported
acA2040-25gc Stacked ROI feature not supported
acA2040-25gm Stacked ROI feature not supported
acA2040-25gmNIR Stacked ROI feature not supported
acA2040-35gc Stacked ROI feature not supported
acA2040-35gm Stacked ROI feature not supported
acA2040-55uc Stacked ROI feature not supported
acA2040-55um Stacked ROI feature not supported
acA2040-90uc Stacked ROI feature not supported
acA2040-90um Stacked ROI feature not supported
acA2040-90umNIR Stacked ROI feature not supported
acA2040-120uc 8
acA2040-120um 8
acA2440-20gc Stacked ROI feature not supported
acA2440-20gm Stacked ROI feature not supported
acA2440-35uc Stacked ROI feature not supported
acA2440-35ucMED Stacked ROI feature not supported
acA2440-35um Stacked ROI feature not supported
acA2440-35umMED Stacked ROI feature not supported
acA2440-75uc 8
acA2440-75ucMED 8
acA2440-75um 8
acA2440-75umMED 8
acA2500-14gc Stacked ROI feature not supported
acA2500-14gm Stacked ROI feature not supported
acA2500-14uc Stacked ROI feature not supported
acA2500-14um Stacked ROI feature not supported
acA2500-20gc 8
acA2500-20gcMED 8
acA2500-20gm 8
acA2500-20gmMED 8
acA2500-60uc 8
acA2500-60um 8
acA3088-16gc Stacked ROI feature not supported
acA3088-16gm Stacked ROI feature not supported
acA3088-57uc Stacked ROI feature not supported
acA3088-57ucMED Stacked ROI feature not supported
acA3088-57um Stacked ROI feature not supported
acA3088-57umMED Stacked ROI feature not supported
acA3800-10gc Stacked ROI feature not supported
acA3800-10gm Stacked ROI feature not supported
acA3800-14uc Stacked ROI feature not supported
acA3800-14um Stacked ROI feature not supported
acA4024-8gc Stacked ROI feature not supported
acA4024-8gm Stacked ROI feature not supported
acA4024-29uc Stacked ROI feature not supported
acA4024-29um Stacked ROI feature not supported
acA4096-11gc Stacked ROI feature not supported
acA4096-11gm Stacked ROI feature not supported
acA4096-30uc Stacked ROI feature not supported
acA4096-30ucMED Stacked ROI feature not supported
acA4096-30um Stacked ROI feature not supported
acA4096-30umMED Stacked ROI feature not supported
acA4096-40uc 8
acA4096-40ucMED 8
acA4096-40um 8
acA4096-40umMED 8
acA4112-8gc Stacked ROI feature not supported
acA4112-8gm Stacked ROI feature not supported
acA4112-20uc Stacked ROI feature not supported
acA4112-20ucMED Stacked ROI feature not supported
acA4112-20um Stacked ROI feature not supported
acA4112-20umMED Stacked ROI feature not supported
acA4112-30uc 8
acA4112-30ucMED 8
acA4112-30um 8
acA4112-30umMED 8
acA5472-5gc Stacked ROI feature not supported
acA5472-5gm Stacked ROI feature not supported
acA5472-17uc Stacked ROI feature not supported
acA5472-17ucMED Stacked ROI feature not supported
acA5472-17um Stacked ROI feature not supported
acA5472-17umMED Stacked ROI feature not supported
boA1936-400cc 8
boA1936-400cm 8
boA2448-250cc Stacked ROI feature not supported
boA2448-250cm Stacked ROI feature not supported
boA2832-190cc Stacked ROI feature not supported
boA2832-190cm Stacked ROI feature not supported
boA4096-93cc Stacked ROI feature not supported
boA4096-93cm Stacked ROI feature not supported
boA4096-180cc Stacked ROI feature not supported
boA4096-180cm Stacked ROI feature not supported
boA4112-68cc Stacked ROI feature not supported
boA4112-68cm Stacked ROI feature not supported
boA4500-45cc Stacked ROI feature not supported
boA4500-45cm Stacked ROI feature not supported
boA4504-100cc Stacked ROI feature not supported
boA4504-100cm Stacked ROI feature not supported
boA5120-150cc Stacked ROI feature not supported
boA5120-150cm Stacked ROI feature not supported
boA5120-230cc Stacked ROI feature not supported
boA5120-230cm Stacked ROI feature not supported
boA5320-150cc Stacked ROI feature not supported
boA5320-150cm Stacked ROI feature not supported
boA5328-100cc Stacked ROI feature not supported
boA5328-100cm Stacked ROI feature not supported
boA6500-36cc Stacked ROI feature not supported
boA6500-36cm Stacked ROI feature not supported
boA8100-16cc Stacked ROI feature not supported
boA8100-16cm Stacked ROI feature not supported
boA9344-30cc Stacked ROI feature not supported
boA9344-30cm Stacked ROI feature not supported
boA9344-70cc Stacked ROI feature not supported
boA9344-70cm Stacked ROI feature not supported
boA13440-17cm Stacked ROI feature not supported
daA720-520uc Stacked ROI feature not supported
daA720-520um Stacked ROI feature not supported
daA1280-54uc Stacked ROI feature not supported
daA1280-54um Stacked ROI feature not supported
daA1440-220uc Stacked ROI feature not supported
daA1440-220um Stacked ROI feature not supported
daA1600-60uc Stacked ROI feature not supported
daA1600-60um Stacked ROI feature not supported
daA1920-15um Stacked ROI feature not supported
daA1920-30uc Stacked ROI feature not supported
daA1920-30um Stacked ROI feature not supported
daA1920-160uc Stacked ROI feature not supported
daA1920-160um Stacked ROI feature not supported
daA2448-70uc Stacked ROI feature not supported
daA2448-70um Stacked ROI feature not supported
daA2500-14uc Stacked ROI feature not supported
daA2500-14um Stacked ROI feature not supported
daA3840-45uc Stacked ROI feature not supported
daA3840-45um Stacked ROI feature not supported
puA1280-54uc Stacked ROI feature not supported
puA1280-54um Stacked ROI feature not supported
puA1600-60uc Stacked ROI feature not supported
puA1600-60um Stacked ROI feature not supported
puA1920-30uc Stacked ROI feature not supported
puA1920-30um Stacked ROI feature not supported
puA2500-14uc Stacked ROI feature not supported
puA2500-14um Stacked ROI feature not supported

Sample Code#

// Configure width and offset X for all zones
camera.Width.SetValue(200);
camera.OffsetX.SetValue(100);
// Select zone 0
camera.ROIZoneSelector.SetValue(ROIZoneSelector_Zone0);
// Set the vertical offset for the selected zone
camera.ROIZoneOffset.SetValue(100);
// Set the height for the selected zone
camera.ROIZoneSize.SetValue(100);
// Enable the selected zone
camera.ROIZoneMode.SetValue(ROIZoneMode_On);
// Select zone 1
camera.ROIZoneSelector.SetValue(ROIZoneSelector_Zone1);
// Set the vertical offset for the selected zone
camera.ROIZoneOffset.SetValue(250);
// Set the height for the selected zone
camera.ROIZoneSize.SetValue(200);
// Enable the selected zone
camera.ROIZoneMode.SetValue(ROIZoneMode_On);
INodeMap& nodemap = camera.GetNodeMap();
// Configure width and offset X for all zones
CIntegerParameter(nodemap, "Width").SetValue(200);
CIntegerParameter(nodemap, "OffsetX").SetValue(100);
// Select zone 0
CEnumParameter(nodemap, "ROIZoneSelector").SetValue("Zone0");
// Set the vertical offset for the selected zone
CIntegerParameter(nodemap, "ROIZoneOffset").SetValue(100);
// Set the height for the selected zone
CIntegerParameter(nodemap, "ROIZoneSize").SetValue(100);
// Enable the selected zone
CEnumParameter(nodemap, "ROIZoneMode").SetValue("On");
// Select zone 1
CEnumParameter(nodemap, "ROIZoneSelector").SetValue("Zone1");
// Set the vertical offset for the selected zone
CIntegerParameter(nodemap, "ROIZoneOffset").SetValue(250);
// Set the height for the selected zone
CIntegerParameter(nodemap, "ROIZoneSize").SetValue(200);
// Enable the selected zone
CEnumParameter(nodemap, "ROIZoneMode").SetValue("On");
// Configure width and offset X for all zones
camera.Parameters[PLCamera.Width].SetValue(200);
camera.Parameters[PLCamera.OffsetX].SetValue(100);
// Select zone 0
camera.Parameters[PLCamera.ROIZoneSelector].SetValue(PLCamera.ROIZoneSelector.Zone0);
// Set the vertical offset for the selected zone
camera.Parameters[PLCamera.ROIZoneOffset].SetValue(100);
// Set the height for the selected zone
camera.Parameters[PLCamera.ROIZoneSize].SetValue(100);
// Enable the selected zone
camera.Parameters[PLCamera.ROIZoneMode].SetValue(PLCamera.ROIZoneMode.On);
// Select zone 1
camera.Parameters[PLCamera.ROIZoneSelector].SetValue(PLCamera.ROIZoneSelector.Zone1);
// Set the vertical offset for the selected zone
camera.Parameters[PLCamera.ROIZoneOffset].SetValue(250);
// Set the height for the selected zone
camera.Parameters[PLCamera.ROIZoneSize].SetValue(200);
// Enable the selected zone
camera.Parameters[PLCamera.ROIZoneMode].SetValue(PLCamera.ROIZoneMode.On);
/* 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 */
/* Configure width and offset X for all zones */
errRes = PylonDeviceSetIntegerFeature(hdev, "Width", 200);
CHECK(errRes);
errRes = PylonDeviceSetIntegerFeature(hdev, "OffsetX", 100);
CHECK(errRes);
/* Select zone 0 */
errRes = PylonDeviceFeatureFromString(hdev, "ROIZoneSelector", "Zone0");
CHECK(errRes);
/* Set the vertical offset for the selected zone */
errRes = PylonDeviceSetIntegerFeature(hdev, "ROIZoneOffset", 100);
CHECK(errRes);
/* Set the height for the selected zone */
errRes = PylonDeviceSetIntegerFeature(hdev, "ROIZoneSize", 100);
CHECK(errRes);
/* Enable the selected zone */
errRes = PylonDeviceFeatureFromString(hdev, "ROIZoneMode", "On");
CHECK(errRes);
/* Select zone 1 */
errRes = PylonDeviceFeatureFromString(hdev, "ROIZoneSelector", "Zone1");
CHECK(errRes);
/* Set the vertical offset for the selected zone */
errRes = PylonDeviceSetIntegerFeature(hdev, "ROIZoneOffset", 250);
CHECK(errRes);
/* Set the height for the selected zone */
errRes = PylonDeviceSetIntegerFeature(hdev, "ROIZoneSize", 200);
CHECK(errRes);
/* Enable the selected zone */
errRes = PylonDeviceFeatureFromString(hdev, "ROIZoneMode", "On");
CHECK(errRes);
# Configure width and offset X for all zones
camera.Width.Value = 200
camera.OffsetX.Value = 100
# Select zone 0
camera.ROIZoneSelector.Value = "Zone0"
# Set the vertical offset for the selected zone
camera.ROIZoneOffset.Value = 100
# Set the height for the selected zone
camera.ROIZoneSize.Value = 100
# Enable the selected zone
camera.ROIZoneMode.Value = "On"
# Select zone 1
camera.ROIZoneSelector.Value = "Zone1"
# Set the vertical offset for the selected zone
camera.ROIZoneOffset.Value = 250
# Set the height for the selected zone
camera.ROIZoneSize.Value = 200
# Enable the selected zone
camera.ROIZoneMode.Value = "On"

You can also use the pylon Viewer to easily set the parameters.