Blender
V3.3
|
Go to the source code of this file.
Functions | |
MINLINE float | safe_divide (float a, float b) |
MINLINE float | safe_modf (float a, float b) |
MINLINE float | safe_logf (float a, float base) |
MINLINE float | safe_sqrtf (float a) |
MINLINE float | safe_inverse_sqrtf (float a) |
MINLINE float | safe_asinf (float a) |
MINLINE float | safe_acosf (float a) |
MINLINE float | safe_powf (float base, float exponent) |
This file provides safe alternatives to common math functions like sqrt, powf. In this context "safe" means that the output is not NaN if the input is not NaN.
Definition in file BLI_math_base_safe.h.
Definition at line 47 of file math_base_safe_inline.c.
References Freestyle::a, acosf, clamp(), and CLAMP.
Referenced by attr_create_pointiness(), bsdf_diffuse_toon_eval_reflect(), bsdf_glossy_toon_eval_reflect(), direction_to_fisheye_equisolid(), direction_to_fisheye_lens_polynomial(), direction_to_spherical(), fisheye_equisolid_to_direction(), fisheye_lens_polynomial_to_direction(), fisheye_to_direction(), map_to_sphere(), rect_light_sample(), sky_angle_between(), svm_math(), svm_node_ies(), and blender::nodes::try_dispatch_float_math_fl_to_fl().
Definition at line 41 of file math_base_safe_inline.c.
References Freestyle::a, asinf, clamp(), and CLAMP.
Referenced by bsdf_hair_reflection_sample(), bsdf_principled_hair_eval(), bsdf_principled_hair_sample(), spherical_stereo_transform(), svm_math(), and blender::nodes::try_dispatch_float_math_fl_to_fl().
Definition at line 13 of file math_base_safe_inline.c.
References Freestyle::a, and usdtokens::b().
Referenced by safe_logf(), and snap().
Definition at line 36 of file math_base_safe_inline.c.
References Freestyle::a, and sqrtf.
Referenced by blender::nodes::try_dispatch_float_math_fl_to_fl().
Definition at line 23 of file math_base_safe_inline.c.
References Freestyle::a, usdtokens::b(), logf, safe_divide(), and UNLIKELY.
Referenced by svm_math(), TEST(), and blender::nodes::try_dispatch_float_math_fl_fl_to_fl().
Definition at line 18 of file math_base_safe_inline.c.
References Freestyle::a, usdtokens::b(), and fmodf.
Referenced by TEST(), and blender::nodes::try_dispatch_float_math_fl_fl_to_fl().
Definition at line 53 of file math_base_safe_inline.c.
References Freestyle::a, usdtokens::b(), compatible_powf(), float_to_int(), powf, and UNLIKELY.
Referenced by single_peaked_henyey_greenstein(), svm_math(), TEST(), and blender::nodes::try_dispatch_float_math_fl_fl_to_fl().
Definition at line 31 of file math_base_safe_inline.c.
References Freestyle::a, max(), MAX2, and sqrtf.
Referenced by beckmann_table_rows(), bsdf_beckmann_aniso_G1(), bsdf_beckmann_G1(), bsdf_microfacet_ggx_eval_reflect(), bsdf_microfacet_ggx_eval_transmit(), bsdf_microfacet_ggx_sample(), bssrdf_burley_sample(), cos_from_sin(), direction_from_cosine(), ensure_valid_reflection(), henyey_greenstrein_sample(), light_spread_attenuation(), mf_sample_phase_glass(), mf_sampleP22_11(), microfacet_ggx_sample_slopes(), microfacet_sample_stretched(), sample_uniform_cone(), shader_bsdf_average_roughness(), sky_radiance_nishita(), svm_math(), svm_node_closure_bsdf(), triangle_light_sample(), and blender::nodes::try_dispatch_float_math_fl_to_fl().