diff options
author | Daniel Genrich <daniel.genrich@gmx.net> | 2012-08-10 13:58:58 +0400 |
---|---|---|
committer | Daniel Genrich <daniel.genrich@gmx.net> | 2012-08-10 13:58:58 +0400 |
commit | a1dd6ea83616b2ed1b78d1a6c48761d94018e714 (patch) | |
tree | ee86a4c5788a716ac92500f8cbdd25cb4e97fd88 /intern | |
parent | 56b2f4df03728f18252288172bd14d2eecd98f41 (diff) |
Smoke: High res on even resolution did not write to all cells (downsampling = n-1, upsampling = n).
Thanks goes to MiikaH.
Diffstat (limited to 'intern')
-rw-r--r-- | intern/smoke/intern/WAVELET_NOISE.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/intern/smoke/intern/WAVELET_NOISE.h b/intern/smoke/intern/WAVELET_NOISE.h index 4806c6a9fc1..fce901b68aa 100644 --- a/intern/smoke/intern/WAVELET_NOISE.h +++ b/intern/smoke/intern/WAVELET_NOISE.h @@ -107,7 +107,7 @@ static void downsampleNeumann(const float *from, float *to, int n, int stride) // if these values are not local incorrect results are generated float downCoeffs[32] = { DOWNCOEFFS }; const float *const aCoCenter= &downCoeffs[16]; - for (int i = 0; i < ceil((float)n / 2); i++) { + for (int i = 0; i <= n / 2; i++) { to[i * stride] = 0; for (int k = 2 * i - 16; k < 2 * i + 16; k++) { // handle boundary |