Rerun C++ SDK
Loading...
Searching...
No Matches
view_dir.hpp
1// DO NOT EDIT! This file was auto-generated by crates/build/re_types_builder/src/codegen/cpp/mod.rs
2// Based on "crates/build/re_type_definitions/rerun/datatypes/view_dir.def.rs".
3
4#pragma once
5
6#include "../result.hpp"
7
8#include <cstdint>
9#include <memory>
10
11namespace arrow {
12 /// \private
13 template <typename T>
14 class NumericBuilder;
15
16 class Array;
17 class DataType;
18 class UInt8Type;
19 using UInt8Builder = NumericBuilder<UInt8Type>;
20} // namespace arrow
21
22namespace rerun::datatypes {
23 /// **Datatype**: The six cardinal directions for 3D view-space.
24 ///
25 /// Note that these are abstract directions and do on their own not correspond to any specific
26 /// coordinate system or numerical values.
27 enum class ViewDir : uint8_t {
28
29 /// Up.
30 Up = 1,
31
32 /// Down.
33 Down = 2,
34
35 /// Right.
36 Right = 3,
37
38 /// Left.
39 Left = 4,
40
41 /// Forward.
42 Forward = 5,
43
44 /// Back.
45 Back = 6,
46 };
47} // namespace rerun::datatypes
48
49namespace rerun {
50 template <typename T>
51 struct Loggable;
52
53 /// \private
54 template <>
55 struct Loggable<datatypes::ViewDir> {
56 static constexpr std::string_view ComponentType = "rerun.datatypes.ViewDir";
57
58 /// Returns the arrow data type this type corresponds to.
59 static const std::shared_ptr<arrow::DataType>& arrow_datatype();
60
61 /// Serializes an array of `rerun::datatypes::ViewDir` into an arrow array.
62 static Result<std::shared_ptr<arrow::Array>> to_arrow(
63 const datatypes::ViewDir* instances, size_t num_instances
64 );
65
66 /// Fills an arrow array builder with an array of this type.
67 static rerun::Error fill_arrow_array_builder(
68 arrow::UInt8Builder* builder, const datatypes::ViewDir* elements, size_t num_elements
69 );
70 };
71} // namespace rerun
Status outcome object (success or error) returned for fallible operations.
Definition error.hpp:103
All built-in datatypes. See Types in the Rerun manual.
Definition rerun.hpp:93
ViewDir
Datatype: The six cardinal directions for 3D view-space.
Definition view_dir.hpp:27
All Rerun C++ types and functions are in the rerun namespace or one of its nested namespaces.
Definition rerun.hpp:23