.. role:: ts-api-decorator

#######################
CameraTurntableOperator
#######################

.. js:module:: Operators.Camera
   :noindex:

.. container:: ts-api-section

   .. js:class:: CameraTurntableOperator



.. container:: api-index-section

   .. rubric:: Methods

   .. rst-class:: api-index-list-item api-kind-method api-parent-kind-class

   * :js:meth:`~Operators.Camera.CameraTurntableOperator.addMapping`
   * :js:meth:`~Operators.Camera.CameraTurntableOperator.clearMapping`
   * :js:meth:`~Operators.Camera.CameraTurntableOperator.getCameraRotationMomentumEnabled`
   * :js:meth:`~Operators.Camera.CameraTurntableOperator.getMomentum`
   * :js:meth:`~Operators.Camera.CameraTurntableOperator.getMomentumLossPerSecond`
   * :js:meth:`~Operators.Camera.CameraTurntableOperator.isAnimating`
   * :js:meth:`~Operators.Camera.CameraTurntableOperator.isCurrentlyAnimating`
   * :js:meth:`~Operators.Camera.CameraTurntableOperator.setCameraRotationMomentumEnabled`
   * :js:meth:`~Operators.Camera.CameraTurntableOperator.setMapping`
   * :js:meth:`~Operators.Camera.CameraTurntableOperator.setMomentumLossPerSecond`
   * :js:meth:`~Operators.Camera.CameraTurntableOperator.setRotationAxis`
   * :js:meth:`~Operators.Camera.CameraTurntableOperator.stopAnimation`
   * :js:meth:`~Operators.Camera.CameraTurntableOperator.supportsAnimation`





------------

Methods
=======

.. rst-class:: ts-api-section

addMapping
----------

.. js:method:: CameraTurntableOperator.addMapping( button, modifier)

   :param button: None
   :type button: Button
   :param modifier: None
   :type modifier: KeyModifiers


   Adds a button and key modifier mapping for the operator. If no mapping is provided, all combinations are considered valid.
   All mappings require a mouse button, but a key modifier is optional.


   :rtype: void

.. rst-class:: ts-api-section

clearMapping
------------

.. js:method:: CameraTurntableOperator.clearMapping()



   Clears any button and key modifier mappings for the operator.


   :rtype: void

.. rst-class:: ts-api-section

getCameraRotationMomentumEnabled
--------------------------------

.. js:method:: CameraTurntableOperator.getCameraRotationMomentumEnabled()



   :rtype: boolean

.. rst-class:: ts-api-section

getMomentum
-----------

.. js:method:: CameraTurntableOperator.getMomentum()



   :rtype: number

.. rst-class:: ts-api-section

getMomentumLossPerSecond
------------------------

.. js:method:: CameraTurntableOperator.getMomentumLossPerSecond()



   :rtype: number

.. rst-class:: ts-api-section

isAnimating
-----------

.. js:method:: CameraTurntableOperator.isAnimating()



   :rtype: boolean

.. rst-class:: ts-api-section

isCurrentlyAnimating
--------------------

.. js:method:: CameraTurntableOperator.isCurrentlyAnimating()



   :rtype: boolean

.. rst-class:: ts-api-section

setCameraRotationMomentumEnabled
--------------------------------

.. js:method:: CameraTurntableOperator.setCameraRotationMomentumEnabled( val)

   :param val: None
   :type val: boolean


   :rtype: void

.. rst-class:: ts-api-section

setMapping
----------

.. js:method:: CameraTurntableOperator.setMapping( button, modifier)

   :param button: None
   :type button: Button
   :param modifier: None
   :type modifier: KeyModifiers


   Sets the button and key modifier mapping for the operator.


   :rtype: void

.. rst-class:: ts-api-section

setMomentumLossPerSecond
------------------------

.. js:method:: CameraTurntableOperator.setMomentumLossPerSecond( amountLost)

   :param amountLost: Proportion of momentum lost per second
   :type amountLost: number


   Sets proportion of momentum lost per second if camera rotation momentum is enabled. At 0
   no momentum is lost and the camera will orbit indefinitely. Above 1 the camera will stop
   orbiting within a second of release. Only values greater than or equal to 0 are accepted.


   :rtype: void

.. rst-class:: ts-api-section

setRotationAxis
---------------

.. js:method:: CameraTurntableOperator.setRotationAxis( axis)

   :param axis: [[Axis]] or [[Point3]] used to set the rotation axis.
   :type axis: Point3 | Axis


   Sets the rotation axis.


   :rtype: boolean

.. rst-class:: ts-api-section

stopAnimation
-------------

.. js:method:: CameraTurntableOperator.stopAnimation()



   :rtype: void

.. rst-class:: ts-api-section

supportsAnimation
-----------------

.. js:method:: CameraTurntableOperator.supportsAnimation()



   :rtype: boolean

