Documentation
¶
Overview ¶
Package ico describes Windows ICO file format.
Index ¶
Constants ¶
View Source
const (
BI_RGB = 0
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BITMAPINFOHEADER ¶
type BITMAPINFOHEADER struct {
Size uint32
Width int32
Height int32 // NOTE: "represents the combined height of the XOR and AND masks. Remember to divide this number by two before using it to perform calculations for either of the XOR or AND masks."
Planes uint16 // [BMP/DIB]: "is always 1"
BitCount uint16
Compression uint32 // for ico = 0
SizeImage uint32
XPelsPerMeter int32 // for ico = 0
YPelsPerMeter int32 // for ico = 0
ClrUsed uint32 // for ico = 0
ClrImportant uint32 // for ico = 0
}
type ICONDIRENTRY ¶
type ICONDIRENTRY struct {
IconDirEntryCommon
ImageOffset uint32 // Where in the file is this image? [from beginning of file]
}
func DecodeHeaders ¶
func DecodeHeaders(r io.Reader) ([]ICONDIRENTRY, error)
type IconDirEntryCommon ¶
type IconDirEntryCommon struct {
Width byte // Width, in pixels, of the image
Height byte // Height, in pixels, of the image
ColorCount byte // Number of colors in image (0 if >=8bpp)
Reserved byte // Reserved (must be 0)
Planes uint16 // Color Planes
BitCount uint16 // Bits per pixel
BytesInRes uint32 // How many bytes in this resource?
}
Click to show internal directories.
Click to hide internal directories.