Blender V5.0
blender::math::numbers Namespace Reference

Variables

template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
constexpr T e_v = 2.718281828459045235360287471352662498L
template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
constexpr T log2e_v = 1.442695040888963407359924681001892137L
template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
constexpr T log10e_v = 0.434294481903251827651128918916605082L
template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
constexpr T pi_v = 3.141592653589793238462643383279502884L
template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
constexpr T inv_pi_v = 0.318309886183790671537767526745028724L
template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
constexpr T inv_sqrtpi_v = 0.564189583547756286948079451560772586L
template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
constexpr T ln2_v = 0.693147180559945309417232121458176568L
template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
constexpr T ln10_v = 2.302585092994045684017991454684364208L
template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
constexpr T sqrt2_v = 1.414213562373095048801688724209698079L
template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
constexpr T sqrt3_v = 1.732050807568877293527446341505872367L
template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
constexpr T inv_sqrt3_v = 0.577350269189625764509148780501957456L
template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
constexpr T egamma_v = 0.577215664901532860606512090082402431L
template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
constexpr T phi_v = 1.618033988749894848204586834365638118L
constexpr double e = e_v<double>
constexpr double log2e = log2e_v<double>
constexpr double log10e = log10e_v<double>
constexpr double pi = pi_v<double>
constexpr double inv_pi = inv_pi_v<double>
constexpr double inv_sqrtpi = inv_sqrtpi_v<double>
constexpr double ln2 = ln2_v<double>
constexpr double ln10 = ln10_v<double>
constexpr double sqrt2 = sqrt2_v<double>
constexpr double sqrt3 = sqrt3_v<double>
constexpr double inv_sqrt3 = inv_sqrt3_v<double>
constexpr double egamma = egamma_v<double>
constexpr double phi = phi_v<double>

Variable Documentation

◆ e

double blender::math::numbers::e = e_v<double>
inlineconstexpr

Definition at line 70 of file BLI_math_numbers.hh.

◆ e_v

template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
T blender::math::numbers::e_v = 2.718281828459045235360287471352662498L
inlineconstexpr

Definition at line 20 of file BLI_math_numbers.hh.

◆ egamma

double blender::math::numbers::egamma = egamma_v<double>
inlineconstexpr

Definition at line 81 of file BLI_math_numbers.hh.

◆ egamma_v

template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
T blender::math::numbers::egamma_v = 0.577215664901532860606512090082402431L
inlineconstexpr

Definition at line 64 of file BLI_math_numbers.hh.

◆ inv_pi

double blender::math::numbers::inv_pi = inv_pi_v<double>
inlineconstexpr

Definition at line 74 of file BLI_math_numbers.hh.

◆ inv_pi_v

template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
T blender::math::numbers::inv_pi_v = 0.318309886183790671537767526745028724L
inlineconstexpr

Definition at line 36 of file BLI_math_numbers.hh.

◆ inv_sqrt3

double blender::math::numbers::inv_sqrt3 = inv_sqrt3_v<double>
inlineconstexpr

◆ inv_sqrt3_v

template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
T blender::math::numbers::inv_sqrt3_v = 0.577350269189625764509148780501957456L
inlineconstexpr

Definition at line 60 of file BLI_math_numbers.hh.

◆ inv_sqrtpi

double blender::math::numbers::inv_sqrtpi = inv_sqrtpi_v<double>
inlineconstexpr

Definition at line 75 of file BLI_math_numbers.hh.

◆ inv_sqrtpi_v

template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
T blender::math::numbers::inv_sqrtpi_v = 0.564189583547756286948079451560772586L
inlineconstexpr

Definition at line 40 of file BLI_math_numbers.hh.

◆ ln10

double blender::math::numbers::ln10 = ln10_v<double>
inlineconstexpr

Definition at line 77 of file BLI_math_numbers.hh.

◆ ln10_v

template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
T blender::math::numbers::ln10_v = 2.302585092994045684017991454684364208L
inlineconstexpr

Definition at line 48 of file BLI_math_numbers.hh.

◆ ln2

double blender::math::numbers::ln2 = ln2_v<double>
inlineconstexpr

Definition at line 76 of file BLI_math_numbers.hh.

◆ ln2_v

template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
T blender::math::numbers::ln2_v = 0.693147180559945309417232121458176568L
inlineconstexpr

Definition at line 44 of file BLI_math_numbers.hh.

◆ log10e

double blender::math::numbers::log10e = log10e_v<double>
inlineconstexpr

Definition at line 72 of file BLI_math_numbers.hh.

◆ log10e_v

template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
T blender::math::numbers::log10e_v = 0.434294481903251827651128918916605082L
inlineconstexpr

Definition at line 28 of file BLI_math_numbers.hh.

◆ log2e

double blender::math::numbers::log2e = log2e_v<double>
inlineconstexpr

Definition at line 71 of file BLI_math_numbers.hh.

◆ log2e_v

template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
T blender::math::numbers::log2e_v = 1.442695040888963407359924681001892137L
inlineconstexpr

Definition at line 24 of file BLI_math_numbers.hh.

◆ phi

double blender::math::numbers::phi = phi_v<double>
inlineconstexpr

Definition at line 82 of file BLI_math_numbers.hh.

◆ phi_v

template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
T blender::math::numbers::phi_v = 1.618033988749894848204586834365638118L
inlineconstexpr

Definition at line 68 of file BLI_math_numbers.hh.

◆ pi

double blender::math::numbers::pi = pi_v<double>
inlineconstexpr

Definition at line 73 of file BLI_math_numbers.hh.

Referenced by BKE_mball_element_display_radius_calc_with_stiffness(), blender::geometry::calculate_bounds_radial_primitive(), blender::geometry::calculate_bounds_uv_sphere(), blender::geometry::calculate_cone_uvs(), blender::geometry::calculate_cone_verts(), blender::geometry::calculate_sphere_vertex_data(), blender::noise::compute_2d_gabor_kernel(), blender::noise::compute_2d_gabor_noise_cell(), blender::noise::compute_3d_gabor_kernel(), blender::noise::compute_3d_orientation(), blender::compositor::compute_exterior_angle(), blender::compositor::compute_rotation(), blender::math::AngleCartesianBase< float >::degree(), blender::math::AngleRadianBase< float >::degree(), blender::nodes::node_composite_kuwahara_cc::ConvertKuwaharaOperation::execute_anisotropic_cpu(), blender::math::AngleCartesianBase< float >::from_degree(), blender::math::AngleRadianBase< float >::from_degree(), blender::noise::gabor(), blender::noise::gabor(), blender::math::AngleFraction< T >::operator AngleCartesianBase< T >(), blender::ed::greasepencil::primitive_calulate_curve_positions(), blender::math::AngleFraction< T >::radian(), blender::ed::greasepencil::randomize_rotation(), blender::ed::greasepencil::randomize_rotation(), blender::draw::overlay::ring_vertices(), blender::math::safe_acos(), blender::math::safe_acos_approx(), blender::nodes::node_shader_tex_gabor_cc::sh_node_tex_gabor_declare(), blender::draw::overlay::ShapeCache::ShapeCache(), and blender::math::AngleRadianBase< float >::wrapped().

◆ pi_v

template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
T blender::math::numbers::pi_v = 3.141592653589793238462643383279502884L
inlineconstexpr

◆ sqrt2

◆ sqrt2_v

template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
T blender::math::numbers::sqrt2_v = 1.414213562373095048801688724209698079L
inlineconstexpr

◆ sqrt3

double blender::math::numbers::sqrt3 = sqrt3_v<double>
inlineconstexpr

◆ sqrt3_v

template<typename T, BLI_ENABLE_IF((std::is_floating_point_v< T >))>
T blender::math::numbers::sqrt3_v = 1.732050807568877293527446341505872367L
inlineconstexpr