6#include "../collection.hpp"
7#include "../compiler_utils.hpp"
8#include "../components/pinhole_projection.hpp"
9#include "../components/resolution.hpp"
10#include "../components/view_coordinates.hpp"
11#include "../data_cell.hpp"
12#include "../indicator_component.hpp"
13#include "../result.hpp"
91 std::optional<rerun::components::ViewCoordinates>
camera_xyz;
94 static constexpr const char IndicatorComponentName[] =
"rerun.components.PinholeIndicator";
130 return std::move(*
this);
138 return std::move(*
this);
159 RERUN_WITH_MAYBE_UNINITIALIZED_DISABLED(
return std::move(*
this);)
192 RERUN_WITH_MAYBE_UNINITIALIZED_DISABLED(
return std::move(*
this);)
205 template <
typename T>
210 struct AsComponents<archetypes::Pinhole> {
212 static Result<std::vector<DataCell>> serialize(
const archetypes::Pinhole& archetype);
All built-in archetypes. See Types in the Rerun manual.
Definition rerun.hpp:66
All Rerun C++ types and functions are in the rerun namespace or one of its nested namespaces.
Definition rerun.hpp:20
Archetype: Camera perspective projection (a.k.a.
Definition pinhole.hpp:50
rerun::components::PinholeProjection image_from_camera
Camera projection, from image coordinates to view coordinates.
Definition pinhole.hpp:52
Pinhole with_resolution(float width, float height) &&
Pixel resolution (usually integers) of child image space.
Definition pinhole.hpp:128
size_t num_instances() const
Returns the number of primary instances of this archetype.
Definition pinhole.hpp:196
Pinhole with_resolution(int width, int height) &&
Pixel resolution (usually integers) of child image space.
Definition pinhole.hpp:136
std::optional< rerun::components::ViewCoordinates > camera_xyz
Sets the view coordinates for the camera.
Definition pinhole.hpp:91
std::optional< rerun::components::Resolution > resolution
Pixel resolution (usually integers) of child image space.
Definition pinhole.hpp:62
static Pinhole from_focal_length_and_resolution(const datatypes::Vec2D &focal_length, const datatypes::Vec2D &resolution)
Creates a pinhole from the camera focal length and resolution, both specified in pixels.
Pinhole with_resolution(rerun::components::Resolution _resolution) &&
Pixel resolution (usually integers) of child image space.
Definition pinhole.hpp:156
static Pinhole from_focal_length_and_resolution(float focal_length, const datatypes::Vec2D &resolution)
Creates a symmetric pinhole from the camera focal length and resolution, both specified in pixels.
Definition pinhole.hpp:119
Pinhole with_camera_xyz(rerun::components::ViewCoordinates _camera_xyz) &&
Sets the view coordinates for the camera.
Definition pinhole.hpp:189
Indicator component used by archetypes when converting them to component lists.
Definition indicator_component.hpp:23
Component: Camera projection, from image coordinates to view coordinates.
Definition pinhole_projection.hpp:31
Component: Pixel resolution width & height, e.g.
Definition resolution.hpp:23
Component: How we interpret the coordinate system of an entity/space.
Definition view_coordinates.hpp:35
Datatype: A vector in 2D space.
Definition vec2d.hpp:20