16
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-07-22 16:19:19 +02:00

working vehicle spotlights

This commit is contained in:
tmj-fstate
2017-02-25 21:02:27 +01:00
parent 259e9042e1
commit 493340e602
11 changed files with 353 additions and 184 deletions

View File

@@ -415,6 +415,11 @@ inline vector3 CrossProduct(const vector3 &v1, const vector3 &v2)
return vector3(v1.y * v2.z - v1.z * v2.y, v2.x * v1.z - v2.z * v1.x, v1.x * v2.y - v1.y * v2.x);
}
inline vector3 Interpolate( vector3 const &First, vector3 const &Second, float const Factor ) {
return ( First * ( 1.0f - Factor ) ) + ( Second * Factor );
}
inline vector3 operator*(const matrix4x4 &m, const vector3 &v)
{
return vector3(v.x * m[0][0] + v.y * m[1][0] + v.z * m[2][0] + m[3][0],