| Products & Services | Solutions | Academia | Support | User Community | Company |
| Download Product Updates | | | Get Pricing | | | Trial Software |
| Documentation → MATLAB |
| Contents | Index |
| Learn more about MATLAB |
Read data from specified tile
tileData = tiffobj.readEncodedTile(tileNumber)
[Y,Cb,Cr] = tiffobj.readEncodedTile(tileNumber)
tileData = tiffobj.readEncodedTile(tileNumber) reads data from the tile specified by tileNumber. Tile numbers are one-based numbers.
[Y,Cb,Cr] = tiffobj.readEncodedTile(tileNumber) reads YCbCr component data from the specified tile. The size of the chrominance components Cb and Cr might differ from the size of the luminance component Y, depending on the value of the YCbCrSubSampling tag.
readEncodedTile clips tiles on the last row or right-most column of an image if the tile extends past the ImageLength and ImageLength boundaries.
Open a Tiff object and read a tile of data. Replace myfile.tif with the name of a TIFF file on your MATLAB path.
t = Tiff('myfile.tif', 'r');
%
% Check if image is tiled or stipped.
if t.isTiled()
data = t.readEncodedTile(1);
end
This method corresponds to the TIFFReadEncodedTile function in the LibTIFF C API. To use this method, you must be familiar with LibTIFF version 3.7.1, as well as the TIFF specification and technical notes. View this documentation at LibTIFF - TIFF Library and Utilities.
Tiff.isTiled | Tiff.readEncodedStrip
![]() | readEncodedStrip (Tiff) | real | ![]() |

Includes the most popular MATLAB recorded presentations with Q&A sessions led by MATLAB experts.
| © 1984-2009- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |