wbmp

package module
v0.0.0-...-e8ecec9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 7, 2020 License: MIT Imports: 6 Imported by: 0

README

Wireless Bitmap

GoDoc Go Report Card

Package wbmp implements decoding for Wireless Bitmap images.

A Wireless Bitmap is a monochrome image that was used in WAP and MMS where each bit represents one pixel. Bytes are read from left to right where the left most pixel is the high bit of the first byte. Rows are always represent by whole bytes. If the image width is not divisable by 8, the following row starts at the next byte. Unused bits must be set to 0.

Documentation

Overview

Package wbmp implements decoding for Wireless Bitmap images.

A Wireless Bitmap is a monochrome image that was used in WAP and MMS where each bit represents one pixel. Bytes are read from left to right where the left most pixel is the high bit of the first byte. Rows are always represent by whole bytes. If the image width is not divisable by 8, the following row starts at the next byte. Unused bits must be set to 0.

http://www.wapforum.org/what/technical/SPEC-WAESpec-19990524.pdf

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Decode

func Decode(r io.Reader) (image.Image, error)

Decode decodes the image.

func DecodeConfig

func DecodeConfig(r io.Reader) (image.Config, error)

DecodeConfig decodes the color model and dimensions of an image.

Types

type WBMP

type WBMP struct {
	// contains filtered or unexported fields
}

WBMP represents a Wireless Bitmap and implements an image.Image interface.

func (WBMP) At

func (wbmp WBMP) At(x, y int) color.Color

At returns the color of the pixel at (x, y).

func (WBMP) Bounds

func (wbmp WBMP) Bounds() image.Rectangle

Bounds returns the bounds of the image.

func (WBMP) ColorModel

func (wbmp WBMP) ColorModel() color.Model

ColorModel returns the Image's color model.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL