Documentation ¶
Index ¶
- func NewErrorTrap() *errorTrap
- func ParallelDistributedReadWrite(src draw.Image, c int, d ReadWriteDelegate)
- func ParallelDistributedReadWriteE(src draw.Image, c int, d ReadWriteErrorableDelegate) error
- func ParallelIndices(w, h int, d IndicesDelegate)
- func ParallelMatrixReadWrite[T any](m [][]T, d func(x, y int, value T) T)
- func ParallelMatrixReadWriteE[T any](m [][]T, d func(x, y int, value T) (T, error)) error
- func ParallelNrgbaRead(src *image.NRGBA, d NrgbaReadDelegate)
- func ParallelNrgbaReadE(src *image.NRGBA, d NrgbaReadErrorableDelegate) error
- func ParallelNrgbaReadWrite(src *image.NRGBA, d NrgbaReadWriteDelegate)
- func ParallelNrgbaReadWriteE(src *image.NRGBA, d NrgbaReadWriteErrorableDelegate) error
- func ParallelNrgbaReadWriteNew(src *image.NRGBA, d NrgbaReadWriteDelegate) *image.NRGBA
- func ParallelNrgbaReadWriteNewE(src *image.NRGBA, d NrgbaReadWriteErrorableDelegate) (*image.NRGBA, error)
- func ParallelRead(src image.Image, d ReadDelegate)
- func ParallelReadE(src image.Image, d ReadErrorableDelegate) error
- func ParallelReadWrite(src draw.Image, d ReadWriteDelegate)
- func ParallelReadWriteE(src draw.Image, d ReadWriteErrorableDelegate) error
- func ParallelReadWriteNew(src image.Image, d ReadWriteDelegate) draw.Image
- func ParallelReadWriteNewE(src image.Image, d ReadWriteErrorableDelegate) (draw.Image, error)
- func ParallelRgbaRead(src *image.RGBA, d RgbaReadDelegate)
- func ParallelRgbaReadE(src *image.RGBA, d RgbaReadErrorableDelegate) error
- func ParallelRgbaReadWrite(src *image.RGBA, d RgbaReadWriteDelegate)
- func ParallelRgbaReadWriteE(src *image.RGBA, d RgbaReadWriteErrorableDelegate) error
- func ParallelRgbaReadWriteNew(src *image.RGBA, d RgbaReadWriteDelegate) *image.RGBA
- func ParallelRgbaReadWriteNewE(src *image.RGBA, d RgbaReadWriteErrorableDelegate) (*image.RGBA, error)
- type IndicesDelegate
- type NrgbaReadDelegate
- type NrgbaReadErrorableDelegate
- type NrgbaReadWriteDelegate
- type NrgbaReadWriteErrorableDelegate
- type ReadDelegate
- type ReadErrorableDelegate
- type ReadWriteDelegate
- type ReadWriteErrorableDelegate
- type RgbaReadDelegate
- type RgbaReadErrorableDelegate
- type RgbaReadWriteDelegate
- type RgbaReadWriteErrorableDelegate
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewErrorTrap ¶ added in v0.2.0
func NewErrorTrap() *errorTrap
func ParallelDistributedReadWrite ¶ added in v0.2.0
func ParallelDistributedReadWrite(src draw.Image, c int, d ReadWriteDelegate)
Perform a parallel iteration of the pixels of the provided image. For each pixel, execute the delegate function allowing you to read the color and coordinates, the delegate return color will be set at the given coordinates. This changes will be applied to the passed image instance. The integer parameter is the number of clustes into which the image will be devided. Each cluster is then iterated in a separate goroutine.
func ParallelDistributedReadWriteE ¶ added in v0.2.0
func ParallelDistributedReadWriteE(src draw.Image, c int, d ReadWriteErrorableDelegate) error
Perform a parallel iteration of the pixels of the provided image. For each pixel, execute the delegate function allowing you to read the color and coordinates, the delegate return color will be set at the given coordinates. This changes will be applied to the passed image instance. The integer parameter is the number of clustes into which the image will be devided. Each cluster is then iterated in a separate goroutine. The iteration will break after the first error occurs and the error will be returned.
func ParallelIndices ¶ added in v0.2.0
func ParallelIndices(w, h int, d IndicesDelegate)
Perform a parallel iteration of the indexes according to the width and height provided via the parameters. Execute the delegate for each indexes combination. Each row is iterated in a separate goroutine.
func ParallelMatrixReadWrite ¶ added in v0.1.0
Perform a parallel iteration of the values of the provided matrix represented as a two-dimentional generic slice. For each entry, execute the delegate function allowing you to read the values and coordinates, the delegate return value will be set at the given coordinates. This changes will be applied to the passed two-dimentional slice instance. Each column is iterated in a separate goroutine.
func ParallelMatrixReadWriteE ¶ added in v0.1.0
Perform a parallel iteration of the values of the provided matrix represented as a two-dimentional generic slice. For each entry, execute the delegate function allowing you to read the values and coordinates, the delegate return value will be set at the given coordinates. This changes will be applied to the passed two-dimentional slice instance. Each column is iterated in a separate goroutine. The iteration will break after the first error occurs and the error will be returned.
func ParallelNrgbaRead ¶ added in v0.2.0
func ParallelNrgbaRead(src *image.NRGBA, d NrgbaReadDelegate)
Perform a parallel iteration of the pixels of the provided NRGBA image. For each pixel, execute the delegate function allowing you to read the color (R, G, B and A as uint8) and coordinates. Each row is iterated in a separate goroutine.
func ParallelNrgbaReadE ¶ added in v0.2.0
func ParallelNrgbaReadE(src *image.NRGBA, d NrgbaReadErrorableDelegate) error
Perform a parallel iteration of the pixels of the provided NRGBA image. For each pixel, execute the delegate function allowing you to read the color (R, G, B and A as uint8) and coordinates. Each row is iterated in a separate goroutine. The iteration will break after the first error occurs and the error will be returned.
func ParallelNrgbaReadWrite ¶ added in v0.2.0
func ParallelNrgbaReadWrite(src *image.NRGBA, d NrgbaReadWriteDelegate)
Perform a parallel iteration of the pixels of the provided NRGBA image. For each pixel, execute the delegate function allowing you to read the color (R, G, B and A as uint8) and coordinates, the delegate return color will be set at the given coordinates. This changes will be applied to the passed image instance. Consider using ParallelReadWriteNew if you want to avoid changes to the original image at the expense of additional allocations. Each row is iterated in a separate goroutine.
func ParallelNrgbaReadWriteE ¶ added in v0.2.0
func ParallelNrgbaReadWriteE(src *image.NRGBA, d NrgbaReadWriteErrorableDelegate) error
Perform a parallel iteration of the pixels of the provided NRGBA image. For each pixel, execute the delegate function allowing you to read the color (R, G, B and A as uint8) and coordinates, the delegate return color will be set at the given coordinates. This changes will be applied to the passed image instance. Consider using ParallelReadWriteNewE if you want to avoid changes to the original image at the expense of additional allocations. Each row is iterated in a separate goroutine. The iteration will break after the first error occurs and the error will be returned.
func ParallelNrgbaReadWriteNew ¶ added in v0.2.0
func ParallelNrgbaReadWriteNew(src *image.NRGBA, d NrgbaReadWriteDelegate) *image.NRGBA
Perform a parallel iteration of the pixels of the provided NRGBA image. For each pixel, execute the delegate function allowing you to read the color (R, G, B and A as uint8) and coordinates, the delegate return color will be set at the given coordinates. This changes will be applied to a new image instance which internaly uses the NRGBA color space and is returned by the function. Each row is iterated in a separate goroutine.
func ParallelNrgbaReadWriteNewE ¶ added in v0.2.0
func ParallelNrgbaReadWriteNewE(src *image.NRGBA, d NrgbaReadWriteErrorableDelegate) (*image.NRGBA, error)
Perform a parallel iteration of the pixels of the provided NRGBA image. For each pixel, execute the delegate function allowing you to read the color (R, G, B and A as uint8) and coordinates, the delegate return color will be set at the given coordinates. This changes will be applied to a new image instance which internaly uses the NRGBA color space and is returned by the function. Each row is iterated in a separate goroutine. The iteration will break after the first error occurs and the error will be returned.
func ParallelRead ¶ added in v0.2.0
func ParallelRead(src image.Image, d ReadDelegate)
Perform a parallel iteration of the pixels of the provided image. For each pixel, execute the delegate function allowing you to read the color and coordinates. Each row is iterated in a separate goroutine.
func ParallelReadE ¶ added in v0.2.0
func ParallelReadE(src image.Image, d ReadErrorableDelegate) error
Perform a parallel iteration of the pixels of the provided image. For each pixel, execute the delegate function allowing you to read the color and coordinates. Each row is iterated in a separate goroutine. The iteration will break after the first error occurs and the error will be returned.
func ParallelReadWrite ¶ added in v0.2.0
func ParallelReadWrite(src draw.Image, d ReadWriteDelegate)
Perform a parallel iteration of the pixels of the provided image. For each pixel, execute the delegate function allowing you to read the color and coordinates, the delegate return color will be set at the given coordinates. This changes will be applied to the passed image instance. Consider using ParallelReadWriteNew if you want to avoid changes to the original image at the expense of additional allocations. Each row is iterated in a separate goroutine.
func ParallelReadWriteE ¶ added in v0.2.0
func ParallelReadWriteE(src draw.Image, d ReadWriteErrorableDelegate) error
Perform a parallel iteration of the pixels of the provided image. For each pixel, execute the delegate function allowing you to read the color and coordinates, the delegate return color will be set at the given coordinates. This changes will be applied to the passed image instance. Consider using ParallelReadWriteNewE if you want to avoid changes to the original image at the expense of additional allocations. Each row is iterated in a separate goroutine. The iteration will break after the first error occurs and the error will be returned.
func ParallelReadWriteNew ¶ added in v0.2.0
func ParallelReadWriteNew(src image.Image, d ReadWriteDelegate) draw.Image
Perform a parallel iteration of the pixels of the provided image. For each pixel, execute the delegate function allowing you to read the color and coordinates, the delegate return color will be set at the given coordinates. This changes will be applied to a new image instance which internaly uses the NRGBA color space and is returned by the function. Each row is iterated in a separate goroutine.
func ParallelReadWriteNewE ¶ added in v0.2.0
Perform a parallel iteration of the pixels of the provided image. For each pixel, execute the delegate function allowing you to read the color and coordinates, the delegate return color will be set at the given coordinates. This changes will be applied to a new image instance which internaly uses the NRGBA color space and is returned by the function. Each row is iterated in a separate goroutine. The iteration will break after the first error occurs and the error will be returned.
func ParallelRgbaRead ¶ added in v0.2.0
func ParallelRgbaRead(src *image.RGBA, d RgbaReadDelegate)
Perform a parallel iteration of the pixels of the provided RGBA image. For each pixel, execute the delegate function allowing you to read the color (R, G, B and A as uint8) and coordinates. Each row is iterated in a separate goroutine.
func ParallelRgbaReadE ¶ added in v0.2.0
func ParallelRgbaReadE(src *image.RGBA, d RgbaReadErrorableDelegate) error
Perform a parallel iteration of the pixels of the provided RGBA image. For each pixel, execute the delegate function allowing you to read the color (R, G, B and A as uint8) and coordinates. Each row is iterated in a separate goroutine. The iteration will break after the first error occurs and the error will be returned.
func ParallelRgbaReadWrite ¶ added in v0.2.0
func ParallelRgbaReadWrite(src *image.RGBA, d RgbaReadWriteDelegate)
Perform a parallel iteration of the pixels of the provided RGBA image. For each pixel, execute the delegate function allowing you to read the color (R, G, B and A as uint8) and coordinates, the delegate return color will be set at the given coordinates. This changes will be applied to the passed image instance. Consider using ParallelReadWriteNew if you want to avoid changes to the original image at the expense of additional allocations. Each row is iterated in a separate goroutine.
func ParallelRgbaReadWriteE ¶ added in v0.2.0
func ParallelRgbaReadWriteE(src *image.RGBA, d RgbaReadWriteErrorableDelegate) error
Perform a parallel iteration of the pixels of the provided RGBA image. For each pixel, execute the delegate function allowing you to read the color (R, G, B and A as uint8) and coordinates, the delegate return color will be set at the given coordinates. This changes will be applied to the passed image instance. Consider using ParallelReadWriteNewE if you want to avoid changes to the original image at the expense of additional allocations. Each row is iterated in a separate goroutine. The iteration will break after the first error occurs and the error will be returned.
func ParallelRgbaReadWriteNew ¶ added in v0.2.0
func ParallelRgbaReadWriteNew(src *image.RGBA, d RgbaReadWriteDelegate) *image.RGBA
Perform a parallel iteration of the pixels of the provided RGBA image. For each pixel, execute the delegate function allowing you to read the color (R, G, B and A as uint8) and coordinates, the delegate return color will be set at the given coordinates. This changes will be applied to a new image instance which internaly uses the NRGBA color space and is returned by the function. Each row is iterated in a separate goroutine.
func ParallelRgbaReadWriteNewE ¶ added in v0.2.0
func ParallelRgbaReadWriteNewE(src *image.RGBA, d RgbaReadWriteErrorableDelegate) (*image.RGBA, error)
Perform a parallel iteration of the pixels of the provided RGBA image. For each pixel, execute the delegate function allowing you to read the color (R, G, B and A as uint8) and coordinates, the delegate return color will be set at the given coordinates. This changes will be applied to a new image instance which internaly uses the NRGBA color space and is returned by the function. Each row is iterated in a separate goroutine. The iteration will break after the first error occurs and the error will be returned.
Types ¶
type IndicesDelegate ¶ added in v0.2.0
type IndicesDelegate = func(x, y int)