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

render code relocation, mouse wheel zoom control

This commit is contained in:
tmj-fstate
2017-03-10 17:40:52 +01:00
parent b5ae395c42
commit 3708a01d26
20 changed files with 579 additions and 308 deletions

View File

@@ -23,7 +23,7 @@ class float3
y = b;
z = c;
};
double inline Length() const;
float inline Length() const;
};
inline bool operator==(const float3 &v1, const float3 &v2)
@@ -49,9 +49,9 @@ inline float3 operator+(const float3 &v1, const float3 &v2)
{
return float3(v1.x + v2.x, v1.y + v2.y, v1.z + v2.z);
};
double inline float3::Length() const
float inline float3::Length() const
{
return sqrt(x * x + y * y + z * z);
return std::sqrt(x * x + y * y + z * z);
};
inline float3 operator*( float3 const &v, float const k ) {
return float3( v.x * k, v.y * k, v.z * k );