mirror of
https://github.com/yuzu-emu/FasTC
synced 2024-11-23 17:13:39 +00:00
Fix bug with kernel generation.
This commit is contained in:
parent
68f2f4a8b3
commit
5af29c87d0
1 changed files with 2 additions and 2 deletions
|
@ -538,8 +538,8 @@ void GenerateGaussianKernel(Image<IPixel> &out, uint32 size, float sigma) {
|
||||||
}
|
}
|
||||||
|
|
||||||
int32 halfSz = static_cast<int32>(size) / 2;
|
int32 halfSz = static_cast<int32>(size) / 2;
|
||||||
for(int32 j = -halfSz; j < halfSz; j++) {
|
for(int32 j = -halfSz; j <= halfSz; j++) {
|
||||||
for(int32 i = -halfSz; i < halfSz; i++) {
|
for(int32 i = -halfSz; i <= halfSz; i++) {
|
||||||
out(halfSz + i, halfSz + j) = exp(- (j*j + i*i) / (2*sigma*sigma));
|
out(halfSz + i, halfSz + j) = exp(- (j*j + i*i) / (2*sigma*sigma));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue