mirror of
https://github.com/introlab/rtabmap.git
synced 2026-09-11 22:10:21 +08:00
Fixed build for C++03
This commit is contained in:
@@ -305,9 +305,9 @@ Transform OdometryF2M::computeTransform(
|
||||
{
|
||||
if(matches.find(iter->first) == matches.end())
|
||||
{
|
||||
iter = mapPoints.erase(iter);
|
||||
iterMapDescriptors = mapDescriptors.erase(iterMapDescriptors);
|
||||
iterMapWords = mapWords.erase(iterMapWords);
|
||||
mapPoints.erase(iter++);
|
||||
mapDescriptors.erase(iterMapDescriptors++);
|
||||
mapWords.erase(iterMapWords++);
|
||||
++removed;
|
||||
}
|
||||
else
|
||||
|
||||
@@ -26,7 +26,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
#include "ExportScansDialog.h"
|
||||
#include "ui_ExportScansDialog.h"
|
||||
#include "ui_exportScansDialog.h"
|
||||
|
||||
#include "rtabmap/gui/ProgressDialog.h"
|
||||
#include "rtabmap/gui/CloudViewer.h"
|
||||
|
||||
+20
-4
@@ -50,12 +50,24 @@ bool readHeader(FILE *fp, const char *imtype, char c1, char c2,
|
||||
skipSpace(fp);
|
||||
skipComment(fp);
|
||||
skipSpace(fp);
|
||||
fscanf(fp, "%d", width);
|
||||
int r = fscanf(fp, "%d", width);
|
||||
if(r==0)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
skipSpace(fp);
|
||||
fscanf(fp, "%d", height);
|
||||
r = fscanf(fp, "%d", height);
|
||||
if(r==0)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
if (thirdArg) {
|
||||
skipSpace(fp);
|
||||
fscanf(fp, "%d", nbands);
|
||||
r = fscanf(fp, "%d", nbands);
|
||||
if(r==0)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
// skip SINGLE newline character after reading image height (or third arg)
|
||||
c = getc(fp);
|
||||
@@ -102,7 +114,11 @@ cv::Mat readPFM(const char* filename)
|
||||
skipSpace(fp);
|
||||
|
||||
float scalef;
|
||||
fscanf(fp, "%f", &scalef); // scale factor (if negative, little endian)
|
||||
int r = fscanf(fp, "%f", &scalef); // scale factor (if negative, little endian)
|
||||
if(r==0)
|
||||
{
|
||||
return cv::Mat();
|
||||
}
|
||||
|
||||
// skip SINGLE newline character after reading third arg
|
||||
char c = getc(fp);
|
||||
|
||||
Reference in New Issue
Block a user