|
Blender V4.3
|
#include <BLI_math_basis_types.hh>
Public Types | |
| enum class | Value : int8_t { X = 0 , Y , Z } |
Public Member Functions | |
| Axis ()=default | |
| constexpr | Axis (const Value axis) |
| constexpr | operator Value () const |
| constexpr int | as_int () const |
| operator bool () const =delete | |
Static Public Member Functions | |
| static constexpr Axis | from_char (char axis_char) |
| static constexpr Axis | from_int (const int axis_int) |
Static Public Attributes | |
| static constexpr Value | X = Value::X |
| static constexpr Value | Y = Value::Y |
| static constexpr Value | Z = Value::Z |
Friends | |
| std::ostream & | operator<< (std::ostream &stream, const Axis axis) |
An enum class representing one of the 3 basis axes. This is implemented using a class to allow operators and methods. NOTE: While this represents a 3D axis it can still be used to generate 2D basis vectors.
Definition at line 42 of file BLI_math_basis_types.hh.
|
strong |
| Enumerator | |
|---|---|
| X | |
| Y | |
| Z | |
Definition at line 44 of file BLI_math_basis_types.hh.
|
default |
|
inlineconstexpr |
Definition at line 61 of file BLI_math_basis_types.hh.
|
inlineconstexpr |
Definition at line 85 of file BLI_math_basis_types.hh.
References int.
Referenced by blender::nodes::node_fn_axes_to_rotation_cc::AxesToRotationFunction::AxesToRotationFunction(), blender::nodes::node_fn_align_rotation_to_vector_cc::AlignRotationToVectorFunction::call(), blender::nodes::node_fn_axes_to_rotation_cc::AxesToRotationFunction::call(), blender::math::from_vector(), blender::math::tests::TEST(), and blender::math::transform_point().
|
inlinestaticconstexpr |
Convert an uppercase axis character 'X', 'Y' or 'Z' to an enum value.
Definition at line 64 of file BLI_math_basis_types.hh.
References BLI_assert, X, and Z.
Allow casting from DNA enums stored as short / int.
Definition at line 72 of file BLI_math_basis_types.hh.
References BLI_assert, X, and Z.
Referenced by blender::nodes::node_fn_axes_to_rotation_cc::AxesToRotationFunction::AxesToRotationFunction(), blender::math::AxisSigned::axis(), blender::nodes::node_fn_align_rotation_to_vector_cc::node_build_multi_function(), blender::nodes::node_fn_axes_to_rotation_cc::node_build_multi_function(), blender::math::tests::TEST(), blender::ed::view3d::geometry_nodes_gizmos::TransformGizmos::update_rotate_transform_and_target_property(), blender::ed::view3d::geometry_nodes_gizmos::TransformGizmos::update_scale_transform_and_target_property(), and blender::ed::view3d::geometry_nodes_gizmos::TransformGizmos::update_translate_transform_and_target_property().
|
explicitdelete |
Avoid hell.
|
inlineconstexpr |
Definition at line 80 of file BLI_math_basis_types.hh.
|
friend |
Definition at line 11 of file math_basis_types.cc.
|
staticconstexpr |
Definition at line 51 of file BLI_math_basis_types.hh.
Referenced by from_int(), blender::math::from_vector(), blender::math::invert(), blender::nodes::node_fn_axes_to_rotation_cc::node_init(), blender::nodes::node_fn_align_rotation_to_vector_cc::node_rna(), blender::nodes::node_fn_axes_to_rotation_cc::node_rna(), blender::math::orthogonalize(), blender::math::tests::TEST(), blender::tests::TEST(), and blender::tests::TEST().
|
staticconstexpr |
Definition at line 52 of file BLI_math_basis_types.hh.
Referenced by blender::math::from_vector(), blender::math::invert(), blender::nodes::node_fn_align_rotation_to_vector_cc::node_rna(), blender::nodes::node_fn_axes_to_rotation_cc::node_rna(), blender::math::orthogonalize(), blender::math::tests::TEST(), blender::tests::TEST(), blender::tests::TEST(), and blender::math::to_dual_quaternion().
|
staticconstexpr |
Definition at line 53 of file BLI_math_basis_types.hh.
Referenced by from_int(), blender::math::from_vector(), blender::math::invert(), blender::nodes::node_fn_align_rotation_to_vector_cc::node_init(), blender::nodes::node_fn_axes_to_rotation_cc::node_init(), blender::nodes::node_fn_align_rotation_to_vector_cc::node_rna(), blender::nodes::node_fn_axes_to_rotation_cc::node_rna(), blender::math::orthogonalize(), blender::math::tests::TEST(), blender::tests::TEST(), and blender::tests::TEST().