|
roentgen |
b75cab |
.\" $Id: TIFFbuffer.3tiff,v 1.2 2005-11-02 11:07:18 dron Exp $
|
|
roentgen |
b75cab |
.\"
|
|
roentgen |
b75cab |
.\" Copyright (c) 1995 Sam Leffler
|
|
roentgen |
b75cab |
.\" Copyright (c) 1995 Silicon Graphics, Inc.
|
|
roentgen |
b75cab |
.\"
|
|
roentgen |
b75cab |
.\" Permission to use, copy, modify, distribute, and sell this software and
|
|
roentgen |
b75cab |
.\" its documentation for any purpose is hereby granted without fee, provided
|
|
roentgen |
b75cab |
.\" that (i) the above copyright notices and this permission notice appear in
|
|
roentgen |
b75cab |
.\" all copies of the software and related documentation, and (ii) the names of
|
|
roentgen |
b75cab |
.\" Sam Leffler and Silicon Graphics may not be used in any advertising or
|
|
roentgen |
b75cab |
.\" publicity relating to the software without the specific, prior written
|
|
roentgen |
b75cab |
.\" permission of Sam Leffler and Silicon Graphics.
|
|
roentgen |
b75cab |
.\"
|
|
roentgen |
b75cab |
.\" THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
|
|
roentgen |
b75cab |
.\" EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
|
|
roentgen |
b75cab |
.\" WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
|
|
roentgen |
b75cab |
.\"
|
|
roentgen |
b75cab |
.\" IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR
|
|
roentgen |
b75cab |
.\" ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND,
|
|
roentgen |
b75cab |
.\" OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
|
|
roentgen |
b75cab |
.\" WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF
|
|
roentgen |
b75cab |
.\" LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE
|
|
roentgen |
b75cab |
.\" OF THIS SOFTWARE.
|
|
roentgen |
b75cab |
.\"
|
|
roentgen |
b75cab |
.if n .po 0
|
|
roentgen |
b75cab |
.TH TIFFBUFFER 3TIFF "November 1, 2005" "libtiff"
|
|
roentgen |
b75cab |
.SH NAME
|
|
roentgen |
b75cab |
TIFFReadBufferSetup, TIFFWriteBufferSetup \- I/O buffering control routines
|
|
roentgen |
b75cab |
.SH SYNOPSIS
|
|
roentgen |
b75cab |
.nf
|
|
roentgen |
b75cab |
.B "#include <tiffio.h>"</tiffio.h>
|
|
roentgen |
b75cab |
.sp
|
|
roentgen |
b75cab |
.BI "int TIFFReadBufferSetup(TIFF *" tif ", tdata_t " buffer ", tsize_t " size ");"
|
|
roentgen |
b75cab |
.BI "int TIFFWriteBufferSetup(TIFF *" tif ", tdata_t " buffer ", tsize_t " size ");"
|
|
roentgen |
b75cab |
.fi
|
|
roentgen |
b75cab |
.SH DESCRIPTION
|
|
roentgen |
b75cab |
The following routines are provided for client-control of the I/O buffers used
|
|
roentgen |
b75cab |
by the library. Applications need never use these routines; they are provided
|
|
roentgen |
b75cab |
only for ``intelligent clients'' that wish to optimize memory usage and/or
|
|
roentgen |
b75cab |
eliminate potential copy operations that can occur when working with images
|
|
roentgen |
b75cab |
that have data stored without compression.
|
|
roentgen |
b75cab |
.PP
|
|
roentgen |
b75cab |
.I TIFFReadBufferSetup
|
|
roentgen |
b75cab |
sets up the data buffer used to read raw (encoded) data from a file. If the
|
|
roentgen |
b75cab |
specified pointer is
|
|
roentgen |
b75cab |
.SM NULL
|
|
roentgen |
b75cab |
(zero), then a buffer of the appropriate size is allocated. Otherwise the
|
|
roentgen |
b75cab |
caller must guarantee that the buffer is large enough to hold any individual
|
|
roentgen |
b75cab |
strip of raw data.
|
|
roentgen |
b75cab |
.I TIFFReadBufferSetup
|
|
roentgen |
b75cab |
returns a non-zero value if the setup was successful and zero otherwise.
|
|
roentgen |
b75cab |
.PP
|
|
roentgen |
b75cab |
.I TIFFWriteBufferSetup
|
|
roentgen |
b75cab |
sets up the data buffer used to write raw (encoded) data to a file. If the
|
|
roentgen |
b75cab |
specified
|
|
roentgen |
b75cab |
.I size
|
|
roentgen |
b75cab |
is \-1 then the buffer size is selected to hold a complete tile or strip, or
|
|
roentgen |
b75cab |
at least 8 kilobytes, whichever is greater. If the specified
|
|
roentgen |
b75cab |
.I buffer
|
|
roentgen |
b75cab |
is
|
|
roentgen |
b75cab |
.SM NULL
|
|
roentgen |
b75cab |
(zero), then a buffer of the appropriate size is dynamically allocated.
|
|
roentgen |
b75cab |
.I TIFFWriteBufferSetup
|
|
roentgen |
b75cab |
returns a non-zero value if the setup was successful and zero otherwise.
|
|
roentgen |
b75cab |
.SH DIAGNOSTICS
|
|
roentgen |
b75cab |
.BR "%s: No space for data buffer at scanline %ld" .
|
|
roentgen |
b75cab |
.I TIFFReadBufferSetup
|
|
roentgen |
b75cab |
was unable to dynamically allocate space for a data buffer.
|
|
roentgen |
b75cab |
.PP
|
|
roentgen |
b75cab |
.BR "%s: No space for output buffer" .
|
|
roentgen |
b75cab |
.I TIFFWriteBufferSetup
|
|
roentgen |
b75cab |
was unable to dynamically allocate space for a data buffer.
|
|
roentgen |
b75cab |
.SH "SEE ALSO"
|
|
roentgen |
b75cab |
.BR libtiff (3TIFF)
|
|
roentgen |
b75cab |
.PP
|
|
roentgen |
b75cab |
Libtiff library home page:
|
|
roentgen |
b75cab |
.BR http://www.remotesensing.org/libtiff/
|