Skip to content

Commit

Permalink
gofmt and docstring formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
justinfx committed Sep 9, 2023
1 parent dd6a254 commit 17dfe96
Show file tree
Hide file tree
Showing 9 changed files with 653 additions and 825 deletions.
1 change: 0 additions & 1 deletion examples/affine/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,6 @@ func example1() {
// Since rotation is done around the origin, we must translate
// the point (300,100) up to the origin, do the rotation, and
// then translate back again
//
func example2() {
imagick.Initialize()
defer imagick.Terminate()
Expand Down
2 changes: 1 addition & 1 deletion imagick/affine_matrix_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ func TestAffineMatrix(t *testing.T) {
t.Errorf("Expected SY=-1, got %v", m.ScaleY())
}

dw.Affine(m)
dw.Affine(m)
mw.DrawImage(dw)

m.ResetToIdentity()
Expand Down
1 change: 1 addition & 0 deletions imagick/fix_32_bit.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
//go:build 386
// +build 386

package imagick
Expand Down
9 changes: 5 additions & 4 deletions imagick/kernel_info.go
Original file line number Diff line number Diff line change
Expand Up @@ -157,10 +157,11 @@ func NewKernelInfoBuiltIn(typ KernelInfoType, kernel string) (*KernelInfo, error
// http://www.imagemagick.org/api/morphology.php#ScaleKernelInfo for details.
//
// Flag should be one of:
// KERNEL_NORMALIZE_NONE
// KERNEL_NORMALIZE_VALUE
// KERNEL_NORMALIZE_CORRELATE
// KERNEL_NORMALIZE_PERCENT
//
// KERNEL_NORMALIZE_NONE
// KERNEL_NORMALIZE_VALUE
// KERNEL_NORMALIZE_CORRELATE
// KERNEL_NORMALIZE_PERCENT
func (ki *KernelInfo) Scale(scale float64, normalizeType KernelNormalizeType) {
C.ScaleKernelInfo(ki.info, C.double(scale), C.GeometryFlags(normalizeType))
runtime.KeepAlive(ki)
Expand Down
2 changes: 1 addition & 1 deletion imagick/kernel_info_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ func TestKernelInfo(t *testing.T) {
kernel string
size int
}{
{"Laplacian:2", 3}, // Laplacian
{"Laplacian:2", 3}, // Laplacian
{"3x3: 0.0, 0.5, 0.0, 0.5, 1.0, 0.5, 0.0, 0.5, 0.0", 3}, // spread
{"0.0 0.5 0.0 0.5 1.0 0.5 0.0 0.5 0.0", 3}, // old
}
Expand Down
1,295 changes: 563 additions & 732 deletions imagick/magick_wand_image.go

Large diffs are not rendered by default.

Loading

0 comments on commit 17dfe96

Please sign in to comment.