Point3D

From Silhouette Wiki
Revision as of 19:35, 18 November 2012 by Paul (talk | contribs) (Created page with "A Point3D represents a 2D or 3D point. Points can be added, subtracted, multiplied, and divided by other Points, multiplied and divided by scalars, and support the negative op...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

A Point3D represents a 2D or 3D point. Points can be added, subtracted, multiplied, and divided by other Points, multiplied and divided by scalars, and support the negative operator to invert the axis values.

Points can be manipulated by getting and setting the x, y, and z attributes.

By default a Point3D is constructed at (0, 0, 0).

>> p = Point3D(1, 0)
>> p = p * 2.0
>> print p
Point3D(2.0,0.0)