void Mesh::RotateAboutXAboutPoint(float angle, Vector point) { Triangle *tri = tris; for(int i = 0; i < numTris; i++, tri++) { tri->RotateAboutXAboutPoint(angle, point); } centroidChanged = true; rotation.x += angle; }
void Mesh::RotateAboutX(float angle) { Vector c = ComputeCentroid(); Triangle *tri = tris; for(int i = 0; i < numTris; i++, tri++) { tri->RotateAboutXAboutPoint(angle, c); } rotation.x += angle; }