Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
05 ArchiCAD 11 GDL Reference Guide.pdf
Скачиваний:
59
Добавлен:
11.03.2015
Размер:
3.22 Mб
Скачать

Coordinate Transformations

Defines a complete transformations matrix. It is mainly used in automatic GDL code generation. It has only one entry in the stack.

x' = a11 * x + a12 * y + a13 * z + a14 y' = a21 * x + a22 * y + a23 * z + a24 z' = a31 * x + a32 * y + a33 * z + a34

Example:

A=60

B=30

XFORM 2, COS(A), COS(B)*0.6, 0, 0, SIN(A), SIN(B)*0.6, 0, 0, 0, 1, 0

BLOCK 1, 1, 1

MANAGING THE TRANSFORMATION STACK

DEL n

DEL n [, begin_with]

Deletes n entries from the transformation stack.

If the begin_with parameter is not specified, deletes the previous n entries in the transformation stack. The local coordinate system moves back to a previous position.

If the begin_with transformation is specified, deletes n entries forward, beginning with the one denoted by begin_with. Numbering starts with 1. If the begin_with parameter is specified and n is negative, deletes backward.

If fewer transformations were issued in the current script than denoted by the given n number argument, then only the issued transformations are deleted.

DEL TOP

DEl TOP

Deletes all current transformations in the current script.

ArchiCAD 11 GDL Reference Guide

29

Coordinate Transformations

NTR

NTR ()

Returns the actual number of transformations.

Example:

BLOCK 1, 1, 1 ADDX 2

ADDY 2.5

ADDZ 1.5

ROTX -60

ADDX 1.5

BLOCK 1, 0.5, 2

DEL 1, 1 !Deletes the ADDX 2 transformation

BLOCK 1, 0.5, 1

DEL 1, NTR() -2 !Deletes the ADDZ 1.5 transformation

BLOCK 1, 0.5, 2

DEL -2, 3 !Deletes the ROTX -60 and ADDY 2.5 transformations

BLOCK 1, 0.5, 2

30

ArchiCAD 11 GDL Reference Guide