Blender V4.3
blender::bke::attribute_math::SimpleMixer< T > Class Template Reference

#include <BKE_attribute_math.hh>

Public Member Functions

 SimpleMixer (MutableSpan< T > buffer, T default_value={})
 
 SimpleMixer (MutableSpan< T > buffer, const IndexMask &mask, T default_value={})
 
void set (const int64_t index, const T &value, const float weight=1.0f)
 
void mix_in (const int64_t index, const T &value, const float weight=1.0f)
 
void finalize ()
 
void finalize (const IndexMask &mask)
 

Detailed Description

template<typename T>
class blender::bke::attribute_math::SimpleMixer< T >

Definition at line 285 of file BKE_attribute_math.hh.

Constructor & Destructor Documentation

◆ SimpleMixer() [1/2]

template<typename T >
blender::bke::attribute_math::SimpleMixer< T >::SimpleMixer ( MutableSpan< T > buffer,
T default_value = {} )
inline
Parameters
bufferSpan where the interpolated values should be stored.
default_valueOutput value for an element that has not been affected by a mix_in.

Definition at line 296 of file BKE_attribute_math.hh.

◆ SimpleMixer() [2/2]

template<typename T >
blender::bke::attribute_math::SimpleMixer< T >::SimpleMixer ( MutableSpan< T > buffer,
const IndexMask & mask,
T default_value = {} )
inline
Parameters
maskOnly initialize these indices. Other indices in the buffer will be invalid.

Definition at line 304 of file BKE_attribute_math.hh.

Member Function Documentation

◆ finalize() [1/2]

template<typename T >
void blender::bke::attribute_math::SimpleMixer< T >::finalize ( )
inline

Has to be called before the buffer provided in the constructor is used.

Definition at line 332 of file BKE_attribute_math.hh.

References blender::bke::attribute_math::SimpleMixer< T >::finalize(), and blender::MutableSpan< T >::size().

Referenced by blender::bke::attribute_math::SimpleMixer< T >::finalize().

◆ finalize() [2/2]

template<typename T >
void blender::bke::attribute_math::SimpleMixer< T >::finalize ( const IndexMask & mask)
inline

Definition at line 337 of file BKE_attribute_math.hh.

◆ mix_in()

template<typename T >
void blender::bke::attribute_math::SimpleMixer< T >::mix_in ( const int64_t index,
const T & value,
const float weight = 1.0f )
inline

Mix a #value into the element with the given #index.

Definition at line 323 of file BKE_attribute_math.hh.

◆ set()

template<typename T >
void blender::bke::attribute_math::SimpleMixer< T >::set ( const int64_t index,
const T & value,
const float weight = 1.0f )
inline

Set a #value into the element with the given #index.

Definition at line 314 of file BKE_attribute_math.hh.


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