summaryrefslogtreecommitdiffstats
path: root/src/LinearUpscale.h
diff options
context:
space:
mode:
authorSamuel Barney <samjbarney@gmail.com>2015-07-09 22:41:14 +0200
committerSamuel Barney <samjbarney@gmail.com>2015-07-09 22:41:14 +0200
commitdb3642de8958835fd26d0e525a311def3bef1cae (patch)
treef005bd76d8f22a28c1b95280642c73780c794e26 /src/LinearUpscale.h
parentFixes compilation failures on MacOSX 10.10 (diff)
downloadcuberite-db3642de8958835fd26d0e525a311def3bef1cae.tar
cuberite-db3642de8958835fd26d0e525a311def3bef1cae.tar.gz
cuberite-db3642de8958835fd26d0e525a311def3bef1cae.tar.bz2
cuberite-db3642de8958835fd26d0e525a311def3bef1cae.tar.lz
cuberite-db3642de8958835fd26d0e525a311def3bef1cae.tar.xz
cuberite-db3642de8958835fd26d0e525a311def3bef1cae.tar.zst
cuberite-db3642de8958835fd26d0e525a311def3bef1cae.zip
Diffstat (limited to '')
-rw-r--r--src/LinearUpscale.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/LinearUpscale.h b/src/LinearUpscale.h
index d4e9da82a..adc873912 100644
--- a/src/LinearUpscale.h
+++ b/src/LinearUpscale.h
@@ -184,15 +184,15 @@ template <typename TYPE> void LinearUpscale3DArray(
TYPE RatioZ[MAX_UPSCALE_Z];
for (int x = 0; x <= a_UpscaleX; x++)
{
- RatioX[x] = static_cast<TYPE>(x / a_UpscaleX);
+ RatioX[x] = static_cast<TYPE>(x) / a_UpscaleX;
}
for (int y = 0; y <= a_UpscaleY; y++)
{
- RatioY[y] = static_cast<TYPE>(y / a_UpscaleY);
+ RatioY[y] = static_cast<TYPE>(y) / a_UpscaleY;
}
for (int z = 0; z <= a_UpscaleZ; z++)
{
- RatioZ[z] = static_cast<TYPE>(z / a_UpscaleZ);
+ RatioZ[z] = static_cast<TYPE>(z) / a_UpscaleZ;
}
// Interpolate each XYZ cell: