kopia lustrzana https://github.com/OpenDroneMap/ODM
Added warning when an orthophoto cannot be generated due to excessive resolution
rodzic
88aa02ed0a
commit
5ff5f3e39d
|
@ -381,8 +381,13 @@ void OdmOrthoPhoto::createOrthoPhoto()
|
|||
}
|
||||
|
||||
// Init ortho photo
|
||||
photo_ = cv::Mat::zeros(rowRes, colRes, CV_8UC4) + cv::Scalar(255, 255, 255, 0);
|
||||
depth_ = cv::Mat::zeros(rowRes, colRes, CV_32F) - std::numeric_limits<float>::infinity();
|
||||
try{
|
||||
photo_ = cv::Mat::zeros(rowRes, colRes, CV_8UC4) + cv::Scalar(255, 255, 255, 0);
|
||||
depth_ = cv::Mat::zeros(rowRes, colRes, CV_32F) - std::numeric_limits<float>::infinity();
|
||||
}catch(const cv::Exception &e){
|
||||
std::cerr << "Couldn't allocate enough memory to render the orthophoto (" << colRes << "x" << rowRes << " cells = " << ((long long)colRes * (long long)rowRes * 4) << " bytes). Try to reduce the -resolution parameter or add more RAM.\n";
|
||||
exit(1);
|
||||
}
|
||||
|
||||
// Contains the vertices of the mesh.
|
||||
pcl::PointCloud<pcl::PointXYZ>::Ptr meshCloud (new pcl::PointCloud<pcl::PointXYZ>);
|
||||
|
|
Ładowanie…
Reference in New Issue