1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
use arrow2_convert::{ArrowDeserialize, ArrowField, ArrowSerialize};

use crate::Component;

/// A Radius component
///
/// ## Examples
///
/// ```
/// # use re_log_types::component_types::Radius;
/// # use arrow2_convert::field::ArrowField;
/// # use arrow2::datatypes::{DataType, Field};
/// assert_eq!(Radius::data_type(), DataType::Float32);
/// ```
#[derive(Debug, Clone, Copy, ArrowField, ArrowSerialize, ArrowDeserialize)]
#[arrow_field(transparent)]
pub struct Radius(pub f32);

impl Component for Radius {
    #[inline]
    fn name() -> crate::ComponentName {
        "rerun.radius".into()
    }
}