summaryrefslogtreecommitdiffhomepage
path: root/Stars45/Water.cpp
diff options
context:
space:
mode:
authorAki <please@ignore.pl>2022-01-30 17:41:24 +0100
committerAki <please@ignore.pl>2022-01-30 17:41:24 +0100
commit51657e10769faa2617d546a06c42e4c62a19bb50 (patch)
tree688ad8b61ac02e50974684b9b7d3f886fb469e5f /Stars45/Water.cpp
parentdb987e23d5dd33a5db8764743facbb906ac22b0f (diff)
downloadstarshatter-51657e10769faa2617d546a06c42e4c62a19bb50.zip
starshatter-51657e10769faa2617d546a06c42e4c62a19bb50.tar.gz
starshatter-51657e10769faa2617d546a06c42e4c62a19bb50.tar.bz2
Removed trailing whitespace all over the place
Diffstat (limited to 'Stars45/Water.cpp')
-rw-r--r--Stars45/Water.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/Stars45/Water.cpp b/Stars45/Water.cpp
index 83457c0..d1d0a0f 100644
--- a/Stars45/Water.cpp
+++ b/Stars45/Water.cpp
@@ -46,7 +46,7 @@ struct WATER_REFRACT
{
// Vrefract = (V + refract * N) * norm
float refract;
- float refractNorm;
+ float refractNorm;
DWORD diffuse;
};
@@ -59,11 +59,11 @@ struct WATER_SURFACE
// +--------------------------------------------------------------------+
#if defined(_X86) && !defined(_WIN64)
-inline int f2i(float flt)
+inline int f2i(float flt)
{
- volatile int n;
+ volatile int n;
- __asm
+ __asm
{
fld flt
fistp n
@@ -72,7 +72,7 @@ inline int f2i(float flt)
return n;
}
#else
-inline int f2i(float flt)
+inline int f2i(float flt)
{
return (int) flt;
}
@@ -117,7 +117,7 @@ Water::Init(int n, float s, float d)
if (!refractInit) {
WATER_REFRACT* refract = &RefractionTable[256];
- for (UINT u = 0; u < 256; u++) {
+ for (UINT u = 0; u < 256; u++) {
float fCos0 = (float) u / (float) 256.0f;
float f0 = acosf(fCos0);
float fSin0 = sinf(f0);
@@ -222,7 +222,7 @@ Water::CalcWaves(double seconds)
Vec3 vecN;
float f;
- f = surface[uXN + uYN].height - surface[uXP + uYP].height; vecN.x = vecN.z = f;
+ f = surface[uXN + uYN].height - surface[uXP + uYP].height; vecN.x = vecN.z = f;
f = surface[uX0 + uYN].height - surface[uX0 + uYP].height; vecN.z += f;
f = surface[uXP + uYN].height - surface[uXN + uYP].height; vecN.x -= f; vecN.z += f;
f = surface[uXN + uY0].height - surface[uXP + uY0].height; vecN.x += f;