diff options
author | Nick White <git@njw.name> | 2020-07-23 23:09:43 +0100 |
---|---|---|
committer | Nick White <git@njw.name> | 2020-07-23 23:09:43 +0100 |
commit | 1ef9df29fb2d5bb6585e0d0ed99e13a900289e7b (patch) | |
tree | 124ddc2d71e3090fa131468cdf22af076a177063 /test_helpers.go | |
parent | 6a36400351bea5052431bb1feace358fa67a5cf9 (diff) |
Update to v0.2.1 of integralimg, and improve various things
- Improve integral sauvola by rounding threshold correctly
- The Sauvola functions can now process any image.Image, not
just an image.Gray
- Add ImageWindower interface and use it to generalise
wipesides.go
- Rely on Bounds() for image bounds rather than implementation-
specific stuff in integralimg
Note that a couple of the wipesides tests are now failing. It's
possible that this is due to fixed or introduced bugs (let's hope
the former) changing sensible thresholds. Will need to look into
this and sort it.
Diffstat (limited to 'test_helpers.go')
-rw-r--r-- | test_helpers.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/test_helpers.go b/test_helpers.go index 97a43dd..d36ef67 100644 --- a/test_helpers.go +++ b/test_helpers.go @@ -30,7 +30,7 @@ func decode(s string) (*image.Gray, error) { return gray, nil } -func imgsequal(img1 *image.Gray, img2 *image.Gray) bool { +func imgsequal(img1, img2 image.Image) bool { b := img1.Bounds() if !b.Eq(img2.Bounds()) { return false |