List of: Scheme Extensions
Subjects: Mathematics
Contents: Kernel

Action: Sets the x-direction component of a gvector.

Filename: kern/kern_scm/gvec_scm.cxx

Syntax: (gvector:set-x! gvector x)

Arg Types: gvector gvector

x real

Returns: real

Description: The coordinates are computed relative to the active coordinate system. This extension returns the x-value as a real.

gvector specifies the original x-, y-, and z-values.

x specifies the value to replace the original x-value specified in gvector.

Example: ; gvector:set-x!

; Set new x-, y-, and z-components

; in an existing gvector.

(define vector1 (gvector 1 0 0))

;; vector1

; Set a new x-component in an existing gvector.

(gvector:set-x! vector1 3)

;; 3