Debian Codegraph @

texk/xdvipsk/thirdparty/libtiff/doc/functions/_TIFFauxiliary.rst

raw
1 _TIFFauxiliary
2 =================
3
4 Synopsis
5 --------
6
7 .. highlight:: c
8
9 ::
10
11 #include <tiffio.h>
12
13 .. c:function:: uint32_t _TIFFClampDoubleToUInt32(double val)
14
15 .. c:function:: uint32_t _TIFFMultiply32(TIFF* tif, uint32_t first, uint32_t second, const char* where)
16
17 .. c:function:: uint64_t _TIFFMultiply64(TIFF* tif, uint64_t first, uint64_t second, const char* where)
18
19 Description
20 -----------
21
22 :c:func:`_TIFFClampDoubleToUInt32` clamps double values into the range
23 of :c:type:`uint32_t` (i.e. 0 .. 0xFFFFFFFF)
24
25 :c:func:`_TIFFMultiply32` and :c:func:`_TIFFMultiply64` checks for
26 an integer overflow of the multiplication result and return the multiplication
27 result or `0` if an overflow would happen.
28 The string `where` is printed in the error message in case an overflow
29 happens and can be used to indicate where the function was called.
30
31 See also
32 --------
33
34 :doc:`libtiff` (3tiff),