MayaFlux 1.0.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ to_nddata()

template<typename T >
requires (ArithmeticData<T> && DataVariantElement<T>)
std::optional< CompositeProjection > MayaFlux::Kakshya::CompositeArray::to_nddata ( std::string_view  field_name) const

Materialize one exact-type numeric field as homogeneous NDData.

Template Parameters
TDeclared field type and supported DataVariant element type.
Parameters
field_nameField to project.
Returns
Values, presence mask, and dimension metadata; std::nullopt if the field is absent from the layout or its type differs from T.
Note
This copies selected values. Packed storage remains available without copying through access() and element_data().

Definition at line 244 of file CompositeAccess.hpp.

245{
246 const auto selection = slice(0, size());
247 return selection ? selection->to_nddata<T>(field_name) : std::nullopt;
248}
size_t size() const noexcept
Number of packed elements.
std::optional< CompositeSlice > slice(size_t start, size_t count) const
Borrow consecutive elements without copying.

References size.