#include <RVC/RVC.h>
#include <fstream>
#include <iostream>
std::cout <<
"x1.calc_normal:" << cap_opt.
calc_normal << std::endl;
std::cout <<
"x1.filter_range:" << cap_opt.
filter_range << std::endl;
std::cout <<
"x1.gain_2d:" << cap_opt.
gain_2d << std::endl;
std::cout <<
"x1.gain_3d:" << cap_opt.
gain_3d << std::endl;
std::cout <<
"x1.gamma_2d:" << cap_opt.
gamma_2d << std::endl;
std::cout <<
"x1.gamma_3d:" << cap_opt.
gamma_3d << std::endl;
std::cout <<
"x1.truncate_z_max:" << cap_opt.
truncate_z_max << std::endl;
std::cout <<
"x1.truncate_z_min:" << cap_opt.
truncate_z_min << std::endl;
std::cout <<
"x1.scan_times:" << cap_opt.
scan_times << std::endl;
std::cout <<
"x1.smooth_sigma:" << cap_opt.
smooth_sigma << std::endl;
}
std::cout <<
"x2.calc_normal:" << cap_opt.
calc_normal << std::endl;
std::cout <<
"x2.gain_2d:" << cap_opt.
gain_2d << std::endl;
std::cout <<
"x2.gain_3d:" << cap_opt.
gain_3d << std::endl;
std::cout <<
"x2.gamma_2d:" << cap_opt.
gamma_2d << std::endl;
std::cout <<
"x2.gamma_3d:" << cap_opt.
gamma_3d << std::endl;
std::cout <<
"x2.projector_color:" << cap_opt.
projector_color << std::endl;
std::cout <<
"x2.scan_times:" << cap_opt.
scan_times << std::endl;
std::cout <<
"x2.correspond2d:" << cap_opt.
correspond2d << std::endl;
std::cout <<
"x2.smooth_sigma:" << cap_opt.
smooth_sigma << std::endl;
}
static void UseX1() {
size_t actual_size = 0;
SystemListDevices(devices, 10, &actual_size, RVC::SystemListDeviceType::All);
if (actual_size == 0) {
std::cout << "Can not find any Camera!" << std::endl;
return;
}
if(devices[0].IsFirmwareMatch() == false){
std::cout << "device firmware mismatch, Please use RVCManager to upgrade the firmware" << std::endl;
return;
}
std::cout << "Failed to open camera! Please check whether the camera is connected and make sure it is not occupied and supports X1." << std::endl;
return;
}
PrintCaptureOptions(stored_opt_1);
return;
}
static void UseX2() {
size_t actual_size = 0;
SystemListDevices(devices, 10, &actual_size, RVC::SystemListDeviceType::All);
if (actual_size == 0) {
std::cout << "Can not find any Camera!" << std::endl;
return;
}
if(devices[0].IsFirmwareMatch() == false){
std::cout << "device firmware mismatch, Please use RVCManager to upgrade the firmware" << std::endl;
return;
}
std::cout << "Failed to open camera! Please check whether the camera is connected and make sure it is not occupied and supports X2." << std::endl;
return;
}
if (info.support_extra) {
camera_id = RVC::CameraID_Extra;
}
PrintCaptureOptions(stored_opt_1);
return;
}
int main(int argc, char *argv[]) {
UseX1();
UseX2();
return 0;
}