Rerun C++ SDK
|
Archetype: 3D arrows with optional colors, radii, labels, etc. More...
#include <rerun/archetypes/arrows3d.hpp>
Public Types | |
using | IndicatorComponent = rerun::components::IndicatorComponent< IndicatorComponentName > |
Indicator component, used to identify the archetype when converting to a list of components. | |
Public Member Functions | |
Arrows3D (Arrows3D &&other)=default | |
Arrows3D (const Arrows3D &other)=default | |
Arrows3D & | operator= (const Arrows3D &other)=default |
Arrows3D & | operator= (Arrows3D &&other)=default |
Arrows3D | with_vectors (const Collection< rerun::components::Vector3D > &_vectors) && |
All the vectors for each arrow in the batch. | |
Arrows3D | with_origins (const Collection< rerun::components::Position3D > &_origins) && |
All the origin (base) positions for each arrow in the batch. | |
Arrows3D | with_radii (const Collection< rerun::components::Radius > &_radii) && |
Optional radii for the arrows. | |
Arrows3D | with_colors (const Collection< rerun::components::Color > &_colors) && |
Optional colors for the points. | |
Arrows3D | with_labels (const Collection< rerun::components::Text > &_labels) && |
Optional text labels for the arrows. | |
Arrows3D | with_show_labels (const rerun::components::ShowLabels &_show_labels) && |
Optional choice of whether the text labels should be shown by default. | |
Arrows3D | with_many_show_labels (const Collection< rerun::components::ShowLabels > &_show_labels) && |
This method makes it possible to pack multiple show_labels in a single component batch. | |
Arrows3D | with_class_ids (const Collection< rerun::components::ClassId > &_class_ids) && |
Optional class Ids for the points. | |
Collection< ComponentColumn > | columns (const Collection< uint32_t > &lengths_) |
Partitions the component data into multiple sub-batches. | |
Collection< ComponentColumn > | columns () |
Partitions the component data into unit-length sub-batches. | |
Static Public Member Functions | |
static Arrows3D | from_vectors (Collection< components::Vector3D > vectors_) |
Creates new 3D arrows pointing in the given directions, with a base at the origin (0, 0, 0). | |
static Arrows3D | update_fields () |
Update only some specific fields of a Arrows3D . | |
static Arrows3D | clear_fields () |
Clear all the fields of a Arrows3D . | |
Public Attributes | |
std::optional< ComponentBatch > | vectors |
All the vectors for each arrow in the batch. | |
std::optional< ComponentBatch > | origins |
All the origin (base) positions for each arrow in the batch. | |
std::optional< ComponentBatch > | radii |
Optional radii for the arrows. | |
std::optional< ComponentBatch > | colors |
Optional colors for the points. | |
std::optional< ComponentBatch > | labels |
Optional text labels for the arrows. | |
std::optional< ComponentBatch > | show_labels |
Optional choice of whether the text labels should be shown by default. | |
std::optional< ComponentBatch > | class_ids |
Optional class Ids for the points. | |
Static Public Attributes | |
static constexpr const char | IndicatorComponentName [] = "rerun.components.Arrows3DIndicator" |
static constexpr const char | ArchetypeName [] = "rerun.archetypes.Arrows3D" |
The name of the archetype as used in ComponentDescriptor s. | |
static constexpr auto | Descriptor_vectors |
ComponentDescriptor for the vectors field. | |
static constexpr auto | Descriptor_origins |
ComponentDescriptor for the origins field. | |
static constexpr auto | Descriptor_radii |
ComponentDescriptor for the radii field. | |
static constexpr auto | Descriptor_colors |
ComponentDescriptor for the colors field. | |
static constexpr auto | Descriptor_labels |
ComponentDescriptor for the labels field. | |
static constexpr auto | Descriptor_show_labels |
ComponentDescriptor for the show_labels field. | |
static constexpr auto | Descriptor_class_ids |
ComponentDescriptor for the class_ids field. | |
Archetype: 3D arrows with optional colors, radii, labels, etc.
|
inline |
All the origin (base) positions for each arrow in the batch.
If no origins are set, (0, 0, 0) is used as the origin for each arrow.
|
inline |
Optional radii for the arrows.
The shaft is rendered as a line with radius = 0.5 * radius
. The tip is rendered with height = 2.0 * radius
and radius = 1.0 * radius
.
|
inline |
Optional text labels for the arrows.
If there's a single label present, it will be placed at the center of the entity. Otherwise, each instance will have its own label.
|
inline |
This method makes it possible to pack multiple show_labels
in a single component batch.
This only makes sense when used in conjunction with columns
. with_show_labels
should be used when logging a single row's worth of data.
|
inline |
Optional class Ids for the points.
The components::ClassId
provides colors and labels if not specified explicitly.
Collection< ComponentColumn > rerun::archetypes::Arrows3D::columns | ( | const Collection< uint32_t > & | lengths_ | ) |
Partitions the component data into multiple sub-batches.
Specifically, this transforms the existing ComponentBatch
data into ComponentColumn
s instead, via ComponentBatch::partitioned
.
This makes it possible to use RecordingStream::send_columns
to send columnar data directly into Rerun.
The specified lengths
must sum to the total length of the component batch.
Collection< ComponentColumn > rerun::archetypes::Arrows3D::columns | ( | ) |
Partitions the component data into unit-length sub-batches.
This is semantically similar to calling columns
with std::vector<uint32_t>(n, 1)
, where n
is automatically guessed.
std::optional<ComponentBatch> rerun::archetypes::Arrows3D::origins |
All the origin (base) positions for each arrow in the batch.
If no origins are set, (0, 0, 0) is used as the origin for each arrow.
std::optional<ComponentBatch> rerun::archetypes::Arrows3D::radii |
Optional radii for the arrows.
The shaft is rendered as a line with radius = 0.5 * radius
. The tip is rendered with height = 2.0 * radius
and radius = 1.0 * radius
.
std::optional<ComponentBatch> rerun::archetypes::Arrows3D::labels |
Optional text labels for the arrows.
If there's a single label present, it will be placed at the center of the entity. Otherwise, each instance will have its own label.
std::optional<ComponentBatch> rerun::archetypes::Arrows3D::class_ids |
Optional class Ids for the points.
The components::ClassId
provides colors and labels if not specified explicitly.
|
staticconstexpr |
ComponentDescriptor
for the vectors
field.
|
staticconstexpr |
ComponentDescriptor
for the origins
field.
|
staticconstexpr |
ComponentDescriptor
for the radii
field.
|
staticconstexpr |
ComponentDescriptor
for the colors
field.
|
staticconstexpr |
ComponentDescriptor
for the labels
field.
|
staticconstexpr |
ComponentDescriptor
for the show_labels
field.
|
staticconstexpr |
ComponentDescriptor
for the class_ids
field.