ImageKernelConvolution function added
This commit is contained in:
parent
bf03596ee4
commit
19bdd59547
2 changed files with 14 additions and 0 deletions
|
@ -287,6 +287,7 @@ var imageAlphaClear func(image *Image, col uintptr, threshold float32)
|
|||
var imageAlphaMask func(image *Image, alphaMask uintptr)
|
||||
var imageAlphaPremultiply func(image *Image)
|
||||
var imageBlurGaussian func(image *Image, blurSize int32)
|
||||
var imageKernelConvolution func(image *Image, kernel []float32, kernelSize int32)
|
||||
var imageResize func(image *Image, newWidth int32, newHeight int32)
|
||||
var imageResizeNN func(image *Image, newWidth int32, newHeight int32)
|
||||
var imageResizeCanvas func(image *Image, newWidth int32, newHeight int32, offsetX int32, offsetY int32, fill uintptr)
|
||||
|
@ -792,6 +793,7 @@ func init() {
|
|||
purego.RegisterLibFunc(&imageAlphaMask, raylibDll, "ImageAlphaMask")
|
||||
purego.RegisterLibFunc(&imageAlphaPremultiply, raylibDll, "ImageAlphaPremultiply")
|
||||
purego.RegisterLibFunc(&imageBlurGaussian, raylibDll, "ImageBlurGaussian")
|
||||
purego.RegisterLibFunc(&imageKernelConvolution, raylibDll, "ImageKernelConvolution")
|
||||
purego.RegisterLibFunc(&imageResize, raylibDll, "ImageResize")
|
||||
purego.RegisterLibFunc(&imageResizeNN, raylibDll, "ImageResizeNN")
|
||||
purego.RegisterLibFunc(&imageResizeCanvas, raylibDll, "ImageResizeCanvas")
|
||||
|
@ -2535,6 +2537,11 @@ func ImageBlurGaussian(image *Image, blurSize int32) {
|
|||
imageBlurGaussian(image, blurSize)
|
||||
}
|
||||
|
||||
// ImageKernelConvolution - Apply custom square convolution kernel to image
|
||||
func ImageKernelConvolution(image *Image, kernel []float32) {
|
||||
imageKernelConvolution(image, kernel, int32(len(kernel)))
|
||||
}
|
||||
|
||||
// ImageResize - Resize image (Bicubic scaling algorithm)
|
||||
func ImageResize(image *Image, newWidth int32, newHeight int32) {
|
||||
imageResize(image, newWidth, newHeight)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue