Blender V5.0
blender::detail Namespace Reference

Classes

struct  AnyTypeInfo
struct  NoExtraInfo
struct  GVArrayAnyExtraInfo
struct  ScopedDeferHelper
struct  VArrayAnyExtraInfo

Typedefs

template<typename T>
using Ptr = std::unique_ptr<T>

Functions

template<typename T, int Size>
bool any_less_or_equal_than (const VecBase< T, Size > &a, const VecBase< T, Size > &b)
template<size_t... I, typename... Args>
uint64_t get_default_hash_array (std::index_sequence< I... >, const Args &...args)
template<typename T, int A_NumCol, int A_NumRow, int B_NumCol, int B_NumRow, typename MatA, typename MatB>
MatBase< T, B_NumCol, A_NumRow > matrix_mul_impl (const MatA &a, const MatB &b)

Variables

template<typename ExtraInfo, typename T>
constexpr AnyTypeInfo< ExtraInfo > info_for_inline
template<typename ExtraInfo, typename T>
constexpr AnyTypeInfo< ExtraInfo > info_for_unique_ptr
static constexpr std::array< uint64_t, 3 > default_hash_factors = {19349669, 83492791, 3632623}
template<typename T, T Value, size_t... I>
ValueSequence< T,((I==0) ? Value :Value)... > make_value_sequence_impl (std::index_sequence< I... >)
template<typename T, T Value1, T Value2, size_t... Value1Indices, size_t... I>
ValueSequence< T,(ValueSequence< size_t, Value1Indices... >::template contains< I >() ? Value1 :Value2)... > make_two_value_sequence_impl (ValueSequence< size_t, Value1Indices... >, std::index_sequence< I... >)

Typedef Documentation

◆ Ptr

template<typename T>
using blender::detail::Ptr = std::unique_ptr<T>

Used when T can't be stored directly in the inline buffer and is stored in a #std::unique_ptr instead. In this scenario, the #std::unique_ptr is stored in the inline buffer.

Definition at line 60 of file BLI_any.hh.

Function Documentation

◆ any_less_or_equal_than()

template<typename T, int Size>
bool blender::detail::any_less_or_equal_than ( const VecBase< T, Size > & a,
const VecBase< T, Size > & b )
inlinenodiscard

Definition at line 247 of file BLI_bounds.hh.

References any_less_or_equal_than(), b, and i.

Referenced by any_less_or_equal_than(), and blender::Bounds< T >::is_empty().

◆ get_default_hash_array()

template<size_t... I, typename... Args>
uint64_t blender::detail::get_default_hash_array ( std::index_sequence< I... > ,
const Args &... args )
inline

Definition at line 223 of file BLI_hash.hh.

References default_hash_factors, and I.

Referenced by blender::get_default_hash().

◆ matrix_mul_impl()

template<typename T, int A_NumCol, int A_NumRow, int B_NumCol, int B_NumRow, typename MatA, typename MatB>
MatBase< T, B_NumCol, A_NumRow > blender::detail::matrix_mul_impl ( const MatA & a,
const MatB & b )

Multiply two matrices using matrix multiplication.

Definition at line 900 of file BLI_math_matrix_types.hh.

References b, i, matrix_mul_impl(), result, and blender::unroll().

Referenced by matrix_mul_impl(), blender::operator*(), blender::operator*(), blender::operator*(), and blender::operator*().

Variable Documentation

◆ default_hash_factors

std::array<uint64_t, 3> blender::detail::default_hash_factors = {19349669, 83492791, 3632623}
staticconstexpr

Definition at line 220 of file BLI_hash.hh.

Referenced by get_default_hash_array().

◆ info_for_inline

template<typename ExtraInfo, typename T>
AnyTypeInfo<ExtraInfo> blender::detail::info_for_inline
inlineconstexpr
Initial value:
= {
+[](void *dst, const void *src) { new (dst) T(*static_cast<const T *>(src)); },
+[](void *dst, void *src) { new (dst) T(std::move(*static_cast<T *>(src))); },
+[](void *src) { std::destroy_at((static_cast<T *>(src))); },
nullptr,
ExtraInfo::template get<T>()}
#define T
constexpr bool is_trivially_move_constructible_extended_v
constexpr bool is_trivially_destructible_extended_v
constexpr bool is_trivially_copy_constructible_extended_v

Used when T is stored directly in the inline buffer of the Any.

Definition at line 43 of file BLI_any.hh.

◆ info_for_unique_ptr

template<typename ExtraInfo, typename T>
AnyTypeInfo<ExtraInfo> blender::detail::info_for_unique_ptr
inlineconstexpr
Initial value:
= {
[](void *dst, const void *src) { new (dst) Ptr<T>(new T(**(const Ptr<T> *)src)); },
[](void *dst, void *src) { new (dst) Ptr<T>(new T(std::move(**(Ptr<T> *)src))); },
[](void *src) { std::destroy_at((Ptr<T> *)src); },
[](const void *src) -> const void * { return &**(const Ptr<T> *)src; },
ExtraInfo::template get<T>()}
std::unique_ptr< T > Ptr
Definition BLI_any.hh:60

Definition at line 62 of file BLI_any.hh.

◆ make_two_value_sequence_impl

template<typename T, T Value1, T Value2, size_t... Value1Indices, size_t... I>
ValueSequence< T,(ValueSequence< size_t, Value1Indices... >::template contains< I >() ? Value1 :Value2)... > blender::detail::make_two_value_sequence_impl(ValueSequence< size_t, Value1Indices... >, std::index_sequence< I... >) ( ValueSequence< size_t, Value1Indices... > ,
std::index_sequence< I... >  )
inline

Definition at line 98 of file BLI_parameter_pack_utils.hh.

◆ make_value_sequence_impl

template<typename T, T Value, size_t... I>
ValueSequence< T,((I==0) ? Value :Value)... > blender::detail::make_value_sequence_impl(std::index_sequence< I... >) ( std::index_sequence< I... > )
inline

Definition at line 88 of file BLI_parameter_pack_utils.hh.