6#include "../collection.hpp"
7#include "../component_batch.hpp"
8#include "../component_column.hpp"
9#include "../components/blob.hpp"
10#include "../components/media_type.hpp"
11#include "../indicator_component.hpp"
12#include "../result.hpp"
117 std::optional<ComponentBatch>
blob;
129 static constexpr const char IndicatorComponentName[] =
130 "rerun.components.AssetVideoIndicator";
135 static constexpr const char ArchetypeName[] =
"rerun.archetypes.AssetVideo";
162 std::optional<rerun::components::MediaType>
media_type = {}
167 return std::move(asset).with_media_type(
media_type.value());
201 return std::move(*
this);
210 return std::move(*
this);
223 return std::move(*
this);
234 return std::move(*
this);
258 template <
typename T>
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 built-in archetypes. See Types in the Rerun manual.
Definition rerun.hpp:76
All Rerun C++ types and functions are in the rerun namespace or one of its nested namespaces.
Definition rerun.hpp:23
Arrow-encoded data of a single batch of components together with a component descriptor.
Definition component_batch.hpp:28
static Result< ComponentBatch > from_loggable(const rerun::Collection< T > &components, const ComponentDescriptor &descriptor=rerun::Loggable< T >::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:14
The Loggable trait is used by all built-in implementation of rerun::AsComponents to serialize a colle...
Definition loggable.hpp:11
Archetype: A video binary.
Definition asset_video.hpp:115
static constexpr auto Descriptor_media_type
ComponentDescriptor for the media_type field.
Definition asset_video.hpp:142
static AssetVideo clear_fields()
Clear all the fields of a AssetVideo.
AssetVideo with_many_blob(const Collection< rerun::components::Blob > &_blob) &&
This method makes it possible to pack multiple blob in a single component batch.
Definition asset_video.hpp:208
std::optional< ComponentBatch > media_type
The Media Type of the asset.
Definition asset_video.hpp:126
Collection< ComponentColumn > columns(const Collection< uint32_t > &lengths_)
Partitions the component data into multiple sub-batches.
static AssetVideo from_bytes(rerun::Collection< uint8_t > bytes, std::optional< rerun::components::MediaType > media_type={})
Creates a new AssetVideo from the given bytes.
Definition asset_video.hpp:160
static Result< AssetVideo > from_file(const std::filesystem::path &path)
Creates a new AssetVideo from the file contents at path.
AssetVideo with_media_type(const rerun::components::MediaType &_media_type) &&
The Media Type of the asset.
Definition asset_video.hpp:220
static AssetVideo update_fields()
Update only some specific fields of a AssetVideo.
Definition asset_video.hpp:191
static constexpr auto Descriptor_blob
ComponentDescriptor for the blob field.
Definition asset_video.hpp:138
AssetVideo with_blob(const rerun::components::Blob &_blob) &&
The asset's bytes.
Definition asset_video.hpp:199
Collection< ComponentColumn > columns()
Partitions the component data into unit-length sub-batches.
static constexpr const char ArchetypeName[]
The name of the archetype as used in ComponentDescriptors.
Definition asset_video.hpp:135
AssetVideo with_many_media_type(const Collection< rerun::components::MediaType > &_media_type) &&
This method makes it possible to pack multiple media_type in a single component batch.
Definition asset_video.hpp:230
std::optional< ComponentBatch > blob
The asset's bytes.
Definition asset_video.hpp:117
Result< std::vector< std::chrono::nanoseconds > > read_frame_timestamps_ns() const
Determines the presentation timestamps of all frames inside the video.
Component: A binary blob of data.
Definition blob.hpp:17
Indicator component used by archetypes when converting them to component lists.
Definition indicator_component.hpp:32