UNPKG

image-in-browser

Version:

Package for encoding / decoding images, transforming images, applying filters, drawing primitives on images on the client side (no need for server Node.js)

87 lines (86 loc) 2.71 kB
/** @format */ /** * Interface representing the initialization options for IcoInfoImage. */ export interface IcoInfoImageInitOptions { /** Width of the image */ width: number; /** Height of the image */ height: number; /** Color palette of the image */ colorPalette: number; /** Size of the image in bytes */ bytesSize: number; /** Offset of the image in bytes */ bytesOffset: number; /** Number of color planes */ colorPlanes: number; /** Bits per pixel */ bitsPerPixel: number; } /** * Class representing an ICO image information. */ export declare class IcoInfoImage { /** Width of the image */ private readonly _width; /** Height of the image */ private readonly _height; /** Color palette of the image */ private readonly _colorPalette; /** Size of the image in bytes */ private readonly _bytesSize; /** Offset of the image in bytes */ private readonly _bytesOffset; /** Number of color planes */ private readonly _colorPlanes; /** Bits per pixel */ private readonly _bitsPerPixel; /** * Gets the width of the image. * @returns {number} The width of the image. */ get width(): number; /** * Gets the height of the image. * @returns {number} The height of the image. */ get height(): number; /** * Gets the color palette of the image. * @returns {number} The color palette of the image. */ get colorPalette(): number; /** * Gets the size of the image in bytes. * @returns {number} The size of the image in bytes. */ get bytesSize(): number; /** * Gets the offset of the image in bytes. * @returns {number} The offset of the image in bytes. */ get bytesOffset(): number; /** * Gets the number of color planes. * @returns {number} The number of color planes. */ get colorPlanes(): number; /** * Gets the bits per pixel. * @returns {number} The bits per pixel. */ get bitsPerPixel(): number; /** * Initializes a new instance of the IcoInfoImage class. * @param {IcoInfoImageInitOptions} opt - The initialization options. * @param {number} opt.width - Width of the image. * @param {number} opt.height - Height of the image. * @param {number} opt.colorPalette - Color palette of the image. * @param {number} opt.bytesSize - Size of the image in bytes. * @param {number} opt.bytesOffset - Offset of the image in bytes. * @param {number} opt.colorPlanes - Number of color planes. * @param {number} opt.bitsPerPixel - Bits per pixel. */ constructor(opt: IcoInfoImageInitOptions); }