Editable Spline Modify Panel Command Modes and Operations

A suite of methods provide the ability for a script to invoke Editable Spline, Line, and Edit Spline Modify panel modes and operations, corresponding to buttons available at various shape sub-object levels. These methods reside in the splineOps global structure. These methods effectively "push the button" in the Modify panel. In order to use these methods, the node must be selected and the Modify panel open. In the description of these methods, the first argument should be interpreted as either an Editable Spline or Line node where the modifier stack level is at the base object, or an Edit Spline modifier where the modifier stack level is at the Edit Spline. In all cases, the following methods work at the current sub-object level, but only if that level is appropriate for the invoked operation.

If you have made scripted changes to the shape you must call the updateShape() method on the mesh before calling these methods. You do not need to call updateShape() after just calling one of these methods, as 3ds Max will take care of updating the shape.

The following methods invoke one of the 'user-interaction' button operations in the Editable Spline Modify panel, acting on the currently selected sub-objects. These methods highlight the corresponding button in the Geometry rollout and start the operation, at which point the user interactively completes the operation. These methods return after starting the operation, and before the user completes the operation, so care should be taken to ensure that your script does not interfere with the operation. Invoking any of these methods is the same as clicking on the associated button in the Modify panel. Calling a method when the operation is already in effect (either due to a user action or a MAXScript command) causes the operation to be terminated and the highlight is removed from the button.

splineOps.startUnion

Enters "Boolean Union" command mode - valid in Spline Sub-Object level. Only 1 closed spline must be selected to enter this command mode.

splineOps.startSubtract

Enters "Boolean Subtract" command mode - valid in Spline Sub-Object level. Only 1 closed spline must be selected to enter this command mode.

splineOps.intersect

Enters "Boolean Intersect" command mode - valid in Spline Sub-Object level. Only 1 closed spline must be selected to enter this command mode.

splineOps.startAttach

Enters "Attach" command mode - valid in all Sub-Object levels, and when not in Sub-Object mode.

splineOps.startBind

Enters "Bind" command mode - valid in Vertex Sub-Object level.

splineOps.startBreak

Enters "Break" command mode - valid in Vertex and Segment Sub-Object levels.

splineOps.startChamfer

Enters "Chamfer" command mode - valid in Vertex Sub-Object level.

splineOps.startConnect

Enters "Connect" command mode - valid in Vertex Sub-Object level.

splineOps.startCreateLine

Enters "Create Line" command mode - valid in all Sub-Object levels, and when not in Sub-Object mode.

splineOps.startCrossInsert

Enters "CrossInsert" command mode - valid in Vertex Sub-Object level.

splineOps.startExtend

Enters "Extend" command mode - valid in Spline Sub-Object level.

splineOps.startFillet

Enters "Fillet" command mode - valid in Vertex Sub-Object level.

splineOps.startInsert

Enters "Insert" command mode - valid in all Sub-Object levels, and when not in Sub-Object mode.

splineOps.startOutline

Enters "Outline" command mode - valid in Spline Sub-Object level.

splineOps.startRefine

Enters "Refine" command mode - valid in Vertex and Segment Sub-Object levels. This method does not turn off the Connect checkbox, so it is effectively the same as the startRefineConnect() method.

splineOps.startRefineConnect

Enters "Refine" command mode - valid in Vertex and Segment Sub-Object levels. This method does not turn on the Connect checkbox, so it is effectively the same as the startRefine() method.

splineOps.startTrim

Enters "Trim" command mode - valid in Spline Sub-Object level.

splineOps.startCopyTangent

Enters "Copy Tangent" command mode - valid in Vertex Sub-Object level.

splineOps.startPasteTangent

Enters "Paste Tangent" command mode - valid in Vertex Sub-Object level.

The following methods invoke one of the 'instantaneous' button operations in the Editable Shape Modify panel, acting on the currently selected sub-objects:

splineOps.attachMultiple

Displays Attach Multiple dialog allowing the user to select multiple shapes to attach. Valid in all Sub-Object levels, and when not in Sub-Object mode.

splineOps.close

Closes the selected splines - valid in Spline Sub-Object level.

splineOps.cycle

Cycles through the vertices of the spline, selecting each vertex. At least one vertex must be selected before calling this method, or no vertex is selected. If more than one vertex is selected when this method is called, the first vertex of the first shape is selected. Valid in Vertex Sub-Object level.

splineOps.delete

Deletes the selected sub-objects - valid in all Sub-Object levels.

splineOps.detach

Displays Detach dialog allowing the user to specify an object name. Valid in all Sub-Object levels.

splineOps.divide

Divides the selected segments - valid in Segment Sub-Object level.

splineOps.explode

Explodes the each segment in the selected splines into separate splines or objects. Valid in Spline Sub-Object level.

splineOps.fuse

Fuses the selected vertices. Valid in Vertex Sub-Object level.

splineOps.hide

Hides the selected sub-objects - valid in all Sub-Object levels.

splineOps.makeFirst

Makes the selected vertices the first vertex in the spline- valid in Vertex Sub-Object level.

splineOps.mirrorBoth

Mirrors the selected splines horizontally and vertically - valid in Spline Sub-Object level.

splineOps.mirrorHoriz

Mirrors the selected splines horizontally - valid in Spline Sub-Object level.

splineOps.mirrorVert

Mirrors the selected splines vertically - valid in Spline Sub-Object level.

splineOps.reverse

Reverses the order of vertices in the selected splines - valid in Spline Sub-Object level.

splineOps.selectByID

Presses the Select ID button

splineOps.unbind

Unbinds the selected vertices - valid in Vertex Sub-Object level.

splineOps.unhideAll

Unhides all hidden sub-objects -valid in all Sub-Object levels, and when not in Sub-Object mode.

splineOps.weld

Welds the selected vertices - valid in Vertex Sub-Object level.

See also

SplineShape : Shape

?

How To ... Flatten a SplineShape

How To ... Draw a Freehand Spline