LibTIFF 4.7.2
TIFF library public API and implementation reference
Loading...
Searching...
No Matches
Macros | Functions
tif_write.c File Reference

Transfer image bytes through raw buffers and codec methods. More...

#include "tiffiop.h"
#include <assert.h>
#include <stdio.h>
Include dependency graph for tif_write.c:

Go to the source code of this file.

Macros

#define NOSTRIP   ((uint32_t)(-1)) /* undefined state */
 Local repeat of the NOSTRIP sentinel defined in tif_dir.h.
 
#define WRITECHECKSTRIPS(tif, module)    (((tif)->tif_flags & TIFF_BEENWRITING) || TIFFWriteCheck((tif), 0, module))
 Reuse write preparation or check strip organisation.
 
#define WRITECHECKTILES(tif, module)    (((tif)->tif_flags & TIFF_BEENWRITING) || TIFFWriteCheck((tif), 1, module))
 Reuse write preparation or check tile organisation.
 
#define BUFFERCHECK(tif)
 Reuse an output buffer or allocate default encoding storage.
 
#define isUnspecified(tif, f)    (TIFFFieldSet(tif, f) && (tif)->tif_dir.td_imagelength == 0)
 Test the zero-image-length provisional strile case.
 

Functions

static int TIFFGrowStrips (TIFF *tif, uint32_t delta, const char *module)
 Grow contiguous strip offset/count arrays by a requested delta.
 
static int TIFFAppendToStrip (TIFF *tif, uint32_t strip, uint8_t *data, tmsize_t cc)
 Append stored bytes or relocate a growing overwritten strile.
 
int TIFFWriteScanline (TIFF *tif, void *buf, uint32_t row, uint16_t sample)
 Encode and buffer one image scanline.
 
static int _TIFFReserveLargeEnoughWriteBuffer (TIFF *tif, uint32_t strip_or_tile)
 Reserve raw output capacity for a possible strile rewrite.
 
tmsize_t TIFFWriteEncodedStrip (TIFF *tif, uint32_t strip, void *data, tmsize_t cc)
 Write encoded samples to one strip.
 
tmsize_t TIFFWriteRawStrip (TIFF *tif, uint32_t strip, void *data, tmsize_t cc)
 Write raw stored bytes to one strip.
 
tmsize_t TIFFWriteTile (TIFF *tif, void *buf, uint32_t x, uint32_t y, uint32_t z, uint16_t s)
 Encode the tile containing image coordinates.
 
tmsize_t TIFFWriteEncodedTile (TIFF *tif, uint32_t tile, void *data, tmsize_t cc)
 Write encoded samples to one tile.
 
tmsize_t TIFFWriteRawTile (TIFF *tif, uint32_t tile, void *data, tmsize_t cc)
 Write raw stored bytes to one tile.
 
int TIFFSetupStrips (TIFF *tif)
 Replace strile offset/count arrays from current geometry.
 
int TIFFWriteCheck (TIFF *tif, int tiles, const char *module)
 Validate and prepare geometry for image writing.
 
int TIFFWriteBufferSetup (TIFF *tif, void *bp, tmsize_t size)
 Replace the handle's encoding buffer.
 
int TIFFFlushData1 (TIFF *tif)
 Append buffered encoded bytes without invoking postencode recursively.
 
void TIFFSetWriteOffset (TIFF *tif, toff_t off)
 Change the cached next payload write offset.
 

Detailed Description

Transfer image bytes through raw buffers and codec methods.

Definition in file tif_write.c.