]> git.saurik.com Git - wxWidgets.git/blame - src/tiff/html/man/TIFFReadRGBATile.3tiff.html
Disable symbols visibility support for the Clang compiler.
[wxWidgets.git] / src / tiff / html / man / TIFFReadRGBATile.3tiff.html
CommitLineData
8414a40c
VZ
1<!-- Creator : groff version 1.18.1 -->
2<!-- CreationDate: Mon Mar 13 18:03:10 2006 -->
3<html>
4<head>
5<meta name="generator" content="groff -Thtml, see www.gnu.org">
6<meta name="Content-Style" content="text/css">
7<title>TIFFReadRGBATile</title>
8</head>
9<body>
10
11<h1 align=center>TIFFReadRGBATile</h1>
12<a href="#NAME">NAME</a><br>
13<a href="#SYNOPSIS">SYNOPSIS</a><br>
14<a href="#DESCRIPTION">DESCRIPTION</a><br>
15<a href="#NOTES">NOTES</a><br>
16<a href="#RETURN VALUES">RETURN VALUES</a><br>
17<a href="#DIAGNOSTICS">DIAGNOSTICS</a><br>
18<a href="#SEE ALSO">SEE ALSO</a><br>
19
20<hr>
21<a name="NAME"></a>
22<h2>NAME</h2>
23<!-- INDENTATION -->
24<table width="100%" border=0 rules="none" frame="void"
25 cols="2" cellspacing="0" cellpadding="0">
26<tr valign="top" align="left">
27<td width="8%"></td>
28<td width="91%">
29<p>TIFFReadRGBATile &minus; read and decode an image tile
30into a fixed-format raster</p>
31</td>
32</table>
33<a name="SYNOPSIS"></a>
34<h2>SYNOPSIS</h2>
35<!-- INDENTATION -->
36<table width="100%" border=0 rules="none" frame="void"
37 cols="2" cellspacing="0" cellpadding="0">
38<tr valign="top" align="left">
39<td width="8%"></td>
40<td width="91%">
41<p><b>#include &lt;tiffio.h&gt;</b></p>
42</td>
43</table>
44<!-- TABS -->
45<table width="100%" border=0 rules="none" frame="void"
46 cols="5" cellspacing="0" cellpadding="0">
47<tr valign="top" align="left">
48<td width="8%"></td>
49<td width="-2%">
50
51<p><b>#define TIFFGetR(abgr)</b></p>
52</td>
53<td width="25%"></td>
54<td width="6%"></td>
55<td width="61%">
56
57<p><b>((abgr) &amp; 0xff)</b></p>
58</td>
59<tr valign="top" align="left">
60<td width="8%"></td>
61<td width="-2%">
62
63<p><b>#define TIFFGetG(abgr)</b></p>
64</td>
65<td width="25%"></td>
66<td width="6%"></td>
67<td width="61%">
68
69<p><b>(((abgr) &gt;&gt; 8) &amp; 0xff)</b></p>
70</td>
71<tr valign="top" align="left">
72<td width="8%"></td>
73<td width="-2%">
74
75<p><b>#define TIFFGetB(abgr)</b></p>
76</td>
77<td width="25%"></td>
78<td width="6%"></td>
79<td width="61%">
80
81<p><b>(((abgr) &gt;&gt; 16) &amp; 0xff)</b></p>
82</td>
83<tr valign="top" align="left">
84<td width="8%"></td>
85<td width="-2%">
86
87<p><b>#define TIFFGetA(abgr)</b></p>
88</td>
89<td width="25%"></td>
90<td width="6%"></td>
91<td width="61%">
92
93<p><b>(((abgr) &gt;&gt; 24) &amp; 0xff)</b></p>
94</td>
95</table>
96<!-- INDENTATION -->
97<table width="100%" border=0 rules="none" frame="void"
98 cols="2" cellspacing="0" cellpadding="0">
99<tr valign="top" align="left">
100<td width="8%"></td>
101<td width="91%">
102<p><b>int TIFFReadRGBATile(TIFF *</b><i>tif</i><b>,
103uint32</b> <i>x</i><b>, uint32</b> <i>y</i><b>, uint32
104*</b><i>raster</i><b>)</b></p>
105</td>
106</table>
107<a name="DESCRIPTION"></a>
108<h2>DESCRIPTION</h2>
109<!-- INDENTATION -->
110<table width="100%" border=0 rules="none" frame="void"
111 cols="2" cellspacing="0" cellpadding="0">
112<tr valign="top" align="left">
113<td width="8%"></td>
114<td width="91%">
115<p><i>TIFFReadRGBATile</i> reads a single tile of a
116tile-based image into memory, storing the result in the user
117supplied RGBA <i>raster</i>. The raster is assumed to be an
118array of width times length 32-bit entries, where width is
119the width of a tile (TIFFTAG_TILEWIDTH) and length is the
120height of a tile (TIFFTAG_TILELENGTH).</p>
121<!-- INDENTATION -->
122<p>The <i>x</i> and <i>y</i> values are the offsets from the
123top left corner to the top left corner of the tile to be
124read. They must be an exact multiple of the tile width and
125length.</p>
126<!-- INDENTATION -->
127<p>Note that the raster is assume to be organized such that
128the pixel at location (<i>x</i>,<i>y</i>) is
129<i>raster</i>[<i>y</i>*<i>width</i>+<i>x</i>]; with the
130raster origin in the <i>lower-left hand corner</i> of the
131tile. That is bottom to top organization. Edge tiles which
132partly fall off the image will be filled out with
133appropriate zeroed areas.</p>
134<!-- INDENTATION -->
135<p>Raster pixels are 8-bit packed red, green, blue, alpha
136samples. The macros <i>TIFFGetR</i>, <i>TIFFGetG</i>,
137<i>TIFFGetB</i>, and <i>TIFFGetA</i> should be used to
138access individual samples. Images without Associated Alpha
139matting information have a constant Alpha of 1.0 (255).</p>
140<!-- INDENTATION -->
141<p>See the <i>TIFFRGBAImage</i>(3TIFF) page for more details
142on how various image types are converted to RGBA values.</p>
143</td>
144</table>
145<a name="NOTES"></a>
146<h2>NOTES</h2>
147<!-- INDENTATION -->
148<table width="100%" border=0 rules="none" frame="void"
149 cols="2" cellspacing="0" cellpadding="0">
150<tr valign="top" align="left">
151<td width="8%"></td>
152<td width="91%">
153<p>Samples must be either 1, 2, 4, 8, or 16 bits.
154Colorimetric samples/pixel must be either 1, 3, or 4 (i.e.
155<i>SamplesPerPixel</i> minus <i>ExtraSamples</i>).</p>
156<!-- INDENTATION -->
157<p>Palette image colormaps that appear to be incorrectly
158written as 8-bit values are automatically scaled to
15916-bits.</p>
160<!-- INDENTATION -->
161<p><i>TIFFReadRGBATile</i> is just a wrapper around the more
162general <i>TIFFRGBAImage</i>(3TIFF) facilities. It&rsquo;s
163main advantage over the similar <i>TIFFReadRGBAImage()</i>
164function is that for large images a single buffer capable of
165holding the whole image doesn&rsquo;t need to be allocated,
166only enough for one tile. The <i>TIFFReadRGBAStrip()</i>
167function does a similar operation for stripped images.</p>
168</td>
169</table>
170<a name="RETURN VALUES"></a>
171<h2>RETURN VALUES</h2>
172<!-- INDENTATION -->
173<table width="100%" border=0 rules="none" frame="void"
174 cols="2" cellspacing="0" cellpadding="0">
175<tr valign="top" align="left">
176<td width="8%"></td>
177<td width="91%">
178<p>1 is returned if the image was successfully read and
179converted. Otherwise, 0 is returned if an error was
180encountered.</p>
181</td>
182</table>
183<a name="DIAGNOSTICS"></a>
184<h2>DIAGNOSTICS</h2>
185<!-- INDENTATION -->
186<table width="100%" border=0 rules="none" frame="void"
187 cols="2" cellspacing="0" cellpadding="0">
188<tr valign="top" align="left">
189<td width="8%"></td>
190<td width="91%">
191<p>All error messages are directed to the
192<i>TIFFError</i>(3TIFF) routine.</p>
193<!-- INDENTATION -->
194<p><b>Sorry, can not handle %d-bit pictures</b>. The image
195had <i>BitsPerSample</i> other than 1, 2, 4, 8, or 16.</p>
196<!-- INDENTATION -->
197<p><b>Sorry, can not handle %d-channel images</b>. The image
198had <i>SamplesPerPixel</i> other than 1, 3, or 4.</p>
199<!-- INDENTATION -->
200<p><b>Missing needed &quot;PhotometricInterpretation&quot;
201tag</b>. The image did not have a tag that describes how to
202display the data.</p>
203<!-- INDENTATION -->
204<p><b>No &quot;PhotometricInterpretation&quot; tag, assuming
205RGB</b>. The image was missing a tag that describes how to
206display it, but because it has 3 or 4 samples/pixel, it is
207assumed to be <small>RGB.</small></p>
208<!-- INDENTATION -->
209<p><b>No &quot;PhotometricInterpretation&quot; tag, assuming
210min-is-black</b>. The image was missing a tag that describes
211how to display it, but because it has 1 sample/pixel, it is
212assumed to be a grayscale or bilevel image.</p>
213<!-- INDENTATION -->
214<p><b>No space for photometric conversion table</b>. There
215was insufficient memory for a table used to convert image
216samples to 8-bit <small>RGB.</small></p>
217<!-- INDENTATION -->
218<p><b>Missing required &quot;Colormap&quot; tag</b>. A
219Palette image did not have a required <i>Colormap</i>
220tag.</p>
221<!-- INDENTATION -->
222<p><b>No space for tile buffer</b>. There was insufficient
223memory to allocate an i/o buffer.</p>
224<!-- INDENTATION -->
225<p><b>No space for strip buffer</b>. There was insufficient
226memory to allocate an i/o buffer.</p>
227<!-- INDENTATION -->
228<p><b>Can not handle format</b>. The image has a format
229(combination of <i>BitsPerSample</i>,
230<i>SamplesPerPixel</i>, and
231<i>PhotometricInterpretation</i>) that
232<i>TIFFReadRGBAImage</i> can not handle.</p>
233<!-- INDENTATION -->
234<p><b>No space for B&amp;W mapping table</b>. There was
235insufficient memory to allocate a table used to map
236grayscale data to <small>RGB.</small></p>
237<!-- INDENTATION -->
238<p><b>No space for Palette mapping table</b>. There was
239insufficient memory to allocate a table used to map data to
2408-bit <small>RGB.</small></p>
241</td>
242</table>
243<a name="SEE ALSO"></a>
244<h2>SEE ALSO</h2>
245<!-- INDENTATION -->
246<table width="100%" border=0 rules="none" frame="void"
247 cols="2" cellspacing="0" cellpadding="0">
248<tr valign="top" align="left">
249<td width="8%"></td>
250<td width="91%">
251<p><b>TIFFOpen</b>(3TIFF), <b>TIFFRGBAImage</b>(3TIFF),
252<b>TIFFReadRGBAImage</b>(3TIFF),
253<b>TIFFReadRGBAStrip</b>(3TIFF), <b>libtiff</b>(3TIFF)</p>
254<!-- INDENTATION -->
255<p>Libtiff library home page:
256<b>http://www.remotesensing.org/libtiff/</b></p>
257</td>
258</table>
259<hr>
260</body>
261</html>