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

Synopsis

snapMode [-curve boolean] [-edgeMagnet int] [-edgeMagnetTolerance double] [-grid boolean] [-liveFaceCenter boolean] [-livePoint boolean] [-point boolean] [-tolerance int] [-useTolerance boolean] [-uvTolerance int] [-viewPlane boolean]

snapMode is undoable, queryable, and editable.

The snapMode command is used to control snapping. It toggles the snapping modes in effect and sets information used for snapping.

Flags

curve, edgeMagnet, edgeMagnetTolerance, grid, liveFaceCenter, livePoint, point, tolerance, useTolerance, uvTolerance, viewPlane
Long name (short name) [argument types] Properties
-curve(-c) boolean createquery
Set curve snap mode

In query mode, this flag needs a value.

-point(-p) boolean createquery
Set point snap mode

In query mode, this flag needs a value.

-grid(-gr) boolean createquery
Set grid snap mode

In query mode, this flag needs a value.

-viewPlane(-vp) boolean createquery
Set view-plane snap mode

In query mode, this flag needs a value.

-livePoint(-lp) boolean createquery
While moving on live polygon objects, snap to its vertices.

In query mode, this flag needs a value.

-liveFaceCenter(-lfc) boolean createquery
While moving on live polygon objects, snap to its face centers.

In query mode, this flag needs a value.

-useTolerance(-ut) boolean createquery
If useTolerance is set, then point snapping is limited to points that are within a square region surrounding the cursor position. The size of the square is determined by the tolerance value.

In query mode, this flag needs a value.

-tolerance(-t) int createquery
Tolerance defines the size of the square region in which points must lie in order to be snapped to. The tolerance value is the distance from the cursor position to the boundary of the square (in all four directions).

In query mode, this flag needs a value.

-uvTolerance(-uvt) int createquery
uvTolerance defines the size of the square region in which points must lie in order to be snapped to, in the UV Texture Editor. The tolerance value is the distance from the cursor position to the boundary of the square (in all four directions).

In query mode, this flag needs a value.

-edgeMagnet(-em) int createquery
Number of extra magnets to snap onto, regularly spaced along the edge.

In query mode, this flag needs a value.

-edgeMagnetTolerance(-emt) double createquery
Precision for edge magnet snapping.

In query mode, this flag needs a value.


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


boolean - if command is a query

MEL examples

// Turn curve snapping on
snapMode -curve true;

// Returns true if point snapping is on
snapMode -q -point;