Documentation ¶
Index ¶
- type Drawer
- func (d *Drawer) Bounds() image.Rectangle
- func (d *Drawer) ColorModel() color.Model
- func (d *Drawer) Draw(dstRect image.Rectangle, src image.Image, srcPts image.Point) error
- func (d *Drawer) Halt() error
- func (d *Drawer) ServeHTTP(w http.ResponseWriter, r *http.Request)
- func (d *Drawer) String() string
- type ImageFormat
- type Options
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Drawer ¶
type Drawer struct {
// contains filtered or unexported fields
}
func (*Drawer) ColorModel ¶
ColorModel implements image.Image.
func (*Drawer) Halt ¶
Halt implements conn.Resource and terminates all running client requests asynchronously.
func (*Drawer) ServeHTTP ¶
func (d *Drawer) ServeHTTP(w http.ResponseWriter, r *http.Request)
ServeHTTP handles HTTP GET requests and sends a stream of images representing the display buffer in response. The display options control the default format and clients can explicitly request PNG or JPEG images using the "format" parameter ("?format=png", "?format=jpeg").
type ImageFormat ¶
type ImageFormat int
const ( PNG ImageFormat = iota JPEG DefaultFormat = PNG )
func ImageFormatFromString ¶
func ImageFormatFromString(value string) (ImageFormat, error)
func (ImageFormat) String ¶
func (f ImageFormat) String() string
type Options ¶
type Options struct {
// Width and height of the image buffer.
Width, Height int
// Format specifies the image format to send to clients.
Format ImageFormat
}
Click to show internal directories.
Click to hide internal directories.