Go to: Synopsis. Flags. Return value. Related. MEL examples.

Synopsis

trim [-constructionHistory boolean] [-curveOnSurface boolean] [-locatorU float] [-locatorV float] [-name string] [-object boolean] [-polygon int] [-range boolean] [-rebuild boolean] [-replaceOriginal boolean] [-selected int] [-shouldBeLast boolean] [-shrink boolean] [-tolerance linear] [-usedCurves boolean] object1 [object2] ...

trim is undoable, queryable, and editable.

This command trims a surface to its curves on surface by first splitting the surface and then selecting which regions to keep or discard.

Flags

constructionHistory, curveOnSurface, locatorU, locatorV, name, object, polygon, range, rebuild, replaceOriginal, selected, shouldBeLast, shrink, tolerance, usedCurves
Long name (short name) [argument types] Properties
-locatorU(-lu) float queryeditmultiuse
u parameter value to position a locator on the surface.
Default: 0.5

In query mode, this flag needs a value.

-locatorV(-lv) float queryeditmultiuse
v parameter value to position a locator on the surface.
Default: 0.5

In query mode, this flag needs a value.

-selected(-sl) int queryedit
Specify whether to keep or discard selected regions.
Default: 0

In query mode, this flag needs a value.

-shrink(-sh) boolean queryedit
If true, shrink underlying surface to outer boundaries of trimmed surface.
Default: false

In query mode, this flag needs a value.

-tolerance(-tol) linear queryedit
The tolerance with which to trim.
Default: 0.001

In query mode, this flag needs a value.

-usedCurves(-uc) boolean queryeditmultiuse
Flag each curve as used or not used in trimming.

In query mode, this flag needs a value.

-shouldBeLast(-sbl) boolean queryedit
If true, then deformers will let this trim node be last
Default: true

In query mode, this flag needs a value.

-name(-n) string create
Name the resulting object
-constructionHistory(-ch) boolean create
Turn the construction history on or off (not available in all commands)
-object(-o) boolean create
Create the result, or just the dependency node (not available in all commands)
-replaceOriginal(-rpo) boolean create
Create "in place" (i.e., replace) (not available in all commands)
-curveOnSurface(-cos) boolean create
If possible, create 2D curve as a result (not available in all commands)
-polygon(-po) int create
The value of this argument controls the type of the object created by this operation (not available in all commands)
  • 0: nurbs surface
  • 1: polygon (use nurbsToPolygonsPref to set the parameters for the conversion)
  • 2: subdivision surface (use nurbsToSubdivPref to set the parameters for the conversion)
  • 3: Bezier surface
  • 4: subdivision surface solid (use nurbsToSubdivPref to set the parameters for the conversion)
-range(-rn) boolean create
Force a curve range on complete input curve (not available in all commands)
-rebuild(-rb) boolean create
Rebuild the input curve(s) before using them in the operation. Use nurbsCurveRebuildPref to set the parameters for the conversion. (not available in all commands)

Flag can appear in Create mode of command Flag can appear in Edit mode of command
Flag can appear in Query mode of command Flag can be used more than once in a command

Return value


[string] (object name and node name)

Related

intersect, projectCurve, untrim

MEL examples

// Keep all selected regions
trim -sl 0;

// Discard all selected regions
trim -sl 1;

// shrink the underlying surface to just outside the
// outermost boundary curve
trim -sh 1;