All Manuals > CAPI Reference Manual > 2 GP Reference Entries

NextPrevUpTopContentsIndex

make-transform

Function
Summary

Returns a new transform object initialized according to a set of optional arguments.

Package

graphics-ports

Signature

make-transform &optional a b c d e f => transform

Arguments

a

A real number.

b

A real number.

c

A real number.

d

A real number.

e

A real number.

f

A real number.

Values

transform

A transform object.

Description

The make-transform function returns a new transform object initialized according to the optional args. The default args make the unit transform.

Default values are as follows: a and d are 1; b , c , e , and f are 0. The transform matrix is

    a  b  0
    c  d  0
    e  f  1

for generalized two dimensional points of the form (x y 1) .

Example

This transform will cause rotation by pi/4 radians:

(let ((s (sin (/ pi 4)))
      (c (cos (/ pi 4))))
  (gp:make-transform  c  s (- s) c 0 0))

CAPI Reference Manual - 15 Dec 2011

NextPrevUpTopContentsIndex