From fbf7380eebe7bddf8373943fe4febec30ba67b35 Mon Sep 17 00:00:00 2001 From: Wylder Keane <5810110+wylderkeane@users.noreply.github.com> Date: Mon, 9 Oct 2023 15:27:02 -0700 Subject: [PATCH 1/2] Add a method for pixel size in sophus::ImageView (#181) Add `pixelSize()` to `ImageView` class to enable subview image size calculations in bytes. --- cpp/sophus/image/image_view.h | 1 + 1 file changed, 1 insertion(+) diff --git a/cpp/sophus/image/image_view.h b/cpp/sophus/image/image_view.h index 64f525ff..31938b17 100644 --- a/cpp/sophus/image/image_view.h +++ b/cpp/sophus/image/image_view.h @@ -94,6 +94,7 @@ struct ImageView { [[nodiscard]] auto sizeBytes() const -> size_t { return layout().sizeBytes(); } + [[nodiscard]] auto pixelSize() const -> size_t { return sizeof(Pixel); } /// Returns true if u is in [0, width). [[nodiscard]] auto colInBounds(int u) const -> bool { From bc9a04a2e0e792c517eb3192a0980e5652eab19a Mon Sep 17 00:00:00 2001 From: Ethan Rublee Date: Sun, 8 Oct 2023 17:55:27 +0000 Subject: [PATCH 2/2] Remove some unused protobuf imports. --- protos/farm_ng/core/event_service.proto | 1 - protos/farm_ng/core/pose.proto | 1 - 2 files changed, 2 deletions(-) diff --git a/protos/farm_ng/core/event_service.proto b/protos/farm_ng/core/event_service.proto index bebf3d20..1cd0a34e 100644 --- a/protos/farm_ng/core/event_service.proto +++ b/protos/farm_ng/core/event_service.proto @@ -15,7 +15,6 @@ syntax = "proto3"; import "farm_ng/core/uri.proto"; -import "farm_ng/core/timestamp.proto"; import "farm_ng/core/event.proto"; package farm_ng.core.proto; diff --git a/protos/farm_ng/core/pose.proto b/protos/farm_ng/core/pose.proto index e2af5fac..88781764 100644 --- a/protos/farm_ng/core/pose.proto +++ b/protos/farm_ng/core/pose.proto @@ -15,7 +15,6 @@ syntax = "proto3"; import "farm_ng/core/lie.proto"; -import "farm_ng/core/linalg.proto"; package farm_ng.core.proto;