LLManip Class Reference

#include <llmanip.h>

Inheritance diagram for LLManip:

Inheritance graph
[legend]
Collaboration diagram for LLManip:

Collaboration graph
[legend]

List of all members.

Public Types

enum  e_manip_part {
  LL_NO_PART = 0, LL_X_ARROW, LL_Y_ARROW, LL_Z_ARROW,
  LL_YZ_PLANE, LL_XZ_PLANE, LL_XY_PLANE, LL_CORNER_NNN,
  LL_CORNER_NNP, LL_CORNER_NPN, LL_CORNER_NPP, LL_CORNER_PNN,
  LL_CORNER_PNP, LL_CORNER_PPN, LL_CORNER_PPP, LL_FACE_POSZ,
  LL_FACE_POSX, LL_FACE_POSY, LL_FACE_NEGX, LL_FACE_NEGY,
  LL_FACE_NEGZ, LL_EDGE_NEGX_NEGY, LL_EDGE_NEGX_POSY, LL_EDGE_POSX_NEGY,
  LL_EDGE_POSX_POSY, LL_EDGE_NEGY_NEGZ, LL_EDGE_NEGY_POSZ, LL_EDGE_POSY_NEGZ,
  LL_EDGE_POSY_POSZ, LL_EDGE_NEGZ_NEGX, LL_EDGE_NEGZ_POSX, LL_EDGE_POSZ_NEGX,
  LL_EDGE_POSZ_POSX, LL_ROT_GENERAL, LL_ROT_X, LL_ROT_Y,
  LL_ROT_Z, LL_ROT_ROLL
}
enum  e_select_part_ranges {
  LL_ARROW_MIN = LL_X_ARROW, LL_ARROW_MAX = LL_Z_ARROW, LL_CORNER_MIN = LL_CORNER_NNN, LL_CORNER_MAX = LL_CORNER_PPP,
  LL_FACE_MIN = LL_FACE_POSZ, LL_FACE_MAX = LL_FACE_NEGZ, LL_EDGE_MIN = LL_EDGE_NEGX_NEGY, LL_EDGE_MAX = LL_EDGE_POSZ_POSX
}
typedef enum LLManip::e_manip_part EManipPart
typedef enum
LLManip::e_select_part_ranges 
EManipPartRanges

Public Member Functions

 LLManip (const LLString &name, LLToolComposite *composite)
virtual BOOL handleMouseDownOnPart (S32 x, S32 y, MASK mask)=0
void renderGuidelines (BOOL draw_x=TRUE, BOOL draw_y=TRUE, BOOL draw_z=TRUE)
BOOL handleMouseUp (S32 x, S32 y, MASK mask)
BOOL handleHover (S32 x, S32 y, MASK mask)
virtual void highlightManipulators (S32 x, S32 y)=0
virtual void handleSelect ()
virtual void handleDeselect ()
virtual BOOL canAffectSelection ()=0
EManipPart getHighlightedPart ()
LLSafeHandle< LLObjectSelectiongetSelection ()

Static Public Member Functions

static void rebuild (LLViewerObject *vobj)
static void renderXYZ (const LLVector3 &vec)

Protected Member Functions

LLVector3 getSavedPivotPoint () const
LLVector3 getPivotPoint ()
void getManipNormal (LLViewerObject *object, EManipPart manip, LLVector3 &normal)
BOOL getManipAxis (LLViewerObject *object, EManipPart manip, LLVector3 &axis)
F32 getSubdivisionLevel (const LLVector3 &reference_point, const LLVector3 &translate_axis, F32 grid_scale, S32 min_pixel_spacing=MIN_DIVISION_PIXEL_WIDTH)
void renderTickValue (const LLVector3 &pos, F32 value, const char *suffix, const LLColor4 &color)
void renderTickText (const LLVector3 &pos, const char *suffix, const LLColor4 &color)
void updateGridSettings ()
BOOL getMousePointOnPlaneGlobal (LLVector3d &point, S32 x, S32 y, LLVector3d origin, LLVector3 normal) const
BOOL getMousePointOnPlaneAgent (LLVector3 &point, S32 x, S32 y, LLVector3 origin, LLVector3 normal)
BOOL nearestPointOnLineFromMouse (S32 x, S32 y, const LLVector3 &b1, const LLVector3 &b2, F32 &a_param, F32 &b_param)
LLColor4 setupSnapGuideRenderPass (S32 pass)

Protected Attributes

LLFrameTimer mHelpTextTimer
BOOL mInSnapRegime
LLSafeHandle< LLObjectSelectionmObjectSelection
EManipPart mHighlightedPart

Static Protected Attributes

static F32 sHelpTextVisibleTime = 2.f
static F32 sHelpTextFadeTime = 2.f
static S32 sNumTimesHelpTextShown = 0
static S32 sMaxTimesShowHelpText = 5
static F32 sGridMaxSubdivisionLevel = 32.f
static F32 sGridMinSubdivisionLevel = 1.f
static LLVector2 sTickLabelSpacing


Detailed Description

Definition at line 47 of file llmanip.h.


Member Typedef Documentation


Member Enumeration Documentation

Enumerator:
LL_NO_PART 
LL_X_ARROW 
LL_Y_ARROW 
LL_Z_ARROW 
LL_YZ_PLANE 
LL_XZ_PLANE 
LL_XY_PLANE 
LL_CORNER_NNN 
LL_CORNER_NNP 
LL_CORNER_NPN 
LL_CORNER_NPP 
LL_CORNER_PNN 
LL_CORNER_PNP 
LL_CORNER_PPN 
LL_CORNER_PPP 
LL_FACE_POSZ 
LL_FACE_POSX 
LL_FACE_POSY 
LL_FACE_NEGX 
LL_FACE_NEGY 
LL_FACE_NEGZ 
LL_EDGE_NEGX_NEGY 
LL_EDGE_NEGX_POSY 
LL_EDGE_POSX_NEGY 
LL_EDGE_POSX_POSY 
LL_EDGE_NEGY_NEGZ 
LL_EDGE_NEGY_POSZ 
LL_EDGE_POSY_NEGZ 
LL_EDGE_POSY_POSZ 
LL_EDGE_NEGZ_NEGX 
LL_EDGE_NEGZ_POSX 
LL_EDGE_POSZ_NEGX 
LL_EDGE_POSZ_POSX 
LL_ROT_GENERAL 
LL_ROT_X 
LL_ROT_Y 
LL_ROT_Z 
LL_ROT_ROLL 

Definition at line 50 of file llmanip.h.

Enumerator:
LL_ARROW_MIN 
LL_ARROW_MAX 
LL_CORNER_MIN 
LL_CORNER_MAX 
LL_FACE_MIN 
LL_FACE_MAX 
LL_EDGE_MIN 
LL_EDGE_MAX 

Definition at line 106 of file llmanip.h.


Constructor & Destructor Documentation

LLManip::LLManip ( const LLString name,
LLToolComposite composite 
)

Definition at line 95 of file llmanip.cpp.


Member Function Documentation

void LLManip::rebuild ( LLViewerObject vobj  )  [static]

virtual BOOL LLManip::handleMouseDownOnPart ( S32  x,
S32  y,
MASK  mask 
) [pure virtual]

Implemented in LLManipRotate, LLManipScale, and LLManipTranslate.

Referenced by LLToolCompRotate::pickCallback(), LLToolCompScale::pickCallback(), and LLToolCompTranslate::pickCallback().

Here is the caller graph for this function:

void LLManip::renderGuidelines ( BOOL  draw_x = TRUE,
BOOL  draw_y = TRUE,
BOOL  draw_z = TRUE 
)

void LLManip::renderXYZ ( const LLVector3 vec  )  [static]

BOOL LLManip::handleMouseUp ( S32  x,
S32  y,
MASK  mask 
) [virtual]

Reimplemented from LLTool.

Reimplemented in LLManipRotate, LLManipScale, and LLManipTranslate.

Definition at line 233 of file llmanip.cpp.

References FALSE, LLTool::hasMouseCapture(), LLTool::setMouseCapture(), and TRUE.

Referenced by LLManipTranslate::handleMouseUp(), LLManipScale::handleMouseUp(), and LLManipRotate::handleMouseUp().

Here is the call graph for this function:

Here is the caller graph for this function:

BOOL LLManip::handleHover ( S32  x,
S32  y,
MASK  mask 
) [virtual]

Reimplemented from LLTool.

Reimplemented in LLManipRotate, LLManipScale, and LLManipTranslate.

Definition at line 210 of file llmanip.cpp.

References FALSE, gViewerWindow, LLTool::hasMouseCapture(), lldebugst, llendl, mObjectSelection, LLViewerWindow::setCursor(), LLTool::setMouseCapture(), TRUE, and UI_CURSOR_ARROW.

Here is the call graph for this function:

virtual void LLManip::highlightManipulators ( S32  x,
S32  y 
) [pure virtual]

Implemented in LLManipRotate, LLManipScale, and LLManipTranslate.

Referenced by LLToolCompRotate::pickCallback(), LLToolCompScale::pickCallback(), and LLToolCompTranslate::pickCallback().

Here is the caller graph for this function:

void LLManip::handleSelect (  )  [virtual]

Reimplemented from LLTool.

Reimplemented in LLManipRotate, LLManipScale, and LLManipTranslate.

Definition at line 195 of file llmanip.cpp.

References LLSelectMgr::getEditSelection(), LLSingleton< LLSelectMgr >::getInstance(), and mObjectSelection.

Referenced by LLManipTranslate::handleSelect(), LLManipScale::handleSelect(), and LLManipRotate::handleSelect().

Here is the call graph for this function:

Here is the caller graph for this function:

void LLManip::handleDeselect (  )  [virtual]

Reimplemented from LLTool.

Reimplemented in LLManipRotate, LLManipScale, and LLManipTranslate.

Definition at line 200 of file llmanip.cpp.

References mObjectSelection, and NULL.

Referenced by LLManipTranslate::handleDeselect(), LLManipScale::handleDeselect(), and LLManipRotate::handleDeselect().

Here is the caller graph for this function:

virtual BOOL LLManip::canAffectSelection (  )  [pure virtual]

Implemented in LLManipRotate, LLManipScale, and LLManipTranslate.

Referenced by LLToolCompTranslate::pickCallback().

Here is the caller graph for this function:

EManipPart LLManip::getHighlightedPart (  )  [inline]

LLObjectSelectionHandle LLManip::getSelection (  ) 

LLVector3 LLManip::getSavedPivotPoint (  )  const [protected]

Definition at line 343 of file llmanip.cpp.

References LLBBox::getCenterAgent(), LLSingleton< LLSelectMgr >::getInstance(), and LLSelectMgr::getSavedBBoxOfSelection().

Referenced by LLManipTranslate::renderSnapGuides().

Here is the call graph for this function:

Here is the caller graph for this function:

LLVector3 LLManip::getPivotPoint (  )  [protected]

void LLManip::getManipNormal ( LLViewerObject object,
EManipPart  manip,
LLVector3 normal 
) [protected]

BOOL LLManip::getManipAxis ( LLViewerObject object,
EManipPart  manip,
LLVector3 axis 
) [protected]

F32 LLManip::getSubdivisionLevel ( const LLVector3 reference_point,
const LLVector3 translate_axis,
F32  grid_scale,
S32  min_pixel_spacing = MIN_DIVISION_PIXEL_WIDTH 
) [protected]

void LLManip::renderTickValue ( const LLVector3 pos,
F32  value,
const char *  suffix,
const LLColor4 color 
) [protected]

void LLManip::renderTickText ( const LLVector3 pos,
const char *  suffix,
const LLColor4 color 
) [protected]

void LLManip::updateGridSettings (  )  [protected]

Definition at line 244 of file llmanip.cpp.

References LLControlGroup::getBOOL(), LLControlGroup::getS32(), gSavedSettings, and sGridMaxSubdivisionLevel.

Referenced by LLManipTranslate::renderSnapGuides(), and LLManipScale::renderSnapGuides().

Here is the call graph for this function:

Here is the caller graph for this function:

BOOL LLManip::getMousePointOnPlaneGlobal ( LLVector3d point,
S32  x,
S32  y,
LLVector3d  origin,
LLVector3  normal 
) const [protected]

BOOL LLManip::getMousePointOnPlaneAgent ( LLVector3 point,
S32  x,
S32  y,
LLVector3  origin,
LLVector3  normal 
) [protected]

BOOL LLManip::nearestPointOnLineFromMouse ( S32  x,
S32  y,
const LLVector3 b1,
const LLVector3 b2,
F32 a_param,
F32 b_param 
) [protected]

LLColor4 LLManip::setupSnapGuideRenderPass ( S32  pass  )  [protected]


Member Data Documentation

Reimplemented in LLManipScale, and LLManipTranslate.

Definition at line 155 of file llmanip.h.

Referenced by LLManipRotate::dragConstrained(), and LLManipRotate::renderSnapGuides().

F32 LLManip::sHelpTextVisibleTime = 2.f [static, protected]

F32 LLManip::sHelpTextFadeTime = 2.f [static, protected]

S32 LLManip::sNumTimesHelpTextShown = 0 [static, protected]

S32 LLManip::sMaxTimesShowHelpText = 5 [static, protected]

F32 LLManip::sGridMaxSubdivisionLevel = 32.f [static, protected]

F32 LLManip::sGridMinSubdivisionLevel = 1.f [static, protected]


The documentation for this class was generated from the following files:

Generated on Fri May 16 08:52:00 2008 for SecondLife by  doxygen 1.5.5