smooth height map tool. More...
#include <FeatherTool.h>
Inherits Tool.
Public Member Functions | |
| FeatherTool (void) | |
| Constructor. | |
| ~FeatherTool (void) | |
| Destructor. | |
| virtual void | mouseDown (TTrackingMode m, CPoint viewPt, WbView *pView, CWorldBuilderDoc *pDoc) |
| Start tool. | |
| virtual void | mouseUp (TTrackingMode m, CPoint viewPt, WbView *pView, CWorldBuilderDoc *pDoc) |
| End tool. | |
| virtual void | mouseMoved (TTrackingMode m, CPoint viewPt, WbView *pView, CWorldBuilderDoc *pDoc) |
| Execute the tool. | |
| virtual WorldHeightMapEdit * | getHeightMap (void) |
| virtual void | activate () |
| Become the current tool. | |
Public Member Functions inherited from Tool | |
| Tool (Int toolID, Int cursorID) | |
| Tool class. | |
| virtual | ~Tool (void) |
| Destructor. | |
| Int | getToolID (void) |
| virtual void | setCursor (void) |
| virtual void | deactivate () |
| virtual Bool | followsTerrain (void) |
| Become not the current tool. | |
Static Public Member Functions | |
| static void | setFeather (Int feather) |
| Set the brush feather and notify the height options panel of the change. | |
| static void | setRate (Int rate) |
| Set the brush feather and notify the height options panel of the change. | |
| static void | setRadius (Int Radius) |
| Set the brush feather and notify the height options panel of the change. | |
Static Public Member Functions inherited from Tool | |
| static Real | calcRoundBlendFactor (CPoint center, Int x, Int y, Int brushWidth, Int featherWidth) |
| Calculate the round blend factor. | |
| static Real | calcSquareBlendFactor (CPoint center, Int x, Int y, Int brushWidth, Int featherWidth) |
| Calculate the square blend factor. | |
| static void | getCenterIndex (Coord3D *docLocP, Int brushWidth, CPoint *center, CWorldBuilderDoc *pDoc) |
| Gets the cell index for the center of the brush. | |
| static void | getAllIndexesIn (const Coord3D *bl, const Coord3D *br, const Coord3D *tl, const Coord3D *tr, Int widthOutside, CWorldBuilderDoc *pDoc, VecHeightMapIndexes *allIndices) |
Protected Attributes | |
| WorldHeightMapEdit * | m_htMapEditCopy |
| WorldHeightMapEdit * | m_htMapFeatherCopy |
| WorldHeightMapEdit * | m_htMapRateCopy |
Protected Attributes inherited from Tool | |
| Int | m_toolID |
| Int | m_cursorID |
| HCURSOR | m_cursor |
| Int | m_prevXIndex |
| Int | m_prevYIndex |
Static Protected Attributes | |
| static Int | m_feather = 0 |
| static Int | m_rate = 0 |
| static Int | m_radius = 0 |
smooth height map tool.
FeatherTool Does the smooth height map tool operation.
Definition at line 35 of file FeatherTool.h.
| FeatherTool::FeatherTool | ( | void | ) |
Constructor.
Definition at line 42 of file FeatherTool.cpp.
| FeatherTool::~FeatherTool | ( | void | ) |
Destructor.
Definition at line 51 of file FeatherTool.cpp.
|
virtual |
Become the current tool.
Shows the brush options panel.
Reimplemented from Tool.
Definition at line 61 of file FeatherTool.cpp.
|
inlinevirtual |
Reimplemented from Tool.
Definition at line 56 of file FeatherTool.h.
|
virtual |
Start tool.
Setup the tool to start brushing - make a copy of the height map to edit, another copy because we need it :), and call mouseMovedDown.
Reimplemented from Tool.
Definition at line 102 of file FeatherTool.cpp.
|
virtual |
Execute the tool.
Smooth the height map at the current point.
Reimplemented from Tool.
Definition at line 140 of file FeatherTool.cpp.
|
virtual |
End tool.
Finish the tool operation - create a command, pass it to the doc to execute, and cleanup ref'd objects.
Reimplemented from Tool.
Definition at line 126 of file FeatherTool.cpp.
|
static |
Set the brush feather and notify the height options panel of the change.
Definition at line 69 of file FeatherTool.cpp.
|
static |
Set the brush feather and notify the height options panel of the change.
Definition at line 90 of file FeatherTool.cpp.
|
static |
Set the brush feather and notify the height options panel of the change.
Definition at line 80 of file FeatherTool.cpp.
|
staticprotected |
Definition at line 42 of file FeatherTool.h.
|
protected |
Definition at line 38 of file FeatherTool.h.
|
protected |
Definition at line 39 of file FeatherTool.h.
|
protected |
Definition at line 40 of file FeatherTool.h.
|
staticprotected |
Definition at line 44 of file FeatherTool.h.
|
staticprotected |
Definition at line 43 of file FeatherTool.h.