w32tex
About: TeX Live provides a comprehensive TeX system including all the major TeX-related programs, macro packages, and fonts that are free software. Windows sources.
  Fossies Dox: w32tex-src.tar.xz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

tif_predict.c File Reference
#include "tiffiop.h"
#include "tif_predict.h"
#include <assert.h>
Include dependency graph for tif_predict.c:

Go to the source code of this file.

Macros

#define PredictorState(tif)   ((TIFFPredictorState*) (tif)->tif_data)
 
#define REPEAT4(n, op)
 
#define FIELD_PREDICTOR   (FIELD_CODEC+0) /* XXX */
 
#define N(a)   (sizeof (a) / sizeof (a[0]))
 

Functions

static void horAcc8 (TIFF *, tidata_t, tsize_t)
 
static void horAcc16 (TIFF *, tidata_t, tsize_t)
 
static void swabHorAcc16 (TIFF *, tidata_t, tsize_t)
 
static void horDiff8 (TIFF *, tidata_t, tsize_t)
 
static void horDiff16 (TIFF *, tidata_t, tsize_t)
 
static int PredictorDecodeRow (TIFF *, tidata_t, tsize_t, tsample_t)
 
static int PredictorDecodeTile (TIFF *, tidata_t, tsize_t, tsample_t)
 
static int PredictorEncodeRow (TIFF *, tidata_t, tsize_t, tsample_t)
 
static int PredictorEncodeTile (TIFF *, tidata_t, tsize_t, tsample_t)
 
static int PredictorSetup (TIFF *tif)
 
static int PredictorSetupDecode (TIFF *tif)
 
static int PredictorSetupEncode (TIFF *tif)
 
static int PredictorVSetField (TIFF *tif, ttag_t tag, va_list ap)
 
static int PredictorVGetField (TIFF *tif, ttag_t tag, va_list ap)
 
static void PredictorPrintDir (TIFF *tif, FILE *fd, long flags)
 
int TIFFPredictorInit (TIFF *tif)
 

Variables

static const TIFFFieldInfo predictFieldInfo []
 

Macro Definition Documentation

◆ FIELD_PREDICTOR

#define FIELD_PREDICTOR   (FIELD_CODEC+0) /* XXX */

Definition at line 378 of file tif_predict.c.

◆ N

#define N (   a)    (sizeof (a) / sizeof (a[0]))

Definition at line 384 of file tif_predict.c.

◆ PredictorState

#define PredictorState (   tif)    ((TIFFPredictorState*) (tif)->tif_data)

Definition at line 37 of file tif_predict.c.

◆ REPEAT4

#define REPEAT4 (   n,
  op 
)
Value:
switch (n) { \
default: { int i; for (i = n-4; i > 0; i--) { op; } } \
case 4: op; \
case 3: op; \
case 2: op; \
case 1: op; \
case 0: ; \
}
#define n
Definition: t4ht.c:1290
small capitals from c petite p scientific i
Definition: afcover.h:80
op
Definition: tex4ht.c:3129

Definition at line 149 of file tif_predict.c.

Function Documentation

◆ horAcc16()

static void horAcc16 ( TIFF tif,
tidata_t  cp0,
tsize_t  cc 
)
static

Definition at line 221 of file tif_predict.c.

References PredictorState, REPEAT4, and stride().

Referenced by PredictorSetupDecode().

◆ horAcc8()

static void horAcc8 ( TIFF tif,
tidata_t  cp0,
tsize_t  cc 
)
static

Definition at line 160 of file tif_predict.c.

References cb, cp, cr, PredictorState, REPEAT4, sp, and stride().

Referenced by PredictorSetupDecode().

◆ horDiff16()

static void horDiff16 ( TIFF tif,
tidata_t  cp0,
tsize_t  cc 
)
static

Definition at line 328 of file tif_predict.c.

References PredictorState, REPEAT4, sp, and stride().

Referenced by PredictorSetupEncode().

◆ horDiff8()

static void horDiff8 ( TIFF tif,
tidata_t  cp0,
tsize_t  cc 
)
static

Definition at line 283 of file tif_predict.c.

References a1, a2, b1, b2, cp, g2, PredictorState, r1, r2, REPEAT4, sp, and stride().

Referenced by PredictorSetupEncode().

◆ PredictorDecodeRow()

static int PredictorDecodeRow ( TIFF tif,
tidata_t  op0,
tsize_t  occ0,
tsample_t  s 
)
static

Definition at line 240 of file tif_predict.c.

References assert(), NULL, PredictorState, s, and sp.

Referenced by PredictorSetupDecode().

◆ PredictorDecodeTile()

static int PredictorDecodeTile ( TIFF tif,
tidata_t  op0,
tsize_t  occ0,
tsample_t  s 
)
static

Definition at line 262 of file tif_predict.c.

References assert(), NULL, PredictorState, s, and sp.

Referenced by PredictorSetupDecode().

◆ PredictorEncodeRow()

static int PredictorEncodeRow ( TIFF tif,
tidata_t  bp,
tsize_t  cc,
tsample_t  s 
)
static

Definition at line 346 of file tif_predict.c.

References assert(), bp, NULL, PredictorState, s, and sp.

Referenced by PredictorSetupEncode().

◆ PredictorEncodeTile()

static int PredictorEncodeTile ( TIFF tif,
tidata_t  bp0,
tsize_t  cc0,
tsample_t  s 
)
static

Definition at line 359 of file tif_predict.c.

References assert(), bp, NULL, PredictorState, s, and sp.

Referenced by PredictorSetupEncode().

◆ PredictorPrintDir()

static void PredictorPrintDir ( TIFF tif,
FILE fd,
long  flags 
)
static

Definition at line 419 of file tif_predict.c.

References FIELD_PREDICTOR, flags, fprintf, PredictorState, sp, TIFFFieldSet, and void.

Referenced by TIFFPredictorInit().

◆ PredictorSetup()

◆ PredictorSetupDecode()

◆ PredictorSetupEncode()

◆ PredictorVGetField()

static int PredictorVGetField ( TIFF tif,
ttag_t  tag,
va_list  ap 
)
static

Definition at line 404 of file tif_predict.c.

References ap, PredictorState, sp, tag, TIFFTAG_PREDICTOR, and va_arg.

Referenced by TIFFPredictorInit().

◆ PredictorVSetField()

static int PredictorVSetField ( TIFF tif,
ttag_t  tag,
va_list  ap 
)
static

◆ swabHorAcc16()

static void swabHorAcc16 ( TIFF tif,
tidata_t  cp0,
tsize_t  cc 
)
static

Definition at line 203 of file tif_predict.c.

References PredictorState, REPEAT4, sp, stride(), and TIFFSwabArrayOfShort().

Referenced by PredictorSetupDecode().

◆ TIFFPredictorInit()

Variable Documentation

◆ predictFieldInfo

const TIFFFieldInfo predictFieldInfo[]
static
Initial value:
= {
{ 317 , 1, 1, TIFF_SHORT, ( 62 +0) ,
((bool)0) , ((bool)0) , "Predictor" },
}
#define TIFF_SHORT
Definition: gvceps.c:721

Definition at line 380 of file tif_predict.c.

Referenced by TIFFPredictorInit().