XformScale

Returns a scale transformation matrix.

Syntax

rhinoscriptsyntax.XformScale ( scale, point=None )

rhinoscript.transformation.XformScale ( scale, point=None )

Parameters

scale

Required.  Single number, list of 3 numbers, Point3d, or Vector3d.  The scale factor. In the case of a single number, a uniform scale is produced. In all other cases a non-uniform scale is produced.

point

Optional.  Center of scale. If omitted, the world origin is used.

Returns

Transform

The 4x4 transformation matrix.

None

on error

Example

import rhinoscriptsyntax as rs

objs = rs.GetObjects("Select objects to scale")

if objs:

    xform = rs.XformScale( (3.0,1.0,1.0) )

    rs.TransformObjects( objs, xform, True)

Also See

XformMirror

XformPlanarProjection

XformRotation

XformShear

XformTranslation