28 #include <VisionX/interface/components/Calibration.h>
35 #include <Calibration/StereoCalibration.h>
36 #include <Image/ByteImage.h>
37 #include <VideoCapture/BitmapSequenceCapture.h>
47 defineRequiredProperty<std::string>(
49 "Filename and path of the left camera images. Enter the path of the first image of "
50 "the sequence. Filenames need to follow the format: path/*%d.bmp (e.g. "
51 "path/image_left0000.bmp).");
52 defineOptionalProperty<std::string>(
55 "Filename and path of the right camera images. Enter the path of the first image "
56 "of the sequence. Filenames need to follow the format: path/*%d.bmp (e.g. "
57 "path/image_right0000.bmp).");
58 defineOptionalProperty<float>(
"FrameRate", 30.0f,
"Frames per second")
59 .setMatchRegex(
"\\d+(.\\d*)?")
62 defineOptionalProperty<ImageDimension>(
64 ImageDimension(640, 480),
65 "Target resolution of the images. Loaded images will be converted to this size.")
66 .setCaseInsensitive(
true)
67 .map(
"320x240", ImageDimension(320, 240))
68 .map(
"640x480", ImageDimension(640, 480))
69 .map(
"648x482", ImageDimension(648, 482))
70 .map(
"800x600", ImageDimension(800, 600))
71 .map(
"768x576", ImageDimension(768, 576))
72 .map(
"1024x768", ImageDimension(1024, 768))
73 .map(
"1024x1024", ImageDimension(1024, 1024))
74 .map(
"1280x960", ImageDimension(1280, 960))
75 .map(
"1600x1200", ImageDimension(1600, 1200))
76 .map(
"none", ImageDimension(0, 0));
78 defineOptionalProperty<std::string>(
81 "Camera calibration file, will be made available in the SLICE interface");
82 defineOptionalProperty<bool>(
83 "ImagesAreUndistorted",
false,
"Sets whether images are provided undistorted.");
84 defineOptionalProperty<bool>(
85 "LoadNextImageAutomatically",
87 "If true, a new image is loaded everytime the 'capture()' function is executed. If "
88 "false, the same image is provided until 'loadNextImage()' is called from "
90 defineOptionalProperty<int>(
91 "RepeatImageCount", 1,
"Repeats the images for the specified amount of time.");
93 defineOptionalProperty<std::string>(
94 "ReferenceFrameName",
"EyeLeftCamera",
"Optional reference frame name.");
115 virtual public ImageFileSequenceProviderInterface
121 return "ImageSequenceProvider";
129 visionx::StereoCalibration
142 return getProperty<std::string>(
"ReferenceFrameName").getValue();
150 const std::string& imageFilePathRight =
"",
151 const Ice::Current&
c = Ice::emptyCurrent)
override;
153 void loadNextImage(
const Ice::Current&
c = Ice::emptyCurrent)
override;
177 bool capture(
void** ppImageBuffers)
override;
204 CStereoCalibration ivtStereoCalibration;
209 StereoCalibration stereoCalibration;
211 int currentRepeatCount = 0;
212 int repeatImageCount;