TIFFDATAWIDTH(3tiff) LibTIFF TIFFDATAWIDTH(3tiff)

NAME


TIFFDataWidth - get the size of TIFF data types

SYNOPSIS



#include <tiffio.h>

int TIFFDataWidth(TIFFDataType type)

DESCRIPTION


TIFFDataWidth() returns the size of type within TIFF file in bytes.
Currently following data types are supported:

+o TIFF_BYTE

+o TIFF_ASCII

+o TIFF_SBYTE

+o TIFF_UNDEFINED

+o TIFF_SHORT

+o TIFF_SSHORT

+o TIFF_LONG

+o TIFF_SLONG

+o TIFF_FLOAT

+o TIFF_IFD

+o TIFF_RATIONAL

+o TIFF_SRATIONAL

+o TIFF_DOUBLE

+o TIFF_LONG8

+o TIFF_SLONG8

+o TIFF_IFD8

RETURN VALUES


TIFFDataWidth() returns a number of bytes occupied by the item of
given type within the TIFF file. 0 returned when unknown data type
supplied.

SEE ALSO


libtiff (3tiff)

AUTHOR


LibTIFF contributors

COPYRIGHT


1988-2025, LibTIFF contributors

4.7 March 7, 2026 TIFFDATAWIDTH(3tiff)