Skip to content

Commit

Permalink
chore: remove deprecated image.ZP
Browse files Browse the repository at this point in the history
  • Loading branch information
thoas committed Mar 8, 2024
1 parent b2561b5 commit 2ce9291
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions engine/backend/goimage.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@ import (
"bytes"
"context"
"fmt"
"github.com/thoas/go-funk"
"github.com/thoas/picfit/constants"
"image"
"image/color/palette"
"image/draw"
Expand All @@ -15,6 +13,9 @@ import (
"io"
"math"

"github.com/thoas/go-funk"
"github.com/thoas/picfit/constants"

"github.com/go-spectest/imaging"

imagefile "github.com/thoas/picfit/image"
Expand Down Expand Up @@ -233,7 +234,7 @@ func scale(img image.Image, options *Options, trans transformation) image.Image
func imageToPaletted(img image.Image) *image.Paletted {
b := img.Bounds()
pm := image.NewPaletted(b, palette.Plan9)
draw.FloydSteinberg.Draw(pm, b, img, image.ZP)
draw.FloydSteinberg.Draw(pm, b, img, image.Point{})
return pm
}

Expand Down

0 comments on commit 2ce9291

Please sign in to comment.