.. DO NOT EDIT THIS FILE!!! .. Generated automatically from Godot engine sources. .. Generator: https://github.com/godotengine/godot/tree/master/doc/tools/make_rst.py. .. XML source: https://github.com/godotengine/godot/tree/master/docs/gdscript/doc/classes/Quaternion.xml. .. _class_Quaternion: Quaternion ========== .. container:: contribute There is currently no description for this class. Please help us by :ref:`contributing one `! .. note:: There are notable differences when using this API with C#. See :ref:`doc_c_sharp_differences` for more information. .. rst-class:: classref-reftable-group Properties ---------- .. table:: :widths: auto +---------------------------+---------------------------------------+---------+ | :ref:`float` | :ref:`w` | ``1.0`` | +---------------------------+---------------------------------------+---------+ | :ref:`float` | :ref:`x` | ``0.0`` | +---------------------------+---------------------------------------+---------+ | :ref:`float` | :ref:`y` | ``0.0`` | +---------------------------+---------------------------------------+---------+ | :ref:`float` | :ref:`z` | ``0.0`` | +---------------------------+---------------------------------------+---------+ .. rst-class:: classref-reftable-group Constructors ------------ .. table:: :widths: auto +-------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`Quaternion` **(** **)** | +-------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`Quaternion` **(** :ref:`Quaternion` from **)** | +-------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`Quaternion` **(** :ref:`Vector3` arc_from, :ref:`Vector3` arc_to **)** | +-------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`Quaternion` **(** :ref:`Vector3` axis, :ref:`float` angle **)** | +-------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`Quaternion` **(** :ref:`Basis` from **)** | +-------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`Quaternion` **(** :ref:`float` x, :ref:`float` y, :ref:`float` z, :ref:`float` w **)** | +-------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ .. rst-class:: classref-reftable-group Methods ------- .. table:: :widths: auto +-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`float` | :ref:`angle_to` **(** :ref:`Quaternion` to **)** |const| | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`float` | :ref:`dot` **(** :ref:`Quaternion` with **)** |const| | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`exp` **(** **)** |const| | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`from_euler` **(** :ref:`Vector3` euler **)** |static| | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`float` | :ref:`get_angle` **(** **)** |const| | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector3` | :ref:`get_axis` **(** **)** |const| | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector3` | :ref:`get_euler` **(** :ref:`int` order=2 **)** |const| | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`inverse` **(** **)** |const| | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`is_equal_approx` **(** :ref:`Quaternion` to **)** |const| | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`is_finite` **(** **)** |const| | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`is_normalized` **(** **)** |const| | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`float` | :ref:`length` **(** **)** |const| | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`float` | :ref:`length_squared` **(** **)** |const| | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`log` **(** **)** |const| | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`normalized` **(** **)** |const| | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`slerp` **(** :ref:`Quaternion` to, :ref:`float` weight **)** |const| | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`slerpni` **(** :ref:`Quaternion` to, :ref:`float` weight **)** |const| | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`spherical_cubic_interpolate` **(** :ref:`Quaternion` b, :ref:`Quaternion` pre_a, :ref:`Quaternion` post_b, :ref:`float` weight **)** |const| | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`spherical_cubic_interpolate_in_time` **(** :ref:`Quaternion` b, :ref:`Quaternion` pre_a, :ref:`Quaternion` post_b, :ref:`float` weight, :ref:`float` b_t, :ref:`float` pre_a_t, :ref:`float` post_b_t **)** |const| | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ .. rst-class:: classref-reftable-group Operators --------- .. table:: :widths: auto +-------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`operator !=` **(** :ref:`Quaternion` right **)** | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`operator *` **(** :ref:`Quaternion` right **)** | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :ref:`Vector3` | :ref:`operator *` **(** :ref:`Vector3` right **)** | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`operator *` **(** :ref:`float` right **)** | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`operator *` **(** :ref:`int` right **)** | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`operator +` **(** :ref:`Quaternion` right **)** | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`operator -` **(** :ref:`Quaternion` right **)** | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`operator /` **(** :ref:`float` right **)** | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`operator /` **(** :ref:`int` right **)** | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`operator ==` **(** :ref:`Quaternion` right **)** | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :ref:`float` | :ref:`operator []` **(** :ref:`int` index **)** | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`operator unary+` **(** **)** | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------+ | :ref:`Quaternion` | :ref:`operator unary-` **(** **)** | +-------------------------------------+--------------------------------------------------------------------------------------------------------------------+ .. rst-class:: classref-section-separator ---- .. rst-class:: classref-descriptions-group Constants --------- .. _class_Quaternion_constant_IDENTITY: .. rst-class:: classref-constant **IDENTITY** = ``Quaternion(0, 0, 0, 1)`` .. container:: contribute There is currently no description for this constant. Please help us by :ref:`contributing one `! .. rst-class:: classref-section-separator ---- .. rst-class:: classref-descriptions-group Property Descriptions --------------------- .. _class_Quaternion_property_w: .. rst-class:: classref-property :ref:`float` **w** = ``1.0`` .. container:: contribute There is currently no description for this property. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_property_x: .. rst-class:: classref-property :ref:`float` **x** = ``0.0`` .. container:: contribute There is currently no description for this property. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_property_y: .. rst-class:: classref-property :ref:`float` **y** = ``0.0`` .. container:: contribute There is currently no description for this property. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_property_z: .. rst-class:: classref-property :ref:`float` **z** = ``0.0`` .. container:: contribute There is currently no description for this property. Please help us by :ref:`contributing one `! .. rst-class:: classref-section-separator ---- .. rst-class:: classref-descriptions-group Constructor Descriptions ------------------------ .. _class_Quaternion_constructor_Quaternion: .. rst-class:: classref-constructor :ref:`Quaternion` **Quaternion** **(** **)** .. container:: contribute There is currently no description for this constructor. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. rst-class:: classref-constructor :ref:`Quaternion` **Quaternion** **(** :ref:`Quaternion` from **)** .. container:: contribute There is currently no description for this constructor. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. rst-class:: classref-constructor :ref:`Quaternion` **Quaternion** **(** :ref:`Vector3` arc_from, :ref:`Vector3` arc_to **)** .. container:: contribute There is currently no description for this constructor. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. rst-class:: classref-constructor :ref:`Quaternion` **Quaternion** **(** :ref:`Vector3` axis, :ref:`float` angle **)** .. container:: contribute There is currently no description for this constructor. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. rst-class:: classref-constructor :ref:`Quaternion` **Quaternion** **(** :ref:`Basis` from **)** .. container:: contribute There is currently no description for this constructor. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. rst-class:: classref-constructor :ref:`Quaternion` **Quaternion** **(** :ref:`float` x, :ref:`float` y, :ref:`float` z, :ref:`float` w **)** .. container:: contribute There is currently no description for this constructor. Please help us by :ref:`contributing one `! .. rst-class:: classref-section-separator ---- .. rst-class:: classref-descriptions-group Method Descriptions ------------------- .. _class_Quaternion_method_angle_to: .. rst-class:: classref-method :ref:`float` **angle_to** **(** :ref:`Quaternion` to **)** |const| .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_method_dot: .. rst-class:: classref-method :ref:`float` **dot** **(** :ref:`Quaternion` with **)** |const| .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_method_exp: .. rst-class:: classref-method :ref:`Quaternion` **exp** **(** **)** |const| .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_method_from_euler: .. rst-class:: classref-method :ref:`Quaternion` **from_euler** **(** :ref:`Vector3` euler **)** |static| .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_method_get_angle: .. rst-class:: classref-method :ref:`float` **get_angle** **(** **)** |const| .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_method_get_axis: .. rst-class:: classref-method :ref:`Vector3` **get_axis** **(** **)** |const| .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_method_get_euler: .. rst-class:: classref-method :ref:`Vector3` **get_euler** **(** :ref:`int` order=2 **)** |const| .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_method_inverse: .. rst-class:: classref-method :ref:`Quaternion` **inverse** **(** **)** |const| .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_method_is_equal_approx: .. rst-class:: classref-method :ref:`bool` **is_equal_approx** **(** :ref:`Quaternion` to **)** |const| .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_method_is_finite: .. rst-class:: classref-method :ref:`bool` **is_finite** **(** **)** |const| .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_method_is_normalized: .. rst-class:: classref-method :ref:`bool` **is_normalized** **(** **)** |const| .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_method_length: .. rst-class:: classref-method :ref:`float` **length** **(** **)** |const| .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_method_length_squared: .. rst-class:: classref-method :ref:`float` **length_squared** **(** **)** |const| .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_method_log: .. rst-class:: classref-method :ref:`Quaternion` **log** **(** **)** |const| .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_method_normalized: .. rst-class:: classref-method :ref:`Quaternion` **normalized** **(** **)** |const| .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_method_slerp: .. rst-class:: classref-method :ref:`Quaternion` **slerp** **(** :ref:`Quaternion` to, :ref:`float` weight **)** |const| .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_method_slerpni: .. rst-class:: classref-method :ref:`Quaternion` **slerpni** **(** :ref:`Quaternion` to, :ref:`float` weight **)** |const| .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_method_spherical_cubic_interpolate: .. rst-class:: classref-method :ref:`Quaternion` **spherical_cubic_interpolate** **(** :ref:`Quaternion` b, :ref:`Quaternion` pre_a, :ref:`Quaternion` post_b, :ref:`float` weight **)** |const| .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_method_spherical_cubic_interpolate_in_time: .. rst-class:: classref-method :ref:`Quaternion` **spherical_cubic_interpolate_in_time** **(** :ref:`Quaternion` b, :ref:`Quaternion` pre_a, :ref:`Quaternion` post_b, :ref:`float` weight, :ref:`float` b_t, :ref:`float` pre_a_t, :ref:`float` post_b_t **)** |const| .. container:: contribute There is currently no description for this method. Please help us by :ref:`contributing one `! .. rst-class:: classref-section-separator ---- .. rst-class:: classref-descriptions-group Operator Descriptions --------------------- .. _class_Quaternion_operator_neq_Quaternion: .. rst-class:: classref-operator :ref:`bool` **operator !=** **(** :ref:`Quaternion` right **)** .. container:: contribute There is currently no description for this operator. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_operator_mul_Quaternion: .. rst-class:: classref-operator :ref:`Quaternion` **operator *** **(** :ref:`Quaternion` right **)** .. container:: contribute There is currently no description for this operator. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_operator_mul_Vector3: .. rst-class:: classref-operator :ref:`Vector3` **operator *** **(** :ref:`Vector3` right **)** .. container:: contribute There is currently no description for this operator. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_operator_mul_float: .. rst-class:: classref-operator :ref:`Quaternion` **operator *** **(** :ref:`float` right **)** .. container:: contribute There is currently no description for this operator. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_operator_mul_int: .. rst-class:: classref-operator :ref:`Quaternion` **operator *** **(** :ref:`int` right **)** .. container:: contribute There is currently no description for this operator. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_operator_sum_Quaternion: .. rst-class:: classref-operator :ref:`Quaternion` **operator +** **(** :ref:`Quaternion` right **)** .. container:: contribute There is currently no description for this operator. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_operator_dif_Quaternion: .. rst-class:: classref-operator :ref:`Quaternion` **operator -** **(** :ref:`Quaternion` right **)** .. container:: contribute There is currently no description for this operator. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_operator_div_float: .. rst-class:: classref-operator :ref:`Quaternion` **operator /** **(** :ref:`float` right **)** .. container:: contribute There is currently no description for this operator. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_operator_div_int: .. rst-class:: classref-operator :ref:`Quaternion` **operator /** **(** :ref:`int` right **)** .. container:: contribute There is currently no description for this operator. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_operator_eq_Quaternion: .. rst-class:: classref-operator :ref:`bool` **operator ==** **(** :ref:`Quaternion` right **)** .. container:: contribute There is currently no description for this operator. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_operator_idx_int: .. rst-class:: classref-operator :ref:`float` **operator []** **(** :ref:`int` index **)** .. container:: contribute There is currently no description for this operator. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_operator_unplus: .. rst-class:: classref-operator :ref:`Quaternion` **operator unary+** **(** **)** .. container:: contribute There is currently no description for this operator. Please help us by :ref:`contributing one `! .. rst-class:: classref-item-separator ---- .. _class_Quaternion_operator_unminus: .. rst-class:: classref-operator :ref:`Quaternion` **operator unary-** **(** **)** .. container:: contribute There is currently no description for this operator. Please help us by :ref:`contributing one `! .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)` .. |constructor| replace:: :abbr:`constructor (This method is used to construct a type.)` .. |static| replace:: :abbr:`static (This method doesn't need an instance to be called, so it can be called directly using the class name.)` .. |operator| replace:: :abbr:`operator (This method describes a valid operator to use with this type as left-hand operand.)` .. |bitfield| replace:: :abbr:`BitField (This value is an integer composed as a bitmask of the following flags.)`