BaseSculptTool (object)¶
バージョン 2.0 で追加.
BaseSculptTool is a based class for sculpting tools.
注釈
This is a work in progress, needs to be generalized to abstract the type of attribute being painted.
Members¶
Boolean | enabled | Handler is enabled. |
Key | enableKey | Enable key. |
HandlerExclusivity | handlerExclusivity | Handler exclusivity. |
Boolean | isIndependent | HandlerExclusivity local override. |
Boolean | takeAllEvents | It true, the handler takes all the events. |
Boolean | alwaysEnabled | It true, the handler takes all the events. |
Boolean | isOwnedByDispatcher | Checks if the handler is owned by a handlerDispatcher. In most of the cases, the dispatcher owns the handlers. However, it’s not true in DFG graphs where the handlers are owns by the nodes. |
Ref<HandlerDispatcher> | dispatcher | Reference to the dispatcher. |
ToolTarget | target | Tool target. |
Boolean | performing | True if the tool is performing an action. |
ManipulationMode | mode | Paint mode, see ToolConstants.kl. |
Mat44 | transform | Transform (SRT). |
Mat44 | currentGeometryTransform | Since we paint in local space, the brush should be drawn in local geometry scaling space. |
Float32 | radius | Slider radius. |
String | attributeName | Color blend geometry attributes. |
PaintToolAttributeStrokeData | attributeStack | Stack attributes, for undo-redo. |
IndexSet | tempPointSet | Temporary buffer for holding the filtered point set. |
GeometryAttribute | tempAttribute | Temporary buffer for smoothing. |
Key | resetKey | Reset the painting, i.e the geometry attributes. |
Vec3 | initialAxis | Tool initial direction. |
Float32 | strength | Strength of the sculpt. The more it’s high, the more the mesh is deformed. |
Methods¶
BaseSculptTool ( in BaseSculptTool other ) | |
BaseSculptTool () | |
BaseSculptTool | clone ? () |
Vec3 | computeDisplacementDir ? ( in Ref<PolygonMesh> mesh ) |
ensureAttributeExists ! ( io Ref<Geometry> geometry, in Boolean resetValues ) | |
Float32 | getStrength ? () |
init ! ( in BasePaintTarget target, in Key enableKey, in Key resetKey, in Float32 initialRadius, in Float32 initialStrength ) | |
paintPolygons ! ( io Ref<PolygonMesh> mesh, in GeometryLocation location ) | |
release ! ( io MouseEvent mouseEvent ) | |
setPointAttribute ! ( in Index i, in Float32 weight, in Vec3 displacementDir, io Ref<PolygonMesh> mesh ) | |
setStrength ! ( in Float32 strength ) | |
smoothPointAttribute ! ( in Index i, in Float32 weight, in Vec3 displacementDir, io Ref<PolygonMesh> mesh ) |
Methods in detail¶
BaseSculptTool ( in BaseSculptTool other )
copy constructor
default constructor
BaseSculptTool BaseSculptTool.clone? ()
clone method
Vec3 BaseSculptTool.computeDisplacementDir? ( in Ref<PolygonMesh> mesh )
Implementation of PaintTool.
BaseSculptTool.ensureAttributeExists! ( io Ref<Geometry> geometry, in Boolean resetValues )
Implementation of PaintTool.
Float32 BaseSculptTool.getStrength? ()
Gets the sculpt strength.
BaseSculptTool.init! ( in BasePaintTarget target, in Key enableKey, in Key resetKey, in Float32 initialRadius, in Float32 initialStrength )
Initializes a BaseSculptTool.
target | Tool target. |
enableKey | Key to enable to tool. |
resetKey | Key to reset the painting. |
initialRadius | Initial sculpt-tool radius. |
initialStrength | Initial sculpt-tool strength. |
BaseSculptTool.paintPolygons! ( io Ref<PolygonMesh> mesh, in GeometryLocation location )
Implementation of PaintTool.
BaseSculptTool.release! ( io MouseEvent mouseEvent )
Implementation of Tool.
BaseSculptTool.setPointAttribute! ( in Index i, in Float32 weight, in Vec3 displacementDir, io Ref<PolygonMesh> mesh )
Implementation of PaintTool.
BaseSculptTool.setStrength! ( in Float32 strength )
Sets the sculpt strength.
strength | The tool new strengh. |
BaseSculptTool.smoothPointAttribute! ( in Index i, in Float32 weight, in Vec3 displacementDir, io Ref<PolygonMesh> mesh )
Implementation of PaintTool.