in source/mesh_stream/ConvertToBinary.cpp [86:114]
void verifyInputs(const Camera::Rig& rig, const std::vector<std::string>& outputFormats) {
CHECK_NE(FLAGS_rig, "");
CHECK_NE(FLAGS_first, "");
CHECK_NE(FLAGS_last, "");
const std::set<std::string> supportedFormats = {"idx", "vtx", "bc7", "obj", "pfm", "rgba"};
for (const std::string& outputFormat : outputFormats) {
// We allow size 0 inputs to ensure stray commas are ignored, i.e. exr,,png is fine
CHECK(outputFormat.size() == 0 || supportedFormats.find(outputFormat) != supportedFormats.end())
<< "Invalid output format specified: " << outputFormat;
const bool isColor = outputFormat == "bc7" || outputFormat == "rgba";
const bool isDisparity = outputFormat == "idx" || outputFormat == "vtx" ||
outputFormat == "pfm" || outputFormat == "obj";
if (!FLAGS_color.empty() && isColor) {
verifyImagePaths(FLAGS_color, rig, FLAGS_first, FLAGS_last);
} else {
LOG(INFO) << "No color directory provided. Ignoring color conversion...";
}
if (!FLAGS_disparity.empty() && isDisparity) {
verifyImagePaths(FLAGS_disparity, rig, FLAGS_first, FLAGS_last);
} else {
LOG(INFO) << "No disparity directory provided. Ignoring depth conversion...";
}
if (!FLAGS_foreground_masks.empty() && isDisparity) {
verifyImagePaths(FLAGS_foreground_masks, rig, FLAGS_first, FLAGS_last);
}
}
}