Skip to content

Commit

Permalink
Use arrow1 in custom-data tutorial
Browse files Browse the repository at this point in the history
  • Loading branch information
emilk committed Jan 6, 2025
1 parent abafb4a commit 83f0565
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions docs/snippets/all/tutorials/custom_data.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
use rerun::{
demo_util::grid,
external::{arrow2, glam, re_types},
external::{arrow, glam, re_types},
ComponentBatch,
};

Expand Down Expand Up @@ -68,18 +68,18 @@ impl rerun::SizeBytes for Confidence {

impl rerun::Loggable for Confidence {
#[inline]
fn arrow2_datatype() -> arrow2::datatypes::DataType {
rerun::Float32::arrow2_datatype()
fn arrow_datatype() -> arrow::datatypes::DataType {
rerun::Float32::arrow_datatype()
}

#[inline]
fn to_arrow2_opt<'a>(
fn to_arrow_opt<'a>(
data: impl IntoIterator<Item = Option<impl Into<std::borrow::Cow<'a, Self>>>>,
) -> re_types::SerializationResult<Box<dyn arrow2::array::Array>>
) -> re_types::SerializationResult<Box<dyn arrow::array::Array>>
where
Self: 'a,
{
rerun::Float32::to_arrow2_opt(data.into_iter().map(|opt| opt.map(Into::into).map(|c| c.0)))
rerun::Float32::to_arrow_opt(data.into_iter().map(|opt| opt.map(Into::into).map(|c| c.0)))
}
}

Expand Down

0 comments on commit 83f0565

Please sign in to comment.