Rerun C++ SDK
Loading...
Searching...
No Matches
rerun::blueprint::archetypes::PlotLegend Struct Reference

Archetype: Configuration for the legend of a plot. More...

#include <rerun/blueprint/archetypes/plot_legend.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

 PlotLegend (PlotLegend &&other)=default
 
 PlotLegend (const PlotLegend &other)=default
 
PlotLegendoperator= (const PlotLegend &other)=default
 
PlotLegendoperator= (PlotLegend &&other)=default
 
PlotLegend with_corner (const rerun::blueprint::components::Corner2D &_corner) &&
 To what corner the legend is aligned.
 
PlotLegend with_visible (const rerun::components::Visible &_visible) &&
 Whether the legend is shown at all.
 
Collection< ComponentColumncolumns (const Collection< uint32_t > &lengths_)
 Partitions the component data into multiple sub-batches.
 
Collection< ComponentColumncolumns ()
 Partitions the component data into unit-length sub-batches.
 

Static Public Member Functions

static PlotLegend update_fields ()
 Update only some specific fields of a PlotLegend.
 
static PlotLegend clear_fields ()
 Clear all the fields of a PlotLegend.
 

Public Attributes

std::optional< ComponentBatchcorner
 To what corner the legend is aligned.
 
std::optional< ComponentBatchvisible
 Whether the legend is shown at all.
 

Static Public Attributes

static constexpr const char IndicatorComponentName []
 
static constexpr const char ArchetypeName [] = "rerun.blueprint.archetypes.PlotLegend"
 The name of the archetype as used in ComponentDescriptors.
 
static constexpr auto Descriptor_corner
 ComponentDescriptor for the corner field.
 
static constexpr auto Descriptor_visible
 ComponentDescriptor for the visible field.
 

Detailed Description

Archetype: Configuration for the legend of a plot.

This type is unstable and may change significantly in a way that the data won't be backwards compatible.

Member Function Documentation

◆ with_corner()

PlotLegend rerun::blueprint::archetypes::PlotLegend::with_corner ( const rerun::blueprint::components::Corner2D &  _corner) &&
inline

To what corner the legend is aligned.

Defaults to the right bottom corner.

◆ with_visible()

PlotLegend rerun::blueprint::archetypes::PlotLegend::with_visible ( const rerun::components::Visible _visible) &&
inline

Whether the legend is shown at all.

True by default.

◆ columns() [1/2]

Collection< ComponentColumn > rerun::blueprint::archetypes::PlotLegend::columns ( const Collection< uint32_t > &  lengths_)

Partitions the component data into multiple sub-batches.

Specifically, this transforms the existing ComponentBatch data into ComponentColumns 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.

◆ columns() [2/2]

Collection< ComponentColumn > rerun::blueprint::archetypes::PlotLegend::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.

Member Data Documentation

◆ corner

std::optional<ComponentBatch> rerun::blueprint::archetypes::PlotLegend::corner

To what corner the legend is aligned.

Defaults to the right bottom corner.

◆ visible

std::optional<ComponentBatch> rerun::blueprint::archetypes::PlotLegend::visible

Whether the legend is shown at all.

True by default.

◆ IndicatorComponentName

constexpr const char rerun::blueprint::archetypes::PlotLegend::IndicatorComponentName[]
staticconstexpr
Initial value:
=
"rerun.blueprint.components.PlotLegendIndicator"

◆ Descriptor_corner

constexpr auto rerun::blueprint::archetypes::PlotLegend::Descriptor_corner
staticconstexpr
Initial value:
= ComponentDescriptor(
ArchetypeName, "corner",
Loggable<rerun::blueprint::components::Corner2D>::Descriptor.component_name
)
static constexpr const char ArchetypeName[]
The name of the archetype as used in ComponentDescriptors.
Definition plot_legend.hpp:42

ComponentDescriptor for the corner field.

◆ Descriptor_visible

constexpr auto rerun::blueprint::archetypes::PlotLegend::Descriptor_visible
staticconstexpr
Initial value:
= ComponentDescriptor(
ArchetypeName, "visible",
Loggable<rerun::components::Visible>::Descriptor.component_name
)

ComponentDescriptor for the visible field.


The documentation for this struct was generated from the following file: