Project

General

Profile

Nightshade NG vs Nightshade 11 mathematical conventions

Row-major vs. column major matrices

This is a very important difference. The Nighshade 11 code used column-major matrices. OSG and thus Nightshade NG uses row-major. Row-major works like you were taught in linear algebra class. Matrix operations are left to right. Column major works like in the OpenGL specification where matrix operations are right to left. It also means that when declaring matrices via a constructor, the NightshadeNG layout will appear to be the transpose of the identical matrix declared in Nightshade 11. In a nutshell, everything about matrices in Nightshade NG is completely backwards from Nightshade 11; beware.