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)
62 lines (61 loc) • 2.25 kB
TypeScript
/** @format */
import { Color } from '../../color/color.js';
import { DecodeInfo } from '../decode-info.js';
import { TiffImage } from './tiff-image.js';
/**
* Interface for initializing TiffInfo options.
*/
export interface TiffInfoInitOptions {
/** Indicates if the TIFF file is big-endian. */
bigEndian: boolean;
/** The signature of the TIFF file. */
signature: number;
/** The offset to the Image File Directory (IFD). */
ifdOffset: number;
/** Array of TiffImage objects. */
images: TiffImage[];
}
/**
* Class representing TIFF information.
*/
export declare class TiffInfo implements DecodeInfo {
/** Indicates if the TIFF file is big-endian. */
private _bigEndian;
/** Gets the big-endian status. */
get bigEndian(): boolean;
/** The signature of the TIFF file. */
private _signature;
/** Gets the signature of the TIFF file. */
get signature(): number;
/** The offset to the Image File Directory (IFD). */
private _ifdOffset;
/** Gets the offset to the Image File Directory (IFD). */
get ifdOffset(): number;
/** Array of TiffImage objects. */
private _images;
/** Gets the array of TiffImage objects. */
get images(): TiffImage[];
/** The width of the TIFF image. */
private _width;
/** Gets the width of the TIFF image. */
get width(): number;
/** The height of the TIFF image. */
private _height;
/** Gets the height of the TIFF image. */
get height(): number;
/** The background color of the TIFF image. */
private _backgroundColor;
/** Gets the background color of the TIFF image. */
get backgroundColor(): Color | undefined;
/** Gets the number of frames in the TIFF image. */
get numFrames(): number;
/**
* Constructs a new TiffInfo instance.
* @param {TiffInfoInitOptions} opt - The initialization options.
* @param {boolean} opt.bigEndian - Indicates if the TIFF file is big-endian.
* @param {string} opt.signature - The signature of the TIFF file.
* @param {number} opt.ifdOffset - The offset to the Image File Directory (IFD).
* @param {TiffImage[]} opt.images - Array of TiffImage objects.
*/
constructor(opt: TiffInfoInitOptions);
}