8000 Use #pragma once as include guard by ahojnnes · Pull Request #2007 · colmap/colmap · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Use #pragma once as include guard #2007

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Jul 7, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 1 addition & 4 deletions src/colmap/base/camera.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_BASE_CAMERA_H_
#define COLMAP_SRC_BASE_CAMERA_H_
#pragma once

#include "colmap/util/types.h"

Expand Down Expand Up @@ -210,5 +209,3 @@ double* Camera::ParamsData() { return params_.data(); }
void Camera::SetParams(const std::vector<double>& params) { params_ = params; }

} // namespace colmap

#endif // COLMAP_SRC_BASE_CAMERA_H_
5 changes: 1 addition & 4 deletions src/colmap/base/camera_rig.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_BASE_CAMERA_RIG_H_
#define COLMAP_SRC_BASE_CAMERA_RIG_H_
#pragma once

#include "colmap/base/camera.h"
#include "colmap/base/reconstruction.h"
Expand Down Expand Up @@ -123,5 +122,3 @@ class CameraRig {
};

} // namespace colmap

#endif // COLMAP_SRC_BASE_CAMERA_RIG_H_
5 changes: 1 addition & 4 deletions src/colmap/base/correspondence_graph.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_BASE_CORRESPONDENCE_GRAPH_H_
#define COLMAP_SRC_BASE_CORRESPONDENCE_GRAPH_H_
#pragma once

#include "colmap/base/database.h"
#include "colmap/util/types.h"
Expand Down Expand Up @@ -204,5 +203,3 @@ bool CorrespondenceGraph::HasCorrespondences(
}

} // namespace colmap

#endif // COLMAP_SRC_BASE_CORRESPONDENCE_GRAPH_H_
5 changes: 1 addition & 4 deletions src/colmap/base/cost_functions.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_BASE_COST_FUNCTIONS_H_
#define COLMAP_SRC_BASE_COST_FUNCTIONS_H_
#pragma once

#include <Eigen/Core>
#include <ceres/ceres.h>
Expand Down Expand Up @@ -329,5 +328,3 @@ inline void SetSphereManifold(ceres::Problem* problem, double* params) {
}

} // namespace colmap

#endif // COLMAP_SRC_BASE_COST_FUNCTIONS_H_
5 changes: 1 addition & 4 deletions src/colmap/base/database.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_BASE_DATABASE_H_
#define COLMAP_SRC_BASE_DATABASE_H_
#pragma once

#include "colmap/base/camera.h"
#include "colmap/base/image.h"
Expand Down Expand Up @@ -395,5 +394,3 @@ bool Database::SwapImagePair(const image_t image_id1, const image_t image_id2) {
}

} // namespace colmap

#endif // COLMAP_SRC_BASE_DATABASE_H_
5 changes: 1 addition & 4 deletions src/colmap/base/database_cache.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_BASE_DATABASE_CACHE_H_
#define COLMAP_SRC_BASE_DATABASE_CACHE_H_
#pragma once

#include "colmap/base/camera.h"
#include "colmap/base/correspondence_graph.h"
Expand Down Expand Up @@ -148,5 +147,3 @@ inline const class CorrespondenceGraph& DatabaseCache::CorrespondenceGraph()
}

} // namespace colmap

#endif // COLMAP_SRC_BASE_DATABASE_CACHE_H_
5 changes: 1 addition & 4 deletions src/colmap/base/graph_cut.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_BASE_GRAPH_CUT_H_
#define COLMAP_SRC_BASE_GRAPH_CUT_H_
#pragma once

#include "colmap/util/logging.h"

Expand Down Expand Up @@ -216,5 +215,3 @@ bool MinSTGraphCut<node_t, value_t>::IsConnectedToSink(
}

} // namespace colmap

#endif // COLMAP_SRC_BASE_GRAPH_CUT_H_
5 changes: 1 addition & 4 deletions src/colmap/base/image.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_BASE_IMAGE_H_
#define COLMAP_SRC_BASE_IMAGE_H_
#pragma once

#include "colmap/base/camera.h"
#include "colmap/base/point2d.h"
Expand Down Expand Up @@ -355,5 +354,3 @@ bool Image::IsPoint3DVisible(const point2D_t point2D_idx) const {
}

} // namespace colmap

#endif // COLMAP_SRC_BASE_IMAGE_H_
5 changes: 1 addition & 4 deletions src/colmap/base/point2d.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_BASE_POINT2D_H_
#define COLMAP_SRC_BASE_POINT2D_H_
#pragma once

#include "colmap/util/types.h"

Expand Down Expand Up @@ -89,5 +88,3 @@ void Point2D::SetPoint3DId(const point3D_t point3D_id) {
}

} // namespace colmap

#endif // COLMAP_SRC_BASE_POINT2D_H_
5 changes: 1 addition & 4 deletions src/colmap/base/point3d.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_BASE_POINT3D_H_
#define COLMAP_SRC_BASE_POINT3D_H_
#pragma once

#include "colmap/base/track.h"
#include "colmap/util/logging.h"
Expand Down Expand Up @@ -132,5 +131,3 @@ class Track& Point3D::Track() {
void Point3D::SetTrack(class Track track) { track_ = std::move(track); }

} // namespace colmap

#endif // COLMAP_SRC_BASE_POINT3D_H_
5 changes: 1 addition & 4 deletions src/colmap/base/polynomial.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_BASE_POLYNOMIAL_H_
#define COLMAP_SRC_BASE_POLYNOMIAL_H_
#pragma once

#include <Eigen/Core>

Expand Down Expand Up @@ -99,5 +98,3 @@ T EvaluatePolynomial(const Eigen::VectorXd& coeffs, const T& x) {
}

} // namespace colmap

#endif // COLMAP_SRC_BASE_POLYNOMIAL_H_
5 changes: 1 addition & 4 deletions src/colmap/base/reconstruction.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_BASE_RECONSTRUCTION_H_
#define COLMAP_SRC_BASE_RECONSTRUCTION_H_
#pragma once

#include "colmap/base/camera.h"
#include "colmap/base/database.h"
Expand Down Expand Up @@ -653,5 +652,3 @@ bool Reconstruction::AlignRobust(const std::vector<std::string>& image_names,
}

} // namespace colmap

#endif // COLMAP_SRC_BASE_RECONSTRUCTION_H_
5 changes: 1 addition & 4 deletions src/colmap/base/reconstruction_manager.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_BASE_RECONSTRUCTION_MANAGER_H_
#define COLMAP_SRC_BASE_RECONSTRUCTION_MANAGER_H_
#pragma once

#include "colmap/base/reconstruction.h"

Expand Down Expand Up @@ -79,5 +78,3 @@ class ReconstructionManager {
};

} // namespace colmap

#endif // COLMAP_SRC_BASE_RECONSTRUCTION_MANAGER_H_
5 changes: 1 addition & 4 deletions src/colmap/base/scene_clustering.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_BASE_SCENE_CLUSTERING_H_
#define COLMAP_SRC_BASE_SCENE_CLUSTERING_H_
#pragma once

#include "colmap/base/database.h"
#include "colmap/util/types.h"
Expand Down Expand Up @@ -98,5 +97,3 @@ class SceneClustering {
};

} // namespace colmap

#endif // COLMAP_SRC_BASE_SCENE_CLUSTERING_H_
5 changes: 1 addition & 4 deletions src/colmap/base/track.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_BASE_TRACK_H_
#define COLMAP_SRC_BASE_TRACK_H_
#pragma once

#include "colmap/util/logging.h"
#include "colmap/util/types.h"
Expand Down Expand Up @@ -135,5 +134,3 @@ void Track::Reserve(const size_t num_elements) {
void Track::Compress() { elements_.shrink_to_fit(); }

} // namespace colmap

#endif // COLMAP_SRC_BASE_TRACK_H_
5 changes: 1 addition & 4 deletions src/colmap/base/visibility_pyramid.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_BASE_VISIBILITY_PYRAMID_H_
#define COLMAP_SRC_BASE_VISIBILITY_PYRAMID_H_
#pragma once

#include <vector>

Expand Down Expand Up @@ -101,5 +100,3 @@ size_t VisibilityPyramid::Score() const { return score_; }
size_t VisibilityPyramid::MaxScore() const { return max_score_; }

} // namespace colmap

#endif // COLMAP_SRC_BASE_VISIBILITY_PYRAMID_H_
5 changes: 1 addition & 4 deletions src/colmap/camera/database.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_CAMERA_CAMERA_DATABASE_H_
#define COLMAP_SRC_CAMERA_CAMERA_DATABASE_H_
#pragma once

#include "colmap/camera/specs.h"

Expand All @@ -55,5 +54,3 @@ class CameraDatabase {
};

} // namespace colmap

#endif // COLMAP_SRC_CAMERA_CAMERA_DATABASE_H_
5 changes: 1 addition & 4 deletions src/colmap/camera/models.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_CAMERA_CAMERA_MODELS_H_
#define COLMAP_SRC_CAMERA_CAMERA_MODELS_H_
#pragma once

#include <cfloat>
#include <string>
Expand Down Expand Up @@ -1550,5 +1549,3 @@ double CameraModelImageToWorldThreshold(const int model_id,
}

} // namespace colmap

#endif // COLMAP_SRC_CAMERA_CAMERA_MODELS_H_
5 changes: 1 addition & 4 deletions src/colmap/camera/specs.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_CAMERA_SPECS_H_
#define COLMAP_SRC_CAMERA_SPECS_H_
#pragma once

#include <string>
#include <unordered_map>
Expand All @@ -45,5 +44,3 @@ typedef std::unordered_map<std::string, camera_make_specs_t> camera_specs_t;
camera_specs_t InitializeCameraSpecs();

} // namespace colmap

#endif // COLMAP_SRC_CAMERA_SPECS_H_
5 changes: 1 addition & 4 deletions src/colmap/controllers/automatic_reconstruction.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_CONTROLLERS_AUTOMATIC_RECONSTRUCTION_H_
#define COLMAP_SRC_CONTROLLERS_AUTOMATIC_RECONSTRUCTION_H_
#pragma once

#include "colmap/base/reconstruction_manager.h"
#include "colmap/util/option_manager.h"
Expand Down Expand Up @@ -126,5 +125,3 @@ class AutomaticReconstructionController : public Thread {
};

} // namespace colmap

#endif // COLMAP_SRC_CONTROLLERS_AUTOMATIC_RECONSTRUCTION_H_
5 changes: 1 addition & 4 deletions src/colmap/controllers/bundle_adjustment.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_CONTROLLERS_BUNDLE_ADJUSTMENT_H_
#define COLMAP_SRC_CONTROLLERS_BUNDLE_ADJUSTMENT_H_
#pragma once

#include "colmap/base/reconstruction.h"
#include "colmap/util/option_manager.h"
Expand All @@ -52,5 +51,3 @@ class BundleAdjustmentController : public Thread {
};

} // namespace colmap

#endif // COLMAP_SRC_CONTROLLERS_BUNDLE_ADJUSTMENT_H_
5 changes: 1 addition & 4 deletions src/colmap/controllers/hierarchical_mapper.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_CONTROLLERS_HIERARCHICAL_MAPPER_H_
#define COLMAP_SRC_CONTROLLERS_HIERARCHICAL_MAPPER_H_
#pragma once

#include "colmap/base/reconstruction_manager.h"
#include "colmap/base/scene_clustering.h"
Expand Down Expand Up @@ -78,5 +77,3 @@ class HierarchicalMapperController : public Thread {
};

} // namespace colmap

#endif // COLMAP_SRC_CONTROLLERS_HIERARCHICAL_MAPPER_H_
5 changes: 1 addition & 4 deletions src/colmap/controllers/incremental_mapper.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_CONTROLLERS_INCREMENTAL_MAPPER_H_
#define COLMAP_SRC_CONTROLLERS_INCREMENTAL_MAPPER_H_
#pragma once

#include "colmap/base/reconstruction_manager.h"
#include "colmap/sfm/incremental_mapper.h"
Expand Down Expand Up @@ -188,5 +187,3 @@ size_t CompleteAndMergeTracks(const IncrementalMapperOptions& options,
IncrementalMapper* mapper);

} // namespace colmap

#endif // COLMAP_SRC_CONTROLLERS_INCREMENTAL_MAPPER_H_
5 changes: 1 addition & 4 del 10799 etions src/colmap/estimators/absolute_pose.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_ESTIMATORS_ABSOLUTE_POSE_H_
#define COLMAP_SRC_ESTIMATORS_ABSOLUTE_POSE_H_
#pragma once

#include "colmap/util/types.h"

Expand Down Expand Up @@ -180,5 +179,3 @@ class EPNPEstimator {
};

} // namespace colmap

#endif // COLMAP_SRC_ESTIMATORS_ABSOLUTE_POSE_H_
5 changes: 1 addition & 4 deletions src/colmap/estimators/affine_transform.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
//
// Author: Johannes L. Schoenberger (jsch-at-demuc-dot-de)

#ifndef COLMAP_SRC_ESTIMATORS_AFFINE_TRANSFORM_H_
#define COLMAP_SRC_ESTIMATORS_AFFINE_TRANSFORM_H_
#pragma once

#include "colmap/util/types.h"

Expand Down Expand Up @@ -61,5 +60,3 @@ class AffineTransformEstimator {
};

} // namespace colmap

#endif // COLMAP_SRC_ESTIMATORS_AFFINE_TRANSFORM_H_
Loading
0