Function Entry: TRANS
← Prev | ↑ Chapter | Next → | Index | Symbols
Function Entry: TRANS
Name
trans
Class
Function
Syntax
(trans pt from to [disp])
Arguments and Values
pt: a list of three reals, interpreted as a 3D point or as a 3D displacement.from: an integer, list, or ename naming the source coordinate system. Designators are:0: WCS — World Coordinate System1: UCS — current User Coordinate System2: DCS — viewport Display Coordinate System3: PSDCS — paper-space DCS (only valid as the to designator and only from2)- an ename: the Object Coordinate System of that entity
- a list (extrusion vector): the OCS implied by that extrusion
to: same designator vocabulary asfrom.disp(optional): when non-nil, treatsptas a displacement rather than a point (so translation components of the transform are skipped).
Description
Translates a point or a displacement from one coordinate system to another. When converting between systems whose Z-axes differ, this function applies the proper rotation.
Return Values
A 3D point (or displacement) expressed in the to coordinate system.
Side Effects
None.
Examples
(trans '(1.0 2.0 3.0) 0 1)returns(2.0 -1.0 3.0)when the UCS is rotated 90° counter-clockwise relative to the WCS.(trans text-insert-point text-ename 1)converts a text-entity insertion point from its OCS to the current UCS.(trans '(1 2 3) 1 circle-ename)converts a UCS displacement to a circle's OCS.
Availability
- AutoCAD 2026: documented.
- BricsCAD V26: presumed compatible.
- Status: AutoCAD documented; BricsCAD presumed-both pending Phase 4 verification.
Source Notes
- [trans (AutoLISP 2026)](https://help.autodesk.com/cloudhelp/2026/ENU/AutoCAD-AutoLISP-Reference/files/GUID-1A316343-0B68-4DBE-8F49-B4D601CB8FCC.htm)
- Status: documented (Phase 3 body fill).