vcg::TrackMode Class Reference

Base class for all the manipulators. More...

#include <trackmode.h>

Inheritance diagram for vcg::TrackMode:
Inheritance graph
[legend]

List of all members.

Public Member Functions

virtual void Animate (unsigned int msec, Trackball *tb)
virtual void Apply (Trackball *trackball, float WheelNotch)
 The default manipulator application for mouse scrolls.
virtual void Apply (Trackball *trackball, Point3f new_point)
 The default manipulator application for mouse drags.
virtual void Draw (Trackball *trackball)
 The default manipulator's render function.
virtual bool IsAnimating (const Trackball *tb)
virtual bool isSticky ()
 The default avaibility to manipulator changes inside an action.
virtual const char * Name ()
 The default manipulator's name.
virtual void Reset ()
 The default manipulator's reset function.
virtual void SetAction ()
 The default manipulator's begin action function.
virtual void Undo ()
 The default manipulator's undo function.
virtual ~TrackMode ()
 The default virtual destructor.

Detailed Description

Base class for all the manipulators.

Functions in this class implements the default behaviour of a manipulator: doing nothing.

Every manipulator must be subclass of this class.

Definition at line 93 of file trackmode.h.


Constructor & Destructor Documentation

virtual vcg::TrackMode::~TrackMode (  )  [inline, virtual]

The default virtual destructor.

Definition at line 98 of file trackmode.h.


Member Function Documentation

void TrackMode::Animate ( unsigned int  msec,
Trackball tb 
) [virtual]

Reimplemented in vcg::NavigatorWasdMode.

Definition at line 162 of file trackmode.cpp.

void TrackMode::Apply ( Trackball trackball,
float  WheelNotch 
) [virtual]

The default manipulator application for mouse scrolls.

This default application does nothing.

Parameters:
trackball the manipulator manager.
WheelNotch the mouse wheel notch.

Reimplemented in vcg::ZMode, vcg::ScaleMode, vcg::AxisMode, vcg::CylinderMode, vcg::PathMode, and vcg::NavigatorWasdMode.

Definition at line 148 of file trackmode.cpp.

void TrackMode::Apply ( Trackball trackball,
Point3f  new_point 
) [virtual]

The default manipulator application for mouse drags.

This default application does nothing.

Parameters:
trackball the manipulator manager.
new_point the new mouse pointer coordinate.

Reimplemented in vcg::SphereMode, vcg::PanMode, vcg::ZMode, vcg::ScaleMode, vcg::AxisMode, vcg::PlaneMode, vcg::CylinderMode, vcg::PathMode, vcg::AreaMode, vcg::PolarMode, and vcg::NavigatorWasdMode.

Definition at line 150 of file trackmode.cpp.

void TrackMode::Draw ( Trackball trackball  )  [virtual]

The default manipulator's render function.

Parameters:
trackball the manipulator manager.

Reimplemented in vcg::InactiveMode, vcg::SphereMode, vcg::PanMode, vcg::ZMode, vcg::ScaleMode, vcg::AxisMode, vcg::PlaneMode, vcg::CylinderMode, vcg::PathMode, vcg::AreaMode, and vcg::PolarMode.

Definition at line 152 of file trackmode.cpp.

bool TrackMode::IsAnimating ( const Trackball tb  )  [virtual]

Reimplemented in vcg::NavigatorWasdMode.

Definition at line 158 of file trackmode.cpp.

bool TrackMode::isSticky (  )  [virtual]

The default avaibility to manipulator changes inside an action.

Every manipulator class can choose if the manipulator manager can switch between it and another manipulator in the middle of an user action, e.g. switching Trackball's current_mode without releasing the mouse button.

The default behaviour is to allow the switch.

Blocking switches is useful for stateful manipulators, regarding state consistency respect to Trackball's Undo() calls.

Returns:
false if manipulator permits the switch.

Reimplemented in vcg::PathMode, vcg::AreaMode, and vcg::NavigatorWasdMode.

Definition at line 165 of file trackmode.cpp.

virtual const char* vcg::TrackMode::Name (  )  [inline, virtual]

The default manipulator's name.

Returns:
the constant string "TrackMode"

Reimplemented in vcg::InactiveMode, vcg::SphereMode, vcg::PanMode, vcg::ZMode, vcg::ScaleMode, vcg::AxisMode, vcg::PlaneMode, vcg::CylinderMode, vcg::PathMode, vcg::AreaMode, vcg::PolarMode, and vcg::NavigatorWasdMode.

Definition at line 135 of file trackmode.h.

void TrackMode::Reset (  )  [virtual]

The default manipulator's reset function.

If a manipulator has a state, it can be reset to the inital state calling this function.

Reimplemented in vcg::PathMode, vcg::AreaMode, vcg::PolarMode, and vcg::NavigatorWasdMode.

Definition at line 156 of file trackmode.cpp.

void TrackMode::SetAction (  )  [virtual]

The default manipulator's begin action function.

This default implementation does nothing.

Reimplemented in vcg::PathMode, vcg::AreaMode, vcg::PolarMode, and vcg::NavigatorWasdMode.

Definition at line 154 of file trackmode.cpp.

void TrackMode::Undo (  )  [virtual]

The default manipulator's undo function.

If a manipulator has a state, it must be undoable with a call of this function. The undo must recreate the state present before the last Apply() call.

This default implementation does nothing.

Reimplemented in vcg::PathMode, and vcg::AreaMode.

Definition at line 169 of file trackmode.cpp.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines


vcglib
Author(s): Christian Bersch
autogenerated on Fri Jan 11 09:23:07 2013