6#include "../../archetype_utils.hpp"
7#include "../../blueprint/components/angular_speed.hpp"
8#include "../../blueprint/components/eye3d_kind.hpp"
9#include "../../collection.hpp"
10#include "../../component_batch.hpp"
11#include "../../component_column.hpp"
12#include "../../components/entity_path.hpp"
13#include "../../components/linear_speed.hpp"
14#include "../../components/position3d.hpp"
15#include "../../components/vector3d.hpp"
16#include "../../result.hpp"
23namespace rerun::blueprint::archetypes {
35 std::optional<ComponentBatch>
kind;
51 std::optional<ComponentBatch>
eye_up;
58 std::optional<ComponentBatch>
speed;
72 static constexpr const char ArchetypeName[] =
"rerun.blueprint.archetypes.EyeControls3D";
131 return std::move(*
this);
138 return std::move(*
this);
149 return std::move(*
this);
158 return std::move(*
this);
168 return std::move(*
this);
179 return std::move(*
this);
189 return std::move(*
this);
201 return detail::partition_batches(
219 return detail::partition_batches_of_unit_length({&
kind,
234 template <
typename T>
239 struct AsComponents<blueprint::archetypes::EyeControls3D> {
244 return detail::collect_batches(
Generic collection of elements that are roughly contiguous in memory.
Definition collection.hpp:49
A class for representing either a usable value, or an error.
Definition result.hpp:14
All Rerun C++ types and functions are in the rerun namespace or one of its nested namespaces.
Definition rerun.hpp:26
static Result< ComponentBatch > from_loggable(const rerun::Collection< T > &components, const ComponentDescriptor &descriptor)
Creates a new component batch from a collection of component instances.
Definition component_batch.hpp:46
A ComponentDescriptor fully describes the semantics of a column of data.
Definition component_descriptor.hpp:16
The Loggable trait is used by all built-in implementation of rerun::AsComponents to serialize a colle...
Definition loggable.hpp:11
Archetype: The controls for the 3D eye in a spatial 3D view.
Definition eye_controls3d.hpp:30
static constexpr auto Descriptor_kind
ComponentDescriptor for the kind field.
Definition eye_controls3d.hpp:75
std::optional< ComponentBatch > kind
The kind of the eye for the spatial 3D view.
Definition eye_controls3d.hpp:35
EyeControls3D with_position(const rerun::components::Position3D &_position) &&
The cameras current position.
Definition eye_controls3d.hpp:135
static constexpr auto Descriptor_tracking_entity
ComponentDescriptor for the tracking_entity field.
Definition eye_controls3d.hpp:100
std::optional< ComponentBatch > look_target
The position the camera is currently looking at.
Definition eye_controls3d.hpp:45
std::optional< ComponentBatch > eye_up
The up-axis of the eye itself, in world-space.
Definition eye_controls3d.hpp:51
static EyeControls3D clear_fields()
Clear all the fields of a EyeControls3D.
static constexpr const char ArchetypeName[]
The name of the archetype as used in ComponentDescriptors.
Definition eye_controls3d.hpp:72
static constexpr auto Descriptor_position
ComponentDescriptor for the position field.
Definition eye_controls3d.hpp:80
EyeControls3D with_kind(const rerun::blueprint::components::Eye3DKind &_kind) &&
The kind of the eye for the spatial 3D view.
Definition eye_controls3d.hpp:129
EyeControls3D with_speed(const rerun::components::LinearSpeed &_speed) &&
Translation speed of the eye in the view (when using WASDQE keys to move in the 3D scene).
Definition eye_controls3d.hpp:166
EyeControls3D with_eye_up(const rerun::components::Vector3D &_eye_up) &&
The up-axis of the eye itself, in world-space.
Definition eye_controls3d.hpp:156
static constexpr auto Descriptor_eye_up
ComponentDescriptor for the eye_up field.
Definition eye_controls3d.hpp:90
std::optional< ComponentBatch > speed
Translation speed of the eye in the view (when using WASDQE keys to move in the 3D scene).
Definition eye_controls3d.hpp:58
static EyeControls3D update_fields()
Update only some specific fields of a EyeControls3D.
Definition eye_controls3d.hpp:118
Collection< ComponentColumn > columns(const Collection< uint32_t > &lengths_)
Partitions the component data into multiple sub-batches.
Definition eye_controls3d.hpp:200
static constexpr auto Descriptor_look_target
ComponentDescriptor for the look_target field.
Definition eye_controls3d.hpp:85
EyeControls3D with_look_target(const rerun::components::Position3D &_look_target) &&
The position the camera is currently looking at.
Definition eye_controls3d.hpp:146
Collection< ComponentColumn > columns()
Partitions the component data into unit-length sub-batches.
Definition eye_controls3d.hpp:218
static constexpr auto Descriptor_spin_speed
ComponentDescriptor for the spin_speed field.
Definition eye_controls3d.hpp:105
static constexpr auto Descriptor_speed
ComponentDescriptor for the speed field.
Definition eye_controls3d.hpp:95
std::optional< ComponentBatch > position
The cameras current position.
Definition eye_controls3d.hpp:38
EyeControls3D with_spin_speed(const rerun::blueprint::components::AngularSpeed &_spin_speed) &&
What speed, if any, the camera should spin around the eye-up axis.
Definition eye_controls3d.hpp:185
std::optional< ComponentBatch > tracking_entity
Currently tracked entity.
Definition eye_controls3d.hpp:63
EyeControls3D with_tracking_entity(const rerun::components::EntityPath &_tracking_entity) &&
Currently tracked entity.
Definition eye_controls3d.hpp:174
std::optional< ComponentBatch > spin_speed
What speed, if any, the camera should spin around the eye-up axis.
Definition eye_controls3d.hpp:68
Component: Angular speed, used for rotation speed for example.
Definition angular_speed.hpp:17
Component: A path to an entity, usually to reference some data that is part of the target entity.
Definition entity_path.hpp:16
Component: Linear speed, used for translation speed for example.
Definition linear_speed.hpp:14
Component: A position in 3D space.
Definition position3d.hpp:15
Component: A vector in 3D space.
Definition vector3d.hpp:15