Nest some more namespaces
Did someone previously suggest that all namespace had been
nested? Silly.
Signed-off-by: Stephan Pleines <pleines.stephan@gmail.com>
Change-Id: I22278c1caaeba8b47dc46fb2ed3078c20a11e190
diff --git a/y2022/vision/ball_color.h b/y2022/vision/ball_color.h
index 695d2e3..824cf30 100644
--- a/y2022/vision/ball_color.h
+++ b/y2022/vision/ball_color.h
@@ -9,8 +9,7 @@
#include "y2022/constants.h"
#include "y2022/vision/ball_color_generated.h"
-namespace y2022 {
-namespace vision {
+namespace y2022::vision {
using namespace frc971::vision;
@@ -62,6 +61,5 @@
const cv::Rect reference_blue_;
const cv::Rect ball_location_;
};
-} // namespace vision
-} // namespace y2022
+} // namespace y2022::vision
#endif
diff --git a/y2022/vision/blob_detector.h b/y2022/vision/blob_detector.h
index a60316a..93bba09 100644
--- a/y2022/vision/blob_detector.h
+++ b/y2022/vision/blob_detector.h
@@ -4,8 +4,7 @@
#include <opencv2/features2d.hpp>
#include <opencv2/imgproc.hpp>
-namespace y2022 {
-namespace vision {
+namespace y2022::vision {
class BlobDetector {
public:
@@ -52,7 +51,6 @@
static void ExtractBlobs(cv::Mat bgr_image, BlobResult *blob_result);
};
-} // namespace vision
-} // namespace y2022
+} // namespace y2022::vision
#endif // Y2022_BLOB_DETECTOR_H_
diff --git a/y2022/vision/camera_reader.h b/y2022/vision/camera_reader.h
index 8782886..54fcb30 100644
--- a/y2022/vision/camera_reader.h
+++ b/y2022/vision/camera_reader.h
@@ -20,8 +20,7 @@
#include "y2022/vision/target_estimate_generated.h"
#include "y2022/vision/target_estimator.h"
-namespace y2022 {
-namespace vision {
+namespace y2022::vision {
using namespace frc971::vision;
using frc971::controls::LedOutput;
@@ -163,6 +162,5 @@
GPIOControl gpio_disable_control_;
};
-} // namespace vision
-} // namespace y2022
+} // namespace y2022::vision
#endif // Y2022_VISION_CAMERA_READER_H_
diff --git a/y2022/vision/gpio.h b/y2022/vision/gpio.h
index 6ed7328..d7b44d4 100644
--- a/y2022/vision/gpio.h
+++ b/y2022/vision/gpio.h
@@ -14,8 +14,7 @@
#include "aos/init.h"
-namespace y2022 {
-namespace vision {
+namespace y2022::vision {
using namespace frc971::vision;
@@ -353,6 +352,5 @@
aos::TimerHandler *const pwm_timer_;
};
-} // namespace vision
-} // namespace y2022
+} // namespace y2022::vision
#endif // Y2022_VISION_GPIO_H_