Class Stitcher
Image Stitching.
public class Stitcher : SharedPtrObject, IDisposable
- Inheritance
-
Stitcher
- Implements
- Inherited Members
Constructors
Stitcher(Mode)
Creates a Stitcher configured in one of the stitching modes.
public Stitcher(Stitcher.Mode mode = Mode.Panorama)
Parameters
mode
Stitcher.ModeScenario for stitcher operation. This is usually determined by source of images to stitch and their transformation.
Properties
CompositingResol
Get or Set the compositing resolution
public double CompositingResol { get; set; }
Property Value
InterpolationFlags
Get or Set the interpolation type.
public Inter InterpolationFlags { get; set; }
Property Value
PanoConfidenceThresh
Get or set the pano confidence threshold
public double PanoConfidenceThresh { get; set; }
Property Value
RegistrationResol
Get or set the registration resolution
public double RegistrationResol { get; set; }
Property Value
SeamEstimationResol
Get or Set the seam estimation resolution
public double SeamEstimationResol { get; set; }
Property Value
WaveCorrection
Get or Set a flag to indicate if the stitcher should apply wave correction
public bool WaveCorrection { get; set; }
Property Value
WaveCorrectionKind
The wave correction type.
public Stitcher.WaveCorrectionType WaveCorrectionKind { get; set; }
Property Value
WorkScale
The work scale
public double WorkScale { get; }
Property Value
Methods
Cameras()
Get the camera parameters
public VectorOfCameraParams Cameras()
Returns
- VectorOfCameraParams
The camera parameters
Component()
Get the component
public int[] Component()
Returns
- int[]
The component
ComposePanorama(IInputArrayOfArrays, IOutputArray)
These functions try to compose the given images (or images stored internally from the other function calls) into the final pano under the assumption that the image transformations were estimated before.
public Stitcher.Status ComposePanorama(IInputArrayOfArrays images, IOutputArray pano)
Parameters
images
IInputArrayOfArraysInput images
pano
IOutputArrayFinal pano
Returns
ComposePanorama(IOutputArray)
These functions try to match the given images and to estimate rotations of each camera.
public Stitcher.Status ComposePanorama(IOutputArray pano)
Parameters
pano
IOutputArrayFinal pano
Returns
DisposeObject()
Release memory associated with this stitcher
protected override void DisposeObject()
EstimateTransform(IInputArrayOfArrays, IInputArrayOfArrays)
These functions try to match the given images and to estimate rotations of each camera.
public Stitcher.Status EstimateTransform(IInputArrayOfArrays images, IInputArrayOfArrays masks = null)
Parameters
images
IInputArrayOfArraysInput images
masks
IInputArrayOfArraysMasks for each input image specifying where to look for keypoints (optional)
Returns
ResultMask()
Return the mask of the panorama. The mask is a 8U UMat with the values: 0xFF (white) for pixels filled by the input images, 0 (black) for unused pixels.It can be used as the mask for inpaint.
public UMat ResultMask()
Returns
- UMat
The mask of the panorama
SetBlender(Blender)
Set the blender for this stitcher
public void SetBlender(Blender blender)
Parameters
blender
BlenderThe blender
SetBundleAdjusterCompensator(BundleAdjusterBase)
Set the bundle adjuster for this stitcher
public void SetBundleAdjusterCompensator(BundleAdjusterBase bundleAdjuster)
Parameters
bundleAdjuster
BundleAdjusterBaseThe bundle adjuster
SetEstimator(Estimator)
Set the estimator for this stitcher
public void SetEstimator(Estimator estimator)
Parameters
estimator
EstimatorThe estimator
SetExposureCompensator(ExposureCompensator)
Set the exposure compensator for this stitcher.
public void SetExposureCompensator(ExposureCompensator exposureCompensator)
Parameters
exposureCompensator
ExposureCompensatorThe exposure compensator
SetFeaturesFinder(Feature2D)
Set the features finder for this stitcher.
public void SetFeaturesFinder(Feature2D finder)
Parameters
finder
Feature2DThe features finder
SetFeaturesMatcher(FeaturesMatcher)
Set the features matcher for this stitcher
public void SetFeaturesMatcher(FeaturesMatcher featuresMatcher)
Parameters
featuresMatcher
FeaturesMatcherThe features matcher
SetSeamFinder(SeamFinder)
Set the seam finder for this stitcher
public void SetSeamFinder(SeamFinder seamFinder)
Parameters
seamFinder
SeamFinderThe seam finder
SetTransform(IInputArrayOfArrays, VectorOfCameraParams, int[])
These function restores camera rotation and camera intrinsics of each camera that can be got with Stitcher.Cameras() call
public Stitcher.Status SetTransform(IInputArrayOfArrays images, VectorOfCameraParams cameras, int[] component = null)
Parameters
images
IInputArrayOfArraysInput images
cameras
VectorOfCameraParamsEstimated rotation of cameras for each of the input images
component
int[]Indices (0-based) of images constituting the final panorama (optional)
Returns
SetWarper(WarperCreator)
Set the warper creator for this stitcher.
public void SetWarper(WarperCreator warperCreator)
Parameters
warperCreator
WarperCreatorThe warper creator
Stitch(IInputArray, IOutputArray)
Compute the panoramic images given the images
public Stitcher.Status Stitch(IInputArray images, IOutputArray pano)
Parameters
images
IInputArrayThe input images. This can be, for example, a VectorOfMat
pano
IOutputArrayThe panoramic image