From be674afdadaa1ab966147755e224e8bbda6807db Mon Sep 17 00:00:00 2001 From: Daniel Genrich Date: Sun, 19 Feb 2012 21:15:12 +0000 Subject: [PATCH] Bugfix (missed one code line): Copy paste induced bug found by Sv. Lockal. Thank you for pointing this out! --- intern/smoke/intern/FLUID_3D.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/intern/smoke/intern/FLUID_3D.cpp b/intern/smoke/intern/FLUID_3D.cpp index adf43a29790..9f036cc6d2f 100644 --- a/intern/smoke/intern/FLUID_3D.cpp +++ b/intern/smoke/intern/FLUID_3D.cpp @@ -1152,7 +1152,7 @@ void FLUID_3D::addVorticity(int zBegin, int zEnd) float dz = (out == vIndex || in == vIndex) ? 1.0f / _dx : gridSize; int right = _obstacles[index + 1] ? vIndex : vIndex + 1; int left = _obstacles[index - 1] ? vIndex : vIndex - 1; - float dx = (right == vIndex || right == vIndex) ? 1.0f / _dx : gridSize; + float dx = (right == vIndex || left == vIndex) ? 1.0f / _dx : gridSize; N[0] = (_vorticity[right] - _vorticity[left]) * dx; N[1] = (_vorticity[up] - _vorticity[down]) * dy; N[2] = (_vorticity[out] - _vorticity[in]) * dz;