aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas White <taw@physics.org>2010-01-22 10:36:06 +0100
committerThomas White <taw@physics.org>2010-01-22 10:36:06 +0100
commit59e333ee9e40ae0be0af08fe0eb739f1babf5771 (patch)
treed485476aac8aa042a5da6ea7237e217a051ce17e
parent5a4c6fc6136e66c8a6c248251ba5b5f25c541701 (diff)
Fix muppetry
-rw-r--r--src/filters.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/filters.c b/src/filters.c
index adb291ba..dfbe353f 100644
--- a/src/filters.c
+++ b/src/filters.c
@@ -90,9 +90,10 @@ static void noise_filter(struct image *image)
int dx, dy;
int val = image->data[x+image->width*y];
- if ( (x==1) || (x==image->width-1)
- || (y==1) || (y==image->height-1) ) {
+ if ( (x==0) || (x==image->width-1)
+ || (y==0) || (y==image->height-1) ) {
if ( val < 0 ) val = 0;
+ continue;
}
for ( dx=-1; dx<=+1; dx++ ) {