| 1 |
TIFFFieldWriteCount |
| 2 |
=================== |
| 3 |
|
| 4 |
Synopsis |
| 5 |
-------- |
| 6 |
|
| 7 |
.. highlight:: c |
| 8 |
|
| 9 |
:: |
| 10 |
|
| 11 |
#include <tiffio.h> |
| 12 |
|
| 13 |
.. c:function:: int TIFFFieldWriteCount(const TIFFField* fip) |
| 14 |
|
| 15 |
Description |
| 16 |
----------- |
| 17 |
|
| 18 |
:c:func:`TIFFFieldWriteCount` returns the number of values to be written |
| 19 |
into the specified TIFF field; that is, the number of arguments that should |
| 20 |
be supplied to :c:func:`TIFFSetField`. For most field types this is a small |
| 21 |
positive integer, typically 1 or 2, but there are some special values: |
| 22 |
|
| 23 |
* :c:macro:`TIFF_VARIABLE` indicates that a variable number of values is |
| 24 |
possible; then, a :c:type:`uint16_t` *count* argument and a pointer *data* |
| 25 |
argument must be supplied to :c:func:`TIFFSetField`. |
| 26 |
* :c:macro:`TIFF_VARIABLE2` is the same as :c:macro:`TIFF_VARIABLE` except |
| 27 |
that the *count* argument must have type :c:expr:`uint32_t`. (On most |
| 28 |
modern machines, this makes no practical difference, and the *count* |
| 29 |
argument can simply be an :c:expr:`int` in either case.) |
| 30 |
* :c:type:`TIFF_SPP` indicates that the number of arguments must be equal |
| 31 |
to the image's number of samples per pixel. |
| 32 |
|
| 33 |
*fip* is a field information pointer previously returned by |
| 34 |
:c:func:`TIFFFindField`, :c:func:`TIFFFieldWithTag`, or |
| 35 |
:c:func:`TIFFFieldWithName`. |
| 36 |
|
| 37 |
For most field types, :c:func:`TIFFFieldWriteCount` returns the same value as |
| 38 |
:c:func:`TIFFFieldReadCount`, but there are some exceptions. |
| 39 |
|
| 40 |
Return values |
| 41 |
------------- |
| 42 |
|
| 43 |
:c:func:`TIFFFieldWriteCount` returns an integer. |
| 44 |
|
| 45 |
See also |
| 46 |
-------- |
| 47 |
|
| 48 |
:doc:`TIFFFieldDataType` (3tiff), |
| 49 |
:doc:`TIFFFieldName` (3tiff), |
| 50 |
:doc:`TIFFFieldPassCount` (3tiff), |
| 51 |
:doc:`TIFFFieldQuery` (3tiff), |
| 52 |
:doc:`TIFFFieldReadCount` (3tiff), |
| 53 |
:doc:`TIFFFieldTag` (3tiff), |
| 54 |
:doc:`libtiff` (3tiff) |