ATS3D is a low-dimensional vector algebra library for ATS2. With a small rasterizer based on it.
- 2- 3- and 4-dimensional vectors
- 3x3- and 4x4-dimensional matrices
- function templates for iterating over components of a vector
- quaternion
Working with 3D vectors:
var a : vec3f
val () = a.init (~1.0f)
var b : vec3f
val () = b.init (1.0f, 0.0f, 0.0f)
val () = println!("a.x = ", a.x())
var c = a + b
val () = println!("c = ", c)
Simply run make
in src/TEST
.
Gouraud-shaded, untextured Wavefront OBJ meshes rendered using
test04.exe
:
Distributed under the 3-clause BSD (see the LICENSE file)
Mesh files are copyright their respective owners.
--Artyom Shalkhakov