Fix a width/height confusion in the healing tool algorithm
As pointed out by Massimo Valentini in bug #519503, the code used height where width should have been used. Correct.
This commit is contained in:
parent
18fa57b7f2
commit
f7ff0903ff
1 changed files with 7 additions and 6 deletions
|
|
@ -300,17 +300,18 @@ gimp_heal_laplace_iteration (gdouble *matrix,
|
|||
gdouble *solution,
|
||||
guchar *mask)
|
||||
{
|
||||
gint rowstride = width * depth;
|
||||
gint i, j, k;
|
||||
gdouble tmp, diff;
|
||||
gdouble err = 0.0;
|
||||
const gint rowstride = width * depth;
|
||||
gint i, j, k;
|
||||
gdouble tmp, diff;
|
||||
gdouble err = 0.0;
|
||||
|
||||
for (i = 0; i < height; i++)
|
||||
{
|
||||
for (j = 0; j < width; j++)
|
||||
{
|
||||
if ((0 == *mask) || (i == 0) || (i == (height - 1)) ||
|
||||
(j == 0) || (j == (height - 1)))
|
||||
if ((0 == *mask) ||
|
||||
(i == 0) || (i == (height - 1)) ||
|
||||
(j == 0) || (j == (width - 1)))
|
||||
{
|
||||
/* do nothing at the boundary or outside mask */
|
||||
for (k = 0; k < depth; k++)
|
||||
|
|
|
|||
Loading…
Reference in a new issue