Rerun C++ SDK
|
Archetype: A double-precision scalar, e.g. More...
#include <rerun/archetypes/scalar.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 | |
Scalar (Scalar &&other)=default | |
Scalar (const Scalar &other)=default | |
Scalar & | operator= (const Scalar &other)=default |
Scalar & | operator= (Scalar &&other)=default |
Scalar (rerun::components::Scalar _scalar) | |
Scalar | with_scalar (const rerun::components::Scalar &_scalar) && |
The scalar value to log. | |
Scalar | with_many_scalar (const Collection< rerun::components::Scalar > &_scalar) && |
This method makes it possible to pack multiple scalar in a single component batch. | |
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 Scalar | update_fields () |
Update only some specific fields of a Scalar . | |
static Scalar | clear_fields () |
Clear all the fields of a Scalar . | |
Public Attributes | |
std::optional< ComponentBatch > | scalar |
The scalar value to log. | |
Static Public Attributes | |
static constexpr const char | IndicatorComponentName [] = "rerun.components.ScalarIndicator" |
static constexpr const char | ArchetypeName [] = "rerun.archetypes.Scalar" |
The name of the archetype as used in ComponentDescriptor s. | |
static constexpr auto | Descriptor_scalar |
ComponentDescriptor for the scalar field. | |
Archetype: A double-precision scalar, e.g.
for use for time-series plots.
The current timeline value will be used for the time/X-axis, hence scalars cannot be static.
When used to produce a plot, this archetype is used to provide the data that is referenced by archetypes::SeriesLine
or archetypes::SeriesPoint
. You can do this by logging both archetypes to the same path, or alternatively configuring the plot-specific archetypes through the blueprint.
|
inline |
This method makes it possible to pack multiple scalar
in a single component batch.
This only makes sense when used in conjunction with columns
. with_scalar
should be used when logging a single row's worth of data.
Collection< ComponentColumn > rerun::archetypes::Scalar::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::Scalar::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.
|
staticconstexpr |
ComponentDescriptor
for the scalar
field.