[ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
The module provides vector and matrix operations useful for 3D computer graphics.
Actually this module itself doesn't depend on GL; you can use this module alone to do matrix calculations. However, the structure of objects are designed so that they can be passed directly to Gauche-gl functions, reducing the overhead of type conversions.
The purpose of this module is to provide reasonable performance.
So the operations are fixed to 3D homogeneous coordinates,
i.e. a vector is 4-element column vector, and a matrix is 4x4
square matrix. If you want more flexibility, <array>
class in gauche.array
provides much more generic
structures, trading performance.
Elements of vectors and matrices are represented in float
internally. When you retrieve each element individually,
it is converted to double
, so you might see some precision
errors. There are lots of operations directly manipulate group of
elements without retrieving each element to Scheme world, avoiding
overhead of conversion.
6.1 Vectors and points | ||
6.2 Vector arrays and point arrays | ||
6.3 Matrices | ||
6.4 Quaternions |
[ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] |
This document was generated by Shiro Kawai on June, 7 2008 using texi2html 1.78.