# TurntableOperator

class `TurntableOperator` : public HPS::Operator

  The TurntableOperator class defines an operator which allows the user to orbit the camera along a specific axis. This Operator works for both mouse- and touch-driven devices. Mouse-Driven Devices: Left button pressed and move: Orbit camera around z-axis Mouse wheel: Orbit camera around y-axis Left click + Control: Selects click location as rotation center Touch-Driven Devices: Touch down and move: Orbit camera around z-axis Two finger touch and move: Orbit camera around y-axis Double Tap: Selects click location as rotation center

  Public Functions

  inline virtual HPS::UTF8 `GetName`() const

    Returns the name of the operator.

  virtual bool `OnMouseDown`(MouseState const &in_state)

    This function is called whenever HPS receives a MouseEvent that signals a mouse button was pressed. This function starts the operator and computes the position of the starting point. If the Control button is pressed the click location will become the rotation center point.

    Parameters: | in_state – A MouseState object describing the current mouse state.
    Returns: | true if the input event was handled, false otherwise.

  virtual bool `OnMouseMove`(MouseState const &in_state)

    This function is called whenever HPS receives a MouseEvent that signals the mouse moved This function orbits the camera around the z-axis.

    Parameters: | in_state – A MouseState object describing the current mouse state.
    Returns: | true if the input event was handled, false otherwise.

  virtual bool `OnMouseUp`(MouseState const &in_state)

    This function is called whenever HPS receives a MouseEvent that signals a mouse button was released. This function stops the operator.

    Parameters: | in_state – A MouseState object describing the current mouse state.
    Returns: | true if the input event was handled, false otherwise.

  virtual bool `OnMouseWheel`(MouseState const &in_state)

    This function is called whenever HPS receives a MouseEvent that signals the mouse wheel moved This function orbits the camera around the y-axis.

    Parameters: | in_state – A MouseState object describing the current mouse state.
    Returns: | true if the input event was handled, false otherwise.

  virtual bool `OnTouchDown`(TouchState const &in_state)

    This function is called whenever HPS receives a TouchEvent that signals the device was touched. This function starts the operator and computes the position of the starting point. If a double-tap is received, the touch location will become the rotation center point.

    Parameters: | in_state – A TouchState object describing the current touch state.
    Returns: | true if the input event was handled, false otherwise.

  virtual bool `OnTouchMove`(TouchState const &in_state)

    This function is called whenever HPS receives a TouchEvent that signals a point of contact has moved. If a one-finger touch was received, this function orbits the camera around the z-axis. If a two-finger touch was received, this function orbits the camera around the y-axis.

    Parameters: | in_state – A TouchState object describing the current touch state.
    Returns: | true if the input event was handled, false otherwise.

  virtual bool `OnTouchUp`(TouchState const &in_state)

    This function is called whenever HPS receives a TouchEvent that signals a point of contact has been released. This function stops the operator.

    Parameters: | in_state – A TouchState object describing the current touch state.
    Returns: | true if the input event was handled, false otherwise.

  `TurntableOperator`(MouseButtons in_mouse_trigger = MouseButtons::ButtonLeft(), ModifierKeys in_modifier_trigger = ModifierKeys())

Conversation saved
HOOPSY BETA

### Hello! I'm HOOPSY

Your multilingual generative AI assistant for documentation. Ask me anything about HOOPS Visualize Desktop in your own language, or choose a sample question below to start a conversation:

What is HOOPS Visualize Desktop?
What are the latest release notes for HOOPS Visualize Desktop?
How do I start evaluating HOOPS Visualize Desktop?
How do I write my first sample application?
How can I get assistance?

HOOPSY may store conversations according to OpenAI's policy. Responses may not always be accurate.

HOOPSY is thinking...