Skip to content

Latest commit

 

History

History
15 lines (11 loc) · 1.21 KB

File metadata and controls

15 lines (11 loc) · 1.21 KB

include/vsg/maths headers

The include/vsg/maths header directory contains the vector, matrix classes and maths functions. The interface and conventions are kept the same as GLSL so C++ usage can be kept consistent with shaders usage.

The vector and maths classes are simple types, do not subclass from vsg::Object, so should be treated like ints, floats etc. The memory storage used aligns with the types expected by Vulkan so can be used directly for uniform, vertex and image data.

Vector classes

Matrix classes

  • include/vsg/maths/mat4.h - template class for 4x4 matrix, providing vsg::mat4 (float) and vsg::dmat4 (double) versions.

Matrix/Vector support functions