Go to the documentation of this file.
39 #include <QApplication>
47 "dataRecorder [options] config.ini output.db\n"
49 " A config file contains all camera parameters and driver used. That\n"
50 " file can be generated by RTAB-Map->Preferences->Save Settings(*.ini)\n"
51 " after modifying Source settings.\n"
53 " -debug Show debug log.\n"
54 " -hide Don't display the current cloud recorded.\n");
59 QApplication *
app = 0;
63 printf(
"\nSignal %d caught...\n", sig);
70 QMetaObject::invokeMethod(
app,
"quit");
82 std::string configFile;
88 for(
int i=1;
i<argc-2; ++
i)
90 if(strcmp(
argv[
i],
"-debug") == 0)
95 if(strcmp(
argv[
i],
"-hide") == 0)
100 printf(
"Unrecognized option : %s\n",
argv[
i]);
103 configFile =
argv[argc-2];
105 fileName =
argv[argc-1];
110 printf(
"Database names must end with .db extension\n");
114 UINFO(
"Output = %s", fileName.c_str());
115 UINFO(
"Show = %s", show?
"true":
"false");
116 UINFO(
"Config = %s", configFile.c_str());
118 app =
new QApplication(argc,
argv);
124 if(paramTmp.find(Parameters::kRtabmapWorkingDirectory()) == paramTmp.end())
130 dialog.
init(configFile.c_str());
180 if(recorder.
init(fileName.c_str()))
185 recorder.setWindowTitle(
"Data recorder");
186 recorder.setMinimumWidth(500);
187 recorder.setMinimumHeight(300);
188 recorder.showNormal();
189 app->processEvents();
204 UERROR(
"Cannot initialize the camera!");
209 UERROR(
"Cannot initialize the recorder! Maybe the path is wrong: \"%s\"", fileName.c_str());
std::pair< std::string, std::string > ParametersPair
double getSourceScanForceGroundNormalsUp() const
bool isSourceRGBDColorOnly() const
RTABMAP_DEPRECATED void setScanParameters(bool fromDepth, int downsampleStep, float rangeMin, float rangeMax, float voxelSize, int normalsK, float normalsRadius, bool forceGroundNormalsUp, bool deskewing)
bool isSourceStereoExposureCompensation() const
bool init(const QString &path, bool recordInRAM=true)
void registerToEventsManager()
rtabmap::ParametersMap getAllParameters() const
double getSourceScanNormalsRadius() const
static void setLevel(ULogger::Level level)
void join(bool killFirst=false)
void setColorOnly(bool colorOnly)
void init(const QString &iniFilePath="")
double getBilateralSigmaR() const
double getBilateralSigmaS() const
std::map< std::string, std::string > ParametersMap
int getSourceHistogramMethod() const
rtabmap::SensorCaptureThread * cam
void setDistortionModel(const std::string &path)
int main(int argc, char *argv[])
static std::string homeDir()
virtual QString getDefaultWorkingDirectory() const
virtual bool init(const std::string &calibrationFolder=".", const std::string &cameraName="")=0
void enableIMUFiltering(int filteringStrategy=1, const ParametersMap ¶meters=ParametersMap(), bool baseFrameConversion=false)
bool isBilateralFiltering() const
bool isSourceStereoDepthGenerated() const
int getSourceScanDownsampleStep() const
Some conversion functions.
std::string getExtension()
double getGeneralInputRate() const
void setStereoExposureCompensation(bool enabled)
bool isSourceScanFromDepth() const
void setMirroringEnabled(bool enabled)
static void setType(Type type, const std::string &fileName=kDefaultLogFileName, bool append=true)
int getIMUFilteringStrategy() const
void setStereoToDepth(bool enabled)
std::string UTILITE_EXPORT uReplaceChar(const std::string &str, char before, char after)
ULogger class and convenient macros.
int getSourceImageDecimation() const
static void readINI(const std::string &configFile, ParametersMap ¶meters, bool modifiedOnly=false)
int getSourceScanNormalsK() const
void setImageDecimation(int decimation)
Camera camera(Pose3(Rot3().retract(Vector3(0.1, 0.2, 0.3)), Point3(0, 5, 0)), Cal3Bundler0(1, 0, 0))
Camera * createCamera(bool useRawImages=false, bool useColor=true)
QString getSourceDistortionModel() const
double getSourceScanRangeMax() const
double getSourceScanVoxelSize() const
PreferencesDialog::Src getSourceDriver() const
bool getIMUFilteringBaseFrameConversion() const
void setHistogramMethod(int histogramMethod)
double getSourceScanRangeMin() const
bool isSourceMirroring() const
static void writeINI(const std::string &configFile, const ParametersMap ¶meters)
void enableBilateralFiltering(float sigmaS, float sigmaR)
bool isDepthFilteringAvailable() const
rtabmap
Author(s): Mathieu Labbe
autogenerated on Thu Jul 25 2024 02:50:12