table of contents
- Tumbleweed 4.7.1-1.1
- Leap-16.0
TIFFREADRGBASTRIP(3tiff) | LibTIFF | TIFFREADRGBASTRIP(3tiff) |
NAME¶
TIFFReadRGBAStrip - read and decode an image strip into a fixed-format raster
SYNOPSIS¶
#include <tiffio.h>
DESCRIPTION¶
TIFFReadRGBAStrip() reads a single strip of a strip-based image into memory, storing the result in the user supplied RGBA raster. The raster is assumed to be an array of ImageWidth × RowsPerStrip 32-bit entries, where ImageWidth is the width of the image (TIFFTAG_IMAGEWIDTH) and RowsPerStrip is the maximum lines in a strip (TIFFTAG_ROWSPERSTRIP).
TIFFReadRGBAStripExt() provides the parameter stop_on_error. Its behaviour is described at TIFFReadRGBAImage.
The row value should be the row of the first row in the strip (strip × RowsPerStrip, zero based).
Note that the raster is assume to be organized such that the pixel at location (x, y) is raster [ y × width + x ]; with the raster origin in the lower-left hand corner of the strip. That is bottom to top organization. When reading a partial last strip in the file the last line of the image will begin at the beginning of the buffer.
Raster pixels are 8-bit packed red, green, blue, alpha samples. The macros TIFFGetR, TIFFGetG, TIFFGetB, and TIFFGetA should be used to access individual samples. Images without Associated Alpha matting information have a constant Alpha of 1.0 (255).
See the TIFFRGBAImage page for more details on how various image types are converted to RGBA values.
NOTES¶
TIFFReadRGBAStrip() is just a wrapper around the more general TIFFRGBAImage facilities. It's main advantage over the similar TIFFReadRGBAImage() function is that for large images a single buffer capable of holding the whole image doesn't need to be allocated, only enough for one strip. The TIFFReadRGBATile() function does a similar operation for tiled images.
For general notes see TIFFRGBImage notes.
RETURN VALUES¶
1 is returned if the image was successfully read and converted. Otherwise, 0 is returned if an error was encountered.
DIAGNOSTICS¶
All error messages are directed to the TIFFErrorExtR() routine.
"Sorry, can not handle %d-bit pictures":
"Sorry, can not handle %d-channel images":
Missing needed "PhotometricInterpretation" tag:
No "PhotometricInterpretation" tag, assuming RGB:
No "PhotometricInterpretation" tag, assuming min-is-black\fP:
"No space for photometric conversion table":
Missing required "Colormap" tag:
"No space for tile buffer":
"No space for strip buffer":
"Can not handle format":
"No space for B&W mapping table":
"No space for Palette mapping table":
SEE ALSO¶
TIFFOpen (3tiff), TIFFRGBAImage (3tiff), TIFFReadRGBAImage (3tiff), TIFFReadRGBATile (3tiff), libtiff (3tiff)
AUTHOR¶
LibTIFF contributors
COPYRIGHT¶
1988-2025, LibTIFF contributors
September 18, 2025 | 4.7 |