Documentation ¶
Overview ¶
Package braille composites bitmaps as braille.
Index ¶
Constants ¶
This section is empty.
Variables ¶
var Margin = image.Point{1, 2}
Margin is the typical margin of skipped bits necessary to make Braille line art look straight. Pass as the margin argument to DrawBitmap.
Functions ¶
func BitmapAt ¶
BitmapAt returns the braille glyph that coresponds to the 2x4 grid at the given point in a bitmap.
func Bounds ¶
Bounds takes a rectangle describing cells on a display to the cells of a braille bitmap covering the cells of the display. Accepts a margin, bits to skip over between cells. Passing braille.Margin drops some pixels to achieve the possibility of rendering straighter lines. Passing image.ZP covers every bit of the bitmap, though all readable fonts will draw a margin between braille characters.
func DrawBitmap ¶
func DrawBitmap(dst *display.Display, r image.Rectangle, src *bitmap.Bitmap, sp image.Point, m image.Point, fg color.Color)
DrawBitmap draws a braille bitmap onto a display, setting the foreground color for any cells with a prsent braille character. Skips over pixels in the given margin between cells. Passing braille.Margin drops pixels between cells to preserve the appearance of straight lines. Passing image.ZP preserves the entire image, but will render discontinuities in the margin between cells.
Types ¶
This section is empty.