.\" Man page generated from reStructuredText. . . .nr rst2man-indent-level 0 . .de1 rstReportMargin \\$1 \\n[an-margin] level \\n[rst2man-indent-level] level margin: \\n[rst2man-indent\\n[rst2man-indent-level]] - \\n[rst2man-indent0] \\n[rst2man-indent1] \\n[rst2man-indent2] .. .de1 INDENT .\" .rstReportMargin pre: . RS \\$1 . nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin] . nr rst2man-indent-level +1 .\" .rstReportMargin post: .. .de UNINDENT . RE .\" indent \\n[an-margin] .\" old: \\n[rst2man-indent\\n[rst2man-indent-level]] .nr rst2man-indent-level -1 .\" new: \\n[rst2man-indent\\n[rst2man-indent-level]] .in \\n[rst2man-indent\\n[rst2man-indent-level]]u .. .TH "TIFFWRITEENCODEDTILE" "3tiff" "Jan 27, 2024" "4.5" "LibTIFF" .SH NAME TIFFWriteEncodedTile \- compress and write a tile of data to an open TIFF file .SH SYNOPSIS .INDENT 0.0 .INDENT 3.5 .sp .EX #include .EE .UNINDENT .UNINDENT .INDENT 0.0 .TP .B tsize_t TIFFWriteEncodedTile(TIFF *tif, ttile_t tile, tdata_t buf, tsize_t size) .UNINDENT .SH DESCRIPTION .sp Compress \fIsize\fP bytes of raw data from \fIbuf\fP and \fBappend\fP the result to the end of the specified tile. Note that the value of \fItile\fP is a \(dqraw tile number\(dq. That is, the caller must take into account whether or not the data are organized in separate planes (\fBPlanarConfiguration\fP = 2). \fI\%TIFFComputeTile()\fP automatically does this when converting an (x,y,z,sample) coordinate quadruple to a tile number. .SH NOTES .sp The library writes encoded data using the native machine byte order. Correctly implemented TIFF readers are expected to do any necessary byte\-swapping to correctly process image data with \fBBitsPerSample\fP greater than 8. .SH RETURN VALUES .sp \-1 is returned if an error was encountered. Otherwise, the value of \fIsize\fP is returned. .SH DIAGNOSTICS .sp All error messages are directed to the \fI\%TIFFErrorExtR()\fP routine. .sp \fB%s: File not open for writing\fP: .INDENT 0.0 .INDENT 3.5 The file was opened for reading, not writing. .UNINDENT .UNINDENT .sp \fBCan not write tiles to a stripped image\fP: .INDENT 0.0 .INDENT 3.5 The image is assumed to be organized in strips because neither of the \fBTileWidth\fP or \fBTileLength\fP tags have been set with \fI\%TIFFSetField()\fP\&. .UNINDENT .UNINDENT .sp \fB%s: Must set \(dqImageWidth\(dq before writing data\fP: .INDENT 0.0 .INDENT 3.5 The image\(aqs width has not been set before the first write. See \fI\%TIFFSetField()\fP for information on how to do this. .UNINDENT .UNINDENT .sp \fB%s: Must set \(dqPlanarConfiguration\(dq before writing data\fP: .INDENT 0.0 .INDENT 3.5 The organization of data has not be defined before the first write. See \fI\%TIFFSetField()\fP for information on how to do this. .UNINDENT .UNINDENT .sp \fB%s: No space for tile arrays\(dq\fP: .INDENT 0.0 .INDENT 3.5 There was not enough space for the arrays that hold tile offsets and byte counts. .UNINDENT .UNINDENT .SH SEE ALSO .sp \fI\%TIFFOpen\fP (3tiff), \fI\%TIFFWriteTile\fP (3tiff), \fI\%TIFFWriteRawTile\fP (3tiff), \fI\%libtiff\fP (3tiff) .SH AUTHOR LibTIFF contributors .SH COPYRIGHT 1988-2024, LibTIFF contributors .\" Generated by docutils manpage writer. .