Initial import
git-svn-id: http://moon:8086/svn/software/trunk/libsrc/libtiff@1 b431acfa-c32f-4a4a-93f1-934dc6c82436
This commit is contained in:
Executable
+225
@@ -0,0 +1,225 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
|
||||
<HTML><HEAD><TITLE>Manpage of TIFFWriteScanline</TITLE>
|
||||
</HEAD><BODY BGCOLOR=WHITE><FONT FACE="helvetica, sans, arial">
|
||||
<H1>TIFFWriteScanline</H1>
|
||||
Section: Misc. Reference Manual Pages (3T)<BR>Updated: December 16, 1991<BR><A HREF="#index">Index</A>
|
||||
<BR><A HREF="index.html">Return to Main Contents</A>
|
||||
<HR>
|
||||
|
||||
<A NAME="lbAB"> </A>
|
||||
<H2>NAME</H2>
|
||||
|
||||
TIFFWriteScanline - write a scanline to an open
|
||||
<FONT SIZE="-1">TIFF</FONT>
|
||||
file
|
||||
<A NAME="lbAC"> </A>
|
||||
<H2>SYNOPSIS</H2>
|
||||
|
||||
<B>#include <<A HREF="file:/usr/include/tiffio.h">tiffio.h</A>></B>
|
||||
|
||||
<BR>
|
||||
|
||||
<B>int TIFFWriteScanline(TIFF* tif, tdata_t buf, uint32 row, tsample_t sample)</B>
|
||||
|
||||
<A NAME="lbAD"> </A>
|
||||
<H2>DESCRIPTION</H2>
|
||||
|
||||
Write data to a file at the specified row.
|
||||
The
|
||||
<I>sample</I>
|
||||
|
||||
parameter is used only if data are organized in separate planes (<I>PlanarConfiguration</I>=2).
|
||||
|
||||
The data are assumed to be uncompressed and in the native
|
||||
bit- and byte-order of the host machine.
|
||||
The data written to the file is
|
||||
compressed according to the compression scheme
|
||||
of the current
|
||||
<FONT SIZE="-1">TIFF</FONT>
|
||||
directory (see further below).
|
||||
If the current scanline is past the end of the current subfile, the
|
||||
<I>ImageLength</I>
|
||||
|
||||
field is automatically increased to include the scanline (except
|
||||
for
|
||||
<I>PlanarConfiguration</I>=2,
|
||||
|
||||
where the
|
||||
<I>ImageLength</I>
|
||||
|
||||
cannot be changed once the first data are written).
|
||||
If the
|
||||
<I>ImageLength</I>
|
||||
|
||||
is increased, the
|
||||
<I>StripOffsets</I>
|
||||
|
||||
and
|
||||
<I>StripByteCounts</I>
|
||||
|
||||
fields are similarly enlarged to reflect data written past the
|
||||
previous end of image.
|
||||
<A NAME="lbAE"> </A>
|
||||
<H2>NOTES</H2>
|
||||
|
||||
The library writes encoded data using the native machine byte order.
|
||||
Correctly implemented
|
||||
<FONT SIZE="-1">TIFF</FONT>
|
||||
readers are expected to do any necessary byte-swapping to
|
||||
correctly process image data with BitsPerSample greater than 8.
|
||||
The library attempts to hide bit-ordering differences
|
||||
between the image and the native machine by converting data
|
||||
from the native machine order.
|
||||
<P>
|
||||
|
||||
In C++ the
|
||||
<I>sample</I>
|
||||
|
||||
parameter defaults to 0.
|
||||
<P>
|
||||
|
||||
Once data are written to a file for the current directory,
|
||||
the values of certain tags may not be altered; see
|
||||
<I><A HREF="TIFFSetField.3t.html">TIFFSetField</A></I>(3T)
|
||||
|
||||
for more information.
|
||||
<P>
|
||||
|
||||
It is not possible to write scanlines to a file that
|
||||
uses a tiled organization. The routine
|
||||
<I>TIFFIsTiled</I>
|
||||
|
||||
can be used to determine if the file is organized
|
||||
as tiles or strips.
|
||||
<A NAME="lbAF"> </A>
|
||||
<H2>RETURN VALUES</H2>
|
||||
|
||||
<I>TIFFWriteScanline</I>
|
||||
|
||||
returns -1 if it immediately detects an error
|
||||
and 1 for a successful write.
|
||||
<A NAME="lbAG"> </A>
|
||||
<H2>DIAGNOSTICS</H2>
|
||||
|
||||
All error messages are directed to the
|
||||
<I><A HREF="TIFFError.3t.html">TIFFError</A></I>(3T)
|
||||
|
||||
routine.
|
||||
<P>
|
||||
|
||||
<B>%s: File not open for writing .</B>
|
||||
|
||||
The file was opened for reading, not writing.
|
||||
<P>
|
||||
|
||||
<B>Can not write scanlines to a tiled image</B>.
|
||||
|
||||
An attempt was made to write a scanline to a tiled image.
|
||||
The image is assumed to be organized in tiles because the
|
||||
<I>TileWidth</I>
|
||||
|
||||
and
|
||||
<I>TileLength</I>
|
||||
|
||||
tags have been set with
|
||||
<I><A HREF="TIFFSetField.3t.html">TIFFSetField</A></I>(3T).
|
||||
|
||||
<P>
|
||||
|
||||
<B>Compression algorithm does not support random access</B>.
|
||||
|
||||
Data was written in a non-sequential order to a file that
|
||||
uses a compression algorithm and that has
|
||||
<I>RowsPerStrip</I>
|
||||
|
||||
greater than one.
|
||||
That is, data in the image is to be stored in a compressed form,
|
||||
and with multiple rows packed into a strip.
|
||||
In this case, the library does not support random access to the data.
|
||||
The data should either be written as entire strips,
|
||||
sequentially by rows, or the value of
|
||||
<I>RowsPerStrip</I>
|
||||
|
||||
should be set to one.
|
||||
<P>
|
||||
|
||||
<B>%s: Must set "ImageWidth" before writing data</B>.
|
||||
The image's width has not be set before the first write.
|
||||
See
|
||||
<I><A HREF="TIFFSetField.3t.html">TIFFSetField</A></I>(3T)
|
||||
|
||||
for information on how to do this.
|
||||
<P>
|
||||
|
||||
<B>%s: Must set "PlanarConfiguration" before writing data</B>.
|
||||
The organization of data has not be defined before the first write.
|
||||
See
|
||||
<I><A HREF="TIFFSetField.3t.html">TIFFSetField</A></I>(3T)
|
||||
|
||||
for information on how to do this.
|
||||
<P>
|
||||
|
||||
<B>Can not change "ImageLength" when using separate planes</B>.
|
||||
Separate image planes are being used (<I>PlanarConfiguration</I>=2),
|
||||
|
||||
but the number of rows has not been specified before the first write.
|
||||
The library supports the dynamic growth of an image only when data
|
||||
are organized in a contiguous manner (<I>PlanarConfiguration</I>=1).
|
||||
|
||||
<P>
|
||||
|
||||
<B>%d: Sample out of range, max %d</B>.
|
||||
|
||||
The
|
||||
<I>sample</I>
|
||||
|
||||
parameter was greater than the value of the SamplesPerPixel tag.
|
||||
<P>
|
||||
|
||||
<B>%s: No space for strip arrays .</B>
|
||||
|
||||
There was not enough space for the arrays that hold strip
|
||||
offsets and byte counts.
|
||||
<A NAME="lbAH"> </A>
|
||||
<H2>BUGS</H2>
|
||||
|
||||
Writing subsampled YCbCR data does not work correctly
|
||||
because, for
|
||||
<I>PlanarConfiguration</I>=2
|
||||
|
||||
the size of a scanline is not calculated on a per-sample basis,
|
||||
and for
|
||||
<I>PlanarConfiguration</I>=1
|
||||
|
||||
the library does not pack the block-interleaved samples.
|
||||
<A NAME="lbAI"> </A>
|
||||
<H2>SEE ALSO</H2>
|
||||
|
||||
<I><A HREF="libtiff.3t.html">libtiff</A></I>(3T),
|
||||
|
||||
<I><A HREF="TIFFOpen.3t.html">TIFFOpen</A></I>(3T),
|
||||
|
||||
<I><A HREF="TIFFWriteEncodedStrip.3t.html">TIFFWriteEncodedStrip</A></I>(3T),
|
||||
|
||||
<I><A HREF="TIFFWriteRawStrip.3t.html">TIFFWriteRawStrip</A></I>(3T)
|
||||
|
||||
|
||||
<HR>
|
||||
<A NAME="index"> </A><H2>Index</H2>
|
||||
<DL>
|
||||
<DT><A HREF="#lbAB">NAME</A><DD>
|
||||
<DT><A HREF="#lbAC">SYNOPSIS</A><DD>
|
||||
<DT><A HREF="#lbAD">DESCRIPTION</A><DD>
|
||||
<DT><A HREF="#lbAE">NOTES</A><DD>
|
||||
<DT><A HREF="#lbAF">RETURN VALUES</A><DD>
|
||||
<DT><A HREF="#lbAG">DIAGNOSTICS</A><DD>
|
||||
<DT><A HREF="#lbAH">BUGS</A><DD>
|
||||
<DT><A HREF="#lbAI">SEE ALSO</A><DD>
|
||||
</DL>
|
||||
<HR>
|
||||
This document was created by
|
||||
<A HREF="index.html">man2html</A>,
|
||||
using the manual pages.<BR>
|
||||
Time: 01:31:39 GMT, November 23, 1999
|
||||
</BODY>
|
||||
</HTML>
|
||||
Reference in New Issue
Block a user