6#include "../datatypes/uvec3d.hpp"
7#include "../result.hpp"
24 : indices{indices_[0], indices_[1], indices_[2]} {}
38 TriangleIndices(std::array<uint32_t, 3> xyz_) : indices(xyz_) {}
57 struct Loggable<components::TriangleIndices> {
58 static constexpr const char Name[] =
"rerun.components.TriangleIndices";
61 static const std::shared_ptr<arrow::DataType>& arrow_datatype() {
62 return Loggable<rerun::datatypes::UVec3D>::arrow_datatype();
66 static Result<std::shared_ptr<arrow::Array>> to_arrow(
67 const components::TriangleIndices* instances,
size_t num_instances
69 if (num_instances == 0) {
70 return Loggable<rerun::datatypes::UVec3D>::to_arrow(
nullptr, 0);
71 }
else if (instances ==
nullptr) {
73 ErrorCode::UnexpectedNullArgument,
74 "Passed array instances is null when num_elements> 0."
77 return Loggable<rerun::datatypes::UVec3D>::to_arrow(
Status outcome object (success or error) returned for fallible operations.
Definition error.hpp:95
All built-in components. See Types in the Rerun manual.
Definition rerun.hpp:79
All Rerun C++ types and functions are in the rerun namespace or one of its nested namespaces.
Definition rerun.hpp:22
Component: The three indices of a triangle in a triangle mesh.
Definition triangle_indices.hpp:15
TriangleIndices(const uint32_t *indices_)
Construct UVec3D from v0/v1/v2 uint32_t pointer.
Definition triangle_indices.hpp:23
TriangleIndices(uint32_t v0, uint32_t v1, uint32_t v2)
Construct TriangleIndices from v0/v1/v2 values.
Definition triangle_indices.hpp:20
Datatype: A uint32 vector in 3D space.
Definition uvec3d.hpp:20