Main Content

numberOfTiles

Total number of tiles in image

Description

numTiles = numberOfTiles(t) returns the total number of tiles in the image specified in the Tiff object t.

example

Examples

collapse all

Create a Tiff object for the file example.tif.

t = Tiff('example.tif','r');

Check if the image has a tiled organization, and then get the number of tiles in the image.

if isTiled(t) % If the image has tiled layout
    nTiles = numberOfTiles(t)
end
nTiles = 
110

Close the Tiff object.

close(t);

Input Arguments

collapse all

Tiff object representing a TIFF file. Use the Tiff function to create the object.

Algorithms

collapse all

References

This function corresponds to the TIFFNumberOfTiles function in the LibTIFF C API. To use this function, you must be familiar with the TIFF specification and technical notes. View this documentation at LibTIFF - TIFF Library and Utilities.

Version History

Introduced in R2009b