Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrUnsupportedFormat = errors.New("imaging: unsupported image format")
)
Functions ¶
Types ¶
type Ditherer ¶
A Ditherer convert a grayscale image with intensities going from 0 (black) to 255 (white) into a black and white image.
type FloydSteinbergDitherer ¶
type FloydSteinbergDitherer struct{}
type GridDitherer ¶
type GridDitherer struct {
// contains filtered or unexported fields
}
GridDitherer implements Bosch and Herman's grid-based method.
func NewGridDitherer ¶
func NewGridDitherer(cellSize int, a, b float64, rand *rand.Rand) GridDitherer
type ImageConverter ¶
type ImageConverter struct {
}
func NewImageConverter ¶
func NewImageConverter() *ImageConverter
func (*ImageConverter) ConvertToGray ¶
func (ic *ImageConverter) ConvertToGray(m image.Image) *image.Gray
type ImageWorker ¶
type ImageWorker struct {
}
func (*ImageWorker) GetImageDemensions ¶
func (w *ImageWorker) GetImageDemensions(image image.Image) (int, int)
returns the image width and height
type ThresholdDitherer ¶
type ThresholdDitherer struct {
// contains filtered or unexported fields
}
ThresholdDitherer converts each pixel in a grayscale image to black or white depending on the intensity of the pixel.
func NewThresholdDitherer ¶
func NewThresholdDitherer(th uint8) ThresholdDitherer
Source Files
¶
Click to show internal directories.
Click to hide internal directories.