本文整理汇总了C++中ImageReader::getFrame方法的典型用法代码示例。如果您正苦于以下问题:C++ ImageReader::getFrame方法的具体用法?C++ ImageReader::getFrame怎么用?C++ ImageReader::getFrame使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ImageReader
的用法示例。
在下文中一共展示了ImageReader::getFrame方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: loadImages
void loadImages(void)
{
ImageReader myReader;
//-------------------------------------------------------------
// We read the left image, right image, and disparity map
//-------------------------------------------------------------
myReader.setSource(const_cast<char*>(leftImagePath.c_str()));
gMyLeftImage = myReader.getFrame(false); // left image
myReader.setSource(const_cast<char*>(righttImagePath.c_str()));
gMyRightImage = myReader.getFrame(false); // right image
// Normally, I should be able to read the disparity map directly into my
// DepthMap's raster. Then I could render the map as a gray-level image
// in one subwindow and draw it as a mesh in an other. However, at this
// point, the "readInto" component of the ImageReader class has not been
// implemented, so I had to separate the two operations.
myReader.setSource(const_cast<char*>(disparityImagePath.c_str()));
gMyDisparity = static_cast<RasterImage_gray*>(myReader.getFrame(false)); // disparity map
// initially we display the right image in the upper-right subwindow
gUpperRightDisplay = gMyRightImage;
}