Blender  V3.3
Public Member Functions | List of all members
blender::bke::DataTypeConversions Class Reference

#include <BKE_type_conversions.hh>

Public Member Functions

void add (fn::MFDataType from_type, fn::MFDataType to_type, const fn::MultiFunction &fn, void(*convert_single_to_initialized)(const void *src, void *dst), void(*convert_single_to_uninitialized)(const void *src, void *dst))
 
const ConversionFunctionsget_conversion_functions (fn::MFDataType from, fn::MFDataType to) const
 
const ConversionFunctionsget_conversion_functions (const CPPType &from, const CPPType &to) const
 
const fn::MultiFunctionget_conversion_multi_function (fn::MFDataType from, fn::MFDataType to) const
 
bool is_convertible (const CPPType &from_type, const CPPType &to_type) const
 
void convert_to_uninitialized (const CPPType &from_type, const CPPType &to_type, const void *from_value, void *to_value) const
 
void convert_to_initialized_n (GSpan from_span, GMutableSpan to_span) const
 
GVArray try_convert (GVArray varray, const CPPType &to_type) const
 
GVMutableArray try_convert (GVMutableArray varray, const CPPType &to_type) const
 
fn::GField try_convert (fn::GField field, const CPPType &to_type) const
 

Detailed Description

Definition at line 16 of file BKE_type_conversions.hh.

Member Function Documentation

◆ add()

void blender::bke::DataTypeConversions::add ( fn::MFDataType  from_type,
fn::MFDataType  to_type,
const fn::MultiFunction fn,
void(*)(const void *src, void *dst)  convert_single_to_initialized,
void(*)(const void *src, void *dst)  convert_single_to_uninitialized 
)
inline

◆ convert_to_initialized_n()

void blender::bke::DataTypeConversions::convert_to_initialized_n ( GSpan  from_span,
GMutableSpan  to_span 
) const

◆ convert_to_uninitialized()

void blender::bke::DataTypeConversions::convert_to_uninitialized ( const CPPType from_type,
const CPPType to_type,
const void from_value,
void to_value 
) const

◆ get_conversion_functions() [1/2]

const ConversionFunctions* blender::bke::DataTypeConversions::get_conversion_functions ( const CPPType from,
const CPPType to 
) const
inline

◆ get_conversion_functions() [2/2]

const ConversionFunctions* blender::bke::DataTypeConversions::get_conversion_functions ( fn::MFDataType  from,
fn::MFDataType  to 
) const
inline

◆ get_conversion_multi_function()

const fn::MultiFunction* blender::bke::DataTypeConversions::get_conversion_multi_function ( fn::MFDataType  from,
fn::MFDataType  to 
) const
inline

Definition at line 42 of file BKE_type_conversions.hh.

References functions, and get_conversion_functions().

Referenced by convert_to_initialized_n(), and try_convert().

◆ is_convertible()

bool blender::bke::DataTypeConversions::is_convertible ( const CPPType from_type,
const CPPType to_type 
) const
inline

◆ try_convert() [1/3]

fn::GField blender::bke::DataTypeConversions::try_convert ( fn::GField  field,
const CPPType to_type 
) const

◆ try_convert() [2/3]

GVArray blender::bke::DataTypeConversions::try_convert ( GVArray  varray,
const CPPType to_type 
) const

◆ try_convert() [3/3]

GVMutableArray blender::bke::DataTypeConversions::try_convert ( GVMutableArray  varray,
const CPPType to_type 
) const

The documentation for this class was generated from the following files: