Image Stitching with Learning¶
This code snippet shows how to stitch multiple images.
C++¶
#include <eVision/EasyImage/EImageStitcher.h>
using namespace eVision;
// Create the stitcher class
EImageStitcher stitcher;
std::vector<EImageBW8> learningImages;
std::vector<EImageBW8> subjectImages;
EImageBW8 output;
stitcher.LearnBW8(learningImages);
// Learn has been done, stitching will be faster as the transformation to apply
// to the different patches are already computed
stitcher.Stitch(subjectImages, output);
C#¶
using eVision;
using System.Collections.Generic;
// Create the stitcher class
EImageStitcher stitcher = new EImageStitcher();
List<EImageBW8> learningImages = new List<EImageBW8>();
List<EImageBW8> subjectImages = new List<EImageBW8>();
EImageBW8 output = new EImageBW8();
stitcher.LearnBW8(learningImages.ToArray());
// Learn has been done, stitching will be faster as the transformation to apply
// to the different patches are already computed
stitcher.Stitch(subjectImages.ToArray(), output);
Python¶
import eVision
# Create the stitcher class
stitcher = eVision.EImageStitcher()
# EImageC24 can be used instead of EImageBW8
# Patchs is a vector of image where each image is calibrated
learningImages = [eVision.EImageBW8(), eVision.EImageBW8(), eVision.EImageBW8()]
subjectImages = []
output = eVision.EImageBW8()
stitcher.LearnBW8(learningImages)
# Learn has been done, stitching will be faster as the transformation to apply
# to the different patches are already computed
stitcher.Stitch(subjectImages, output)