Struct Spinnaker::CoordinateDependentParams¶
ClassList > Spinnaker > CoordinateDependentParams
Container for 3D scan calibration parameters used in stereo processing. More...
#include <Scan3DParameters.h>
Public Attributes¶
| Type | Name |
|---|---|
| float64_t | axisMax Maximum valid coordinate value. |
| float64_t | axisMin Minimum valid coordinate value. |
| float64_t | coordinateOffset Offset for coordinate transformation. |
| float64_t | coordinateScale Scale factor for coordinate transformation. |
| bool | invalidDataFlag Enable/disable invalid data flagging. |
| float64_t | invalidDataValue Value identifying non-valid pixels. |
Detailed Description¶
The Scan3DParameters class provides access to camera calibration parameters required for stereo image processing, including computing 3D point clouds from disparity images. This is the primary API for working with stereo camera parameters.
Key Parameters: * Baseline: Physical distance between the two cameras (in meters) * Focal Length: Focal length in pixels * Principal Point (U, V): Optical center of the camera * Coordinate Scale/Offset: Transform disparity values to world coordinates * Coordinate Selector: Select coordinate axis (X/Y/Z or CoordinateA/B/C) * Invalid Data: Identify and handle invalid pixels in disparity images
Coordinate-Dependent Parameters: Some parameters (CoordinateOffset, CoordinateScale, InvalidDataFlag, InvalidDataValue, AxisMin, AxisMax) vary per coordinate axis. Set the CoordinateSelector before accessing these parameters to specify which coordinate axis (A/B/C) you want to configure.
Common Usage Pattern:
// Option 1: Create and auto-populate from camera
Scan3DParameters scan3dParams(pCamera->GetNodeMap());
// Option 2: Create empty and populate later
Scan3DParameters scan3dParams;
scan3dParams.SetScan3DParameters(pCamera->GetNodeMap()); // Read from camera
// Option 3: Set manually
scan3dParams.SetBaseline(0.12f); // 120mm baseline
scan3dParams.SetFocalLength(1500.0f); // focal length in pixels
scan3dParams.SetPrincipalPointU(640.0f); // image center U
scan3dParams.SetPrincipalPointV(512.0f); // image center V
// Set coordinate-dependent parameters for Z-axis (CoordinateC)
scan3dParams.SetCoordinateSelector(Scan3dCoordinateSelector_CoordinateC);
scan3dParams.SetCoordinateOffset(0.0f);
scan3dParams.SetCoordinateScale(1.0f);
scan3dParams.SetInvalidDataFlag(true);
scan3dParams.SetInvalidDataValue(-10000.0f);
// Use with ImageUtilityStereo functions
PointCloudData pointCloud = ImageUtilityStereo::ComputePointCloud(
disparityImage, rectifiedImage, pointCloudParams, scan3dParams);
See also: ImageUtilityStereo for stereo processing functions
See also: StereoCameraParameters for legacy API (deprecated)
See also: ToStereoCameraParameters() for backward compatibility conversion
See also: FromStereoCameraParameters() for legacy parameter import
Note:
This class replaces the deprecated StereoCameraParameters struct. Use ToStereoCameraParameters() and FromStereoCameraParameters() for migration and backward compatibility.
Note:
For cameras with coordinate selector support, coordinate-dependent parameters are stored per axis. Always set CoordinateSelector before accessing these parameters to ensure you're working with the correct axis.
Structure containing all coordinate-dependent parameters for a single axis.
This structure groups together all parameters that vary per coordinate (A, B, C). Use with GetCoordinateParams() and SetCoordinateParams() for efficient batch operations.
Public Attributes Documentation¶
variable axisMax¶
Maximum valid coordinate value.
variable axisMin¶
Minimum valid coordinate value.
variable coordinateOffset¶
Offset for coordinate transformation.
variable coordinateScale¶
Scale factor for coordinate transformation.
variable invalidDataFlag¶
Enable/disable invalid data flagging.
variable invalidDataValue¶
Value identifying non-valid pixels.
The documentation for this class was generated from the following file C:/workspace/include/Scan3DParameters.h