Use consistent/modern code formatting for pointers

The convention used by libjpeg:

    type * variable;

is not very common anymore, because it looks too much like
multiplication.  Some (particularly C++ programmers) prefer to tuck the
pointer symbol against the type:

    type* variable;

to emphasize that a pointer to a type is effectively a new type.
However, this can also be confusing, since defining multiple variables
on the same line would not work properly:

    type* variable1, variable2;  /* Only variable1 is actually a
                                    pointer. */

This commit reformats the entirety of the libjpeg-turbo code base so
that it uses the same code formatting convention for pointers that the
TurboJPEG API code uses:

    type *variable1, *variable2;

This seems to be the most common convention among C programmers, and
it is the convention used by other codec libraries, such as libpng and
libtiff.
This commit is contained in:
DRC
2016-02-19 08:53:33 -06:00
parent ae41128845
commit bd49803f92
125 changed files with 980 additions and 978 deletions

View File

@@ -82,7 +82,7 @@ end_progress_monitor (j_common_ptr cinfo)
*/
GLOBAL(boolean)
keymatch (char * arg, const char * keyword, int minchars)
keymatch (char *arg, const char *keyword, int minchars)
{
register int ca, ck;
register int nmatched = 0;

View File

@@ -24,7 +24,7 @@
* Object interface for cjpeg's source file decoding modules
*/
typedef struct cjpeg_source_struct * cjpeg_source_ptr;
typedef struct cjpeg_source_struct *cjpeg_source_ptr;
struct cjpeg_source_struct {
void (*start_input) (j_compress_ptr cinfo, cjpeg_source_ptr sinfo);
@@ -42,7 +42,7 @@ struct cjpeg_source_struct {
* Object interface for djpeg's output file encoding modules
*/
typedef struct djpeg_dest_struct * djpeg_dest_ptr;
typedef struct djpeg_dest_struct *djpeg_dest_ptr;
struct djpeg_dest_struct {
/* start_output is called after jpeg_start_decompress finishes.
@@ -56,7 +56,7 @@ struct djpeg_dest_struct {
void (*finish_output) (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo);
/* Target file spec; filled in by djpeg.c after object is created. */
FILE * output_file;
FILE *output_file;
/* Output pixel-row buffer. Created by module init or start_output.
* Width is cinfo->output_width * cinfo->output_components;
@@ -83,7 +83,7 @@ struct cdjpeg_progress_mgr {
int percent_done;
};
typedef struct cdjpeg_progress_mgr * cd_progress_ptr;
typedef struct cdjpeg_progress_mgr *cd_progress_ptr;
/* Module selection routines for I/O modules. */
@@ -102,9 +102,9 @@ EXTERN(djpeg_dest_ptr) jinit_write_targa (j_decompress_ptr cinfo);
/* cjpeg support routines (in rdswitch.c) */
EXTERN(boolean) read_quant_tables (j_compress_ptr cinfo, char * filename,
EXTERN(boolean) read_quant_tables (j_compress_ptr cinfo, char *filename,
boolean force_baseline);
EXTERN(boolean) read_scan_script (j_compress_ptr cinfo, char * filename);
EXTERN(boolean) read_scan_script (j_compress_ptr cinfo, char *filename);
EXTERN(boolean) set_quality_ratings (j_compress_ptr cinfo, char *arg,
boolean force_baseline);
EXTERN(boolean) set_quant_slots (j_compress_ptr cinfo, char *arg);
@@ -112,7 +112,7 @@ EXTERN(boolean) set_sample_factors (j_compress_ptr cinfo, char *arg);
/* djpeg support routines (in rdcolmap.c) */
EXTERN(void) read_color_map (j_decompress_ptr cinfo, FILE * infile);
EXTERN(void) read_color_map (j_decompress_ptr cinfo, FILE *infile);
/* common support routines (in cdjpeg.c) */
@@ -120,7 +120,7 @@ EXTERN(void) enable_signal_catcher (j_common_ptr cinfo);
EXTERN(void) start_progress_monitor (j_common_ptr cinfo,
cd_progress_ptr progress);
EXTERN(void) end_progress_monitor (j_common_ptr cinfo);
EXTERN(boolean) keymatch (char * arg, const char * keyword, int minchars);
EXTERN(boolean) keymatch (char *arg, const char *keyword, int minchars);
EXTERN(FILE *) read_stdin (void);
EXTERN(FILE *) write_stdout (void);

22
cjpeg.c
View File

@@ -82,7 +82,7 @@ static boolean is_targa; /* records user -targa switch */
LOCAL(cjpeg_source_ptr)
select_file_type (j_compress_ptr cinfo, FILE * infile)
select_file_type (j_compress_ptr cinfo, FILE *infile)
{
int c;
@@ -138,8 +138,8 @@ select_file_type (j_compress_ptr cinfo, FILE * infile)
*/
static const char * progname; /* program name for error messages */
static char * outfilename; /* for -outfile switch */
static const char *progname; /* program name for error messages */
static char *outfilename; /* for -outfile switch */
boolean memdst; /* for -memdst switch */
@@ -220,14 +220,14 @@ parse_switches (j_compress_ptr cinfo, int argc, char **argv,
*/
{
int argn;
char * arg;
char *arg;
boolean force_baseline;
boolean simple_progressive;
char * qualityarg = NULL; /* saves -quality parm if any */
char * qtablefile = NULL; /* saves -qtables filename if any */
char * qslotsarg = NULL; /* saves -qslots parm if any */
char * samplearg = NULL; /* saves -sample parm if any */
char * scansarg = NULL; /* saves -scans parm if any */
char *qualityarg = NULL; /* saves -quality parm if any */
char *qtablefile = NULL; /* saves -qtables filename if any */
char *qslotsarg = NULL; /* saves -qslots parm if any */
char *samplearg = NULL; /* saves -sample parm if any */
char *scansarg = NULL; /* saves -scans parm if any */
/* Set up default JPEG parameters. */
@@ -495,8 +495,8 @@ main (int argc, char **argv)
#endif
int file_index;
cjpeg_source_ptr src_mgr;
FILE * input_file;
FILE * output_file = NULL;
FILE *input_file;
FILE *output_file = NULL;
unsigned char *outbuffer = NULL;
unsigned long outsize = 0;
JDIMENSION num_scanlines;

View File

@@ -79,7 +79,7 @@ prefix=${old_prefix}
# Check whether compiler supports pointers to undefined structures
AC_MSG_CHECKING(whether compiler supports pointers to undefined structures)
AC_TRY_COMPILE([ typedef struct undefined_structure * undef_struct_ptr; ], ,
AC_TRY_COMPILE([ typedef struct undefined_structure *undef_struct_ptr; ], ,
AC_MSG_RESULT(yes),
[AC_MSG_RESULT(no)
AC_DEFINE([INCOMPLETE_TYPES_BROKEN], [1],

14
djpeg.c
View File

@@ -88,8 +88,8 @@ static IMAGE_FORMATS requested_fmt;
*/
static const char * progname; /* program name for error messages */
static char * outfilename; /* for -outfile switch */
static const char *progname; /* program name for error messages */
static char *outfilename; /* for -outfile switch */
boolean memsrc; /* for -memsrc switch */
boolean strip, skip;
JDIMENSION startY, endY;
@@ -190,7 +190,7 @@ parse_switches (j_decompress_ptr cinfo, int argc, char **argv,
*/
{
int argn;
char * arg;
char *arg;
/* Set up default JPEG parameters. */
requested_fmt = DEFAULT_FMT; /* set default output file format */
@@ -307,7 +307,7 @@ parse_switches (j_decompress_ptr cinfo, int argc, char **argv,
usage();
if (for_real) { /* too expensive to do twice! */
#ifdef QUANT_2PASS_SUPPORTED /* otherwise can't quantize to supplied map */
FILE * mapfile;
FILE *mapfile;
if ((mapfile = fopen(argv[argn], READ_BINARY)) == NULL) {
fprintf(stderr, "%s: can't open %s\n", progname, argv[argn]);
@@ -417,7 +417,7 @@ LOCAL(unsigned int)
jpeg_getc (j_decompress_ptr cinfo)
/* Read next byte */
{
struct jpeg_source_mgr * datasrc = cinfo->src;
struct jpeg_source_mgr *datasrc = cinfo->src;
if (datasrc->bytes_in_buffer == 0) {
if (! (*datasrc->fill_input_buffer) (cinfo))
@@ -493,8 +493,8 @@ main (int argc, char **argv)
#endif
int file_index;
djpeg_dest_ptr dest_mgr = NULL;
FILE * input_file;
FILE * output_file;
FILE *input_file;
FILE *output_file;
unsigned char *inbuffer = NULL;
unsigned long insize = 0;
JDIMENSION num_scanlines;

View File

@@ -58,7 +58,7 @@
* RGB color and is described by:
*/
extern JSAMPLE * image_buffer; /* Points to large array of R,G,B-order data */
extern JSAMPLE *image_buffer; /* Points to large array of R,G,B-order data */
extern int image_height; /* Number of rows in image */
extern int image_width; /* Number of columns in image */
@@ -69,7 +69,7 @@ extern int image_width; /* Number of columns in image */
*/
GLOBAL(void)
write_JPEG_file (char * filename, int quality)
write_JPEG_file (char *filename, int quality)
{
/* This struct contains the JPEG compression parameters and pointers to
* working space (which is allocated as needed by the JPEG library).
@@ -88,7 +88,7 @@ write_JPEG_file (char * filename, int quality)
*/
struct jpeg_error_mgr jerr;
/* More stuff */
FILE * outfile; /* target file */
FILE *outfile; /* target file */
JSAMPROW row_pointer[1]; /* pointer to JSAMPLE row[s] */
int row_stride; /* physical row width in image buffer */
@@ -253,7 +253,7 @@ struct my_error_mgr {
jmp_buf setjmp_buffer; /* for return to caller */
};
typedef struct my_error_mgr * my_error_ptr;
typedef struct my_error_mgr *my_error_ptr;
/*
* Here's the routine that will replace the standard error_exit method:
@@ -281,7 +281,7 @@ my_error_exit (j_common_ptr cinfo)
GLOBAL(int)
read_JPEG_file (char * filename)
read_JPEG_file (char *filename)
{
/* This struct contains the JPEG decompression parameters and pointers to
* working space (which is allocated as needed by the JPEG library).
@@ -293,7 +293,7 @@ read_JPEG_file (char * filename)
*/
struct my_error_mgr jerr;
/* More stuff */
FILE * infile; /* source file */
FILE *infile; /* source file */
JSAMPARRAY buffer; /* Output row buffer */
int row_stride; /* physical row width in output buffer */

View File

@@ -50,8 +50,8 @@ jpeg_CreateCompress (j_compress_ptr cinfo, int version, size_t structsize)
* complain here.
*/
{
struct jpeg_error_mgr * err = cinfo->err;
void * client_data = cinfo->client_data; /* ignore Purify complaint here */
struct jpeg_error_mgr *err = cinfo->err;
void *client_data = cinfo->client_data; /* ignore Purify complaint here */
MEMZERO(cinfo, sizeof(struct jpeg_compress_struct));
cinfo->err = err;
cinfo->client_data = client_data;
@@ -134,8 +134,8 @@ GLOBAL(void)
jpeg_suppress_tables (j_compress_ptr cinfo, boolean suppress)
{
int i;
JQUANT_TBL * qtbl;
JHUFF_TBL * htbl;
JQUANT_TBL *qtbl;
JHUFF_TBL *htbl;
for (i = 0; i < NUM_QUANT_TBLS; i++) {
if ((qtbl = cinfo->quant_tbl_ptrs[i]) != NULL)

View File

@@ -41,14 +41,14 @@ typedef struct {
int next_restart_num; /* next restart number to write (0-7) */
/* Pointers to statistics areas (these workspaces have image lifespan) */
unsigned char * dc_stats[NUM_ARITH_TBLS];
unsigned char * ac_stats[NUM_ARITH_TBLS];
unsigned char *dc_stats[NUM_ARITH_TBLS];
unsigned char *ac_stats[NUM_ARITH_TBLS];
/* Statistics bin for coding with fixed probability 0.5 */
unsigned char fixed_bin[4];
} arith_entropy_encoder;
typedef arith_entropy_encoder * arith_entropy_ptr;
typedef arith_entropy_encoder *arith_entropy_ptr;
/* The following two definitions specify the allocation chunk size
* for the statistics area.
@@ -119,7 +119,7 @@ LOCAL(void)
emit_byte (int val, j_compress_ptr cinfo)
/* Write next output byte; we do not support suspension in this module. */
{
struct jpeg_destination_mgr * dest = cinfo->dest;
struct jpeg_destination_mgr *dest = cinfo->dest;
*dest->next_output_byte++ = (JOCTET) val;
if (--dest->free_in_buffer == 0)
@@ -323,7 +323,7 @@ emit_restart (j_compress_ptr cinfo, int restart_num)
{
arith_entropy_ptr entropy = (arith_entropy_ptr) cinfo->entropy;
int ci;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
finish_pass(cinfo);
@@ -683,7 +683,7 @@ METHODDEF(boolean)
encode_mcu (j_compress_ptr cinfo, JBLOCKROW *MCU_data)
{
arith_entropy_ptr entropy = (arith_entropy_ptr) cinfo->entropy;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
JBLOCKROW block;
unsigned char *st;
int blkn, ci, tbl, k, ke;
@@ -826,7 +826,7 @@ start_pass (j_compress_ptr cinfo, boolean gather_statistics)
{
arith_entropy_ptr entropy = (arith_entropy_ptr) cinfo->entropy;
int ci, tbl;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
if (gather_statistics)
/* Make sure to avoid that in the master control logic!

View File

@@ -54,7 +54,7 @@ typedef struct {
jvirt_barray_ptr whole_image[MAX_COMPONENTS];
} my_coef_controller;
typedef my_coef_controller * my_coef_ptr;
typedef my_coef_controller *my_coef_ptr;
/* Forward declarations */

View File

@@ -26,10 +26,10 @@ typedef struct {
struct jpeg_color_converter pub; /* public fields */
/* Private state for RGB->YCC conversion */
JLONG * rgb_ycc_tab; /* => table for RGB to YCbCr conversion */
JLONG *rgb_ycc_tab; /* => table for RGB to YCbCr conversion */
} my_color_converter;
typedef my_color_converter * my_cconvert_ptr;
typedef my_color_converter *my_cconvert_ptr;
/**************** RGB -> YCbCr conversion: most common case **************/
@@ -198,7 +198,7 @@ METHODDEF(void)
rgb_ycc_start (j_compress_ptr cinfo)
{
my_cconvert_ptr cconvert = (my_cconvert_ptr) cinfo->cconvert;
JLONG * rgb_ycc_tab;
JLONG *rgb_ycc_tab;
JLONG i;
/* Allocate and fill in the conversion tables. */
@@ -382,7 +382,7 @@ cmyk_ycck_convert (j_compress_ptr cinfo,
{
my_cconvert_ptr cconvert = (my_cconvert_ptr) cinfo->cconvert;
register int r, g, b;
register JLONG * ctab = cconvert->rgb_ycc_tab;
register JLONG *ctab = cconvert->rgb_ycc_tab;
register JSAMPROW inptr;
register JSAMPROW outptr0, outptr1, outptr2, outptr3;
register JDIMENSION col;

View File

@@ -25,21 +25,21 @@
/* Private subobject for this module */
typedef void (*forward_DCT_method_ptr) (DCTELEM * data);
typedef void (*float_DCT_method_ptr) (FAST_FLOAT * data);
typedef void (*forward_DCT_method_ptr) (DCTELEM *data);
typedef void (*float_DCT_method_ptr) (FAST_FLOAT *data);
typedef void (*convsamp_method_ptr) (JSAMPARRAY sample_data,
JDIMENSION start_col,
DCTELEM * workspace);
DCTELEM *workspace);
typedef void (*float_convsamp_method_ptr) (JSAMPARRAY sample_data,
JDIMENSION start_col,
FAST_FLOAT *workspace);
typedef void (*quantize_method_ptr) (JCOEFPTR coef_block, DCTELEM * divisors,
DCTELEM * workspace);
typedef void (*quantize_method_ptr) (JCOEFPTR coef_block, DCTELEM *divisors,
DCTELEM *workspace);
typedef void (*float_quantize_method_ptr) (JCOEFPTR coef_block,
FAST_FLOAT * divisors,
FAST_FLOAT * workspace);
FAST_FLOAT *divisors,
FAST_FLOAT *workspace);
METHODDEF(void) quantize (JCOEFPTR, DCTELEM *, DCTELEM *);
@@ -55,22 +55,22 @@ typedef struct {
* entries, because of scaling (especially for an unnormalized DCT).
* Each table is given in normal array order.
*/
DCTELEM * divisors[NUM_QUANT_TBLS];
DCTELEM *divisors[NUM_QUANT_TBLS];
/* work area for FDCT subroutine */
DCTELEM * workspace;
DCTELEM *workspace;
#ifdef DCT_FLOAT_SUPPORTED
/* Same as above for the floating-point case. */
float_DCT_method_ptr float_dct;
float_convsamp_method_ptr float_convsamp;
float_quantize_method_ptr float_quantize;
FAST_FLOAT * float_divisors[NUM_QUANT_TBLS];
FAST_FLOAT * float_workspace;
FAST_FLOAT *float_divisors[NUM_QUANT_TBLS];
FAST_FLOAT *float_workspace;
#endif
} my_fdct_controller;
typedef my_fdct_controller * my_fdct_ptr;
typedef my_fdct_controller *my_fdct_ptr;
#if BITS_IN_JSAMPLE == 8
@@ -170,7 +170,7 @@ flss (UINT16 val)
*/
LOCAL(int)
compute_reciprocal (UINT16 divisor, DCTELEM * dtbl)
compute_reciprocal (UINT16 divisor, DCTELEM *dtbl)
{
UDCTELEM2 fq, fr;
UDCTELEM c;
@@ -238,8 +238,8 @@ start_pass_fdctmgr (j_compress_ptr cinfo)
my_fdct_ptr fdct = (my_fdct_ptr) cinfo->fdct;
int ci, qtblno, i;
jpeg_component_info *compptr;
JQUANT_TBL * qtbl;
DCTELEM * dtbl;
JQUANT_TBL *qtbl;
DCTELEM *dtbl;
for (ci = 0, compptr = cinfo->comp_info; ci < cinfo->num_components;
ci++, compptr++) {
@@ -332,7 +332,7 @@ start_pass_fdctmgr (j_compress_ptr cinfo)
* What's actually stored is 1/divisor so that the inner loop can
* use a multiplication rather than a division.
*/
FAST_FLOAT * fdtbl;
FAST_FLOAT *fdtbl;
int row, col;
static const double aanscalefactor[DCTSIZE] = {
1.0, 1.387039845, 1.306562965, 1.175875602,
@@ -370,7 +370,7 @@ start_pass_fdctmgr (j_compress_ptr cinfo)
*/
METHODDEF(void)
convsamp (JSAMPARRAY sample_data, JDIMENSION start_col, DCTELEM * workspace)
convsamp (JSAMPARRAY sample_data, JDIMENSION start_col, DCTELEM *workspace)
{
register DCTELEM *workspaceptr;
register JSAMPROW elemptr;
@@ -405,7 +405,7 @@ convsamp (JSAMPARRAY sample_data, JDIMENSION start_col, DCTELEM * workspace)
*/
METHODDEF(void)
quantize (JCOEFPTR coef_block, DCTELEM * divisors, DCTELEM * workspace)
quantize (JCOEFPTR coef_block, DCTELEM *divisors, DCTELEM *workspace)
{
int i;
DCTELEM temp;
@@ -487,7 +487,7 @@ quantize (JCOEFPTR coef_block, DCTELEM * divisors, DCTELEM * workspace)
*/
METHODDEF(void)
forward_DCT (j_compress_ptr cinfo, jpeg_component_info * compptr,
forward_DCT (j_compress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY sample_data, JBLOCKROW coef_blocks,
JDIMENSION start_row, JDIMENSION start_col,
JDIMENSION num_blocks)
@@ -495,8 +495,8 @@ forward_DCT (j_compress_ptr cinfo, jpeg_component_info * compptr,
{
/* This routine is heavily used, so it's worth coding it tightly. */
my_fdct_ptr fdct = (my_fdct_ptr) cinfo->fdct;
DCTELEM * divisors = fdct->divisors[compptr->quant_tbl_no];
DCTELEM * workspace;
DCTELEM *divisors = fdct->divisors[compptr->quant_tbl_no];
DCTELEM *workspace;
JDIMENSION bi;
/* Make sure the compiler doesn't look up these every pass */
@@ -524,7 +524,7 @@ forward_DCT (j_compress_ptr cinfo, jpeg_component_info * compptr,
METHODDEF(void)
convsamp_float (JSAMPARRAY sample_data, JDIMENSION start_col, FAST_FLOAT * workspace)
convsamp_float (JSAMPARRAY sample_data, JDIMENSION start_col, FAST_FLOAT *workspace)
{
register FAST_FLOAT *workspaceptr;
register JSAMPROW elemptr;
@@ -555,7 +555,7 @@ convsamp_float (JSAMPARRAY sample_data, JDIMENSION start_col, FAST_FLOAT * works
METHODDEF(void)
quantize_float (JCOEFPTR coef_block, FAST_FLOAT * divisors, FAST_FLOAT * workspace)
quantize_float (JCOEFPTR coef_block, FAST_FLOAT *divisors, FAST_FLOAT *workspace)
{
register FAST_FLOAT temp;
register int i;
@@ -577,7 +577,7 @@ quantize_float (JCOEFPTR coef_block, FAST_FLOAT * divisors, FAST_FLOAT * workspa
METHODDEF(void)
forward_DCT_float (j_compress_ptr cinfo, jpeg_component_info * compptr,
forward_DCT_float (j_compress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY sample_data, JBLOCKROW coef_blocks,
JDIMENSION start_row, JDIMENSION start_col,
JDIMENSION num_blocks)
@@ -585,8 +585,8 @@ forward_DCT_float (j_compress_ptr cinfo, jpeg_component_info * compptr,
{
/* This routine is heavily used, so it's worth coding it tightly. */
my_fdct_ptr fdct = (my_fdct_ptr) cinfo->fdct;
FAST_FLOAT * divisors = fdct->float_divisors[compptr->quant_tbl_no];
FAST_FLOAT * workspace;
FAST_FLOAT *divisors = fdct->float_divisors[compptr->quant_tbl_no];
FAST_FLOAT *workspace;
JDIMENSION bi;

View File

@@ -102,25 +102,25 @@ typedef struct {
int next_restart_num; /* next restart number to write (0-7) */
/* Pointers to derived tables (these workspaces have image lifespan) */
c_derived_tbl * dc_derived_tbls[NUM_HUFF_TBLS];
c_derived_tbl * ac_derived_tbls[NUM_HUFF_TBLS];
c_derived_tbl *dc_derived_tbls[NUM_HUFF_TBLS];
c_derived_tbl *ac_derived_tbls[NUM_HUFF_TBLS];
#ifdef ENTROPY_OPT_SUPPORTED /* Statistics tables for optimization */
long * dc_count_ptrs[NUM_HUFF_TBLS];
long * ac_count_ptrs[NUM_HUFF_TBLS];
long *dc_count_ptrs[NUM_HUFF_TBLS];
long *ac_count_ptrs[NUM_HUFF_TBLS];
#endif
int simd;
} huff_entropy_encoder;
typedef huff_entropy_encoder * huff_entropy_ptr;
typedef huff_entropy_encoder *huff_entropy_ptr;
/* Working state while writing an MCU.
* This struct contains all the fields that are needed by subroutines.
*/
typedef struct {
JOCTET * next_output_byte; /* => next byte to write in buffer */
JOCTET *next_output_byte; /* => next byte to write in buffer */
size_t free_in_buffer; /* # of byte spaces remaining in buffer */
savable_state cur; /* Current bit buffer & DC state */
j_compress_ptr cinfo; /* dump_buffer needs access to this */
@@ -148,7 +148,7 @@ start_pass_huff (j_compress_ptr cinfo, boolean gather_statistics)
{
huff_entropy_ptr entropy = (huff_entropy_ptr) cinfo->entropy;
int ci, dctbl, actbl;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
if (gather_statistics) {
#ifdef ENTROPY_OPT_SUPPORTED
@@ -318,10 +318,10 @@ jpeg_make_c_derived_tbl (j_compress_ptr cinfo, boolean isDC, int tblno,
LOCAL(boolean)
dump_buffer (working_state * state)
dump_buffer (working_state *state)
/* Empty the output buffer; return TRUE if successful, FALSE if must suspend */
{
struct jpeg_destination_mgr * dest = state->cinfo->dest;
struct jpeg_destination_mgr *dest = state->cinfo->dest;
if (! (*dest->empty_output_buffer) (state->cinfo))
return FALSE;
@@ -461,7 +461,7 @@ dump_buffer (working_state * state)
LOCAL(boolean)
flush_bits (working_state * state)
flush_bits (working_state *state)
{
JOCTET _buffer[BUFSIZE], *buffer;
size_t put_buffer; int put_bits;
@@ -486,7 +486,7 @@ flush_bits (working_state * state)
/* Encode a single block's worth of coefficients */
LOCAL(boolean)
encode_one_block_simd (working_state * state, JCOEFPTR block, int last_dc_val,
encode_one_block_simd (working_state *state, JCOEFPTR block, int last_dc_val,
c_derived_tbl *dctbl, c_derived_tbl *actbl)
{
JOCTET _buffer[BUFSIZE], *buffer;
@@ -503,7 +503,7 @@ encode_one_block_simd (working_state * state, JCOEFPTR block, int last_dc_val,
}
LOCAL(boolean)
encode_one_block (working_state * state, JCOEFPTR block, int last_dc_val,
encode_one_block (working_state *state, JCOEFPTR block, int last_dc_val,
c_derived_tbl *dctbl, c_derived_tbl *actbl)
{
int temp, temp2, temp3;
@@ -616,7 +616,7 @@ encode_one_block (working_state * state, JCOEFPTR block, int last_dc_val,
*/
LOCAL(boolean)
emit_restart (working_state * state, int restart_num)
emit_restart (working_state *state, int restart_num)
{
int ci;
@@ -646,7 +646,7 @@ encode_mcu_huff (j_compress_ptr cinfo, JBLOCKROW *MCU_data)
huff_entropy_ptr entropy = (huff_entropy_ptr) cinfo->entropy;
working_state state;
int blkn, ci;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
/* Load up working state */
state.next_output_byte = cinfo->dest->next_output_byte;
@@ -828,7 +828,7 @@ encode_mcu_gather (j_compress_ptr cinfo, JBLOCKROW *MCU_data)
{
huff_entropy_ptr entropy = (huff_entropy_ptr) cinfo->entropy;
int blkn, ci;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
/* Take care of restart intervals if needed */
if (cinfo->restart_interval) {
@@ -884,7 +884,7 @@ encode_mcu_gather (j_compress_ptr cinfo, JBLOCKROW *MCU_data)
*/
GLOBAL(void)
jpeg_gen_optimal_table (j_compress_ptr cinfo, JHUFF_TBL * htbl, long freq[])
jpeg_gen_optimal_table (j_compress_ptr cinfo, JHUFF_TBL *htbl, long freq[])
{
#define MAX_CLEN 32 /* assumed maximum initial code length */
UINT8 bits[MAX_CLEN+1]; /* bits[k] = # of symbols with code length k */
@@ -1029,7 +1029,7 @@ finish_pass_gather (j_compress_ptr cinfo)
{
huff_entropy_ptr entropy = (huff_entropy_ptr) cinfo->entropy;
int ci, dctbl, actbl;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
JHUFF_TBL **htblptr;
boolean did_dc[NUM_HUFF_TBLS];
boolean did_ac[NUM_HUFF_TBLS];

View File

@@ -40,4 +40,4 @@ EXTERN(void) jpeg_make_c_derived_tbl
/* Generate an optimal table definition given the specified counts */
EXTERN(void) jpeg_gen_optimal_table
(j_compress_ptr cinfo, JHUFF_TBL * htbl, long freq[]);
(j_compress_ptr cinfo, JHUFF_TBL *htbl, long freq[]);

View File

@@ -35,7 +35,7 @@ typedef struct {
JSAMPARRAY buffer[MAX_COMPONENTS];
} my_main_controller;
typedef my_main_controller * my_main_ptr;
typedef my_main_controller *my_main_ptr;
/* Forward declarations */

View File

@@ -94,7 +94,7 @@ typedef struct {
unsigned int last_restart_interval; /* last DRI value emitted; 0 after SOI */
} my_marker_writer;
typedef my_marker_writer * my_marker_ptr;
typedef my_marker_writer *my_marker_ptr;
/*
@@ -113,7 +113,7 @@ LOCAL(void)
emit_byte (j_compress_ptr cinfo, int val)
/* Emit a byte */
{
struct jpeg_destination_mgr * dest = cinfo->dest;
struct jpeg_destination_mgr *dest = cinfo->dest;
*(dest->next_output_byte)++ = (JOCTET) val;
if (--dest->free_in_buffer == 0) {
@@ -150,7 +150,7 @@ emit_dqt (j_compress_ptr cinfo, int index)
/* Emit a DQT marker */
/* Returns the precision used (0 = 8bits, 1 = 16bits) for baseline checking */
{
JQUANT_TBL * qtbl = cinfo->quant_tbl_ptrs[index];
JQUANT_TBL *qtbl = cinfo->quant_tbl_ptrs[index];
int prec;
int i;
@@ -189,7 +189,7 @@ LOCAL(void)
emit_dht (j_compress_ptr cinfo, int index, boolean is_ac)
/* Emit a DHT marker */
{
JHUFF_TBL * htbl;
JHUFF_TBL *htbl;
int length, i;
if (is_ac) {

View File

@@ -40,7 +40,7 @@ typedef struct {
int scan_number; /* current index in scan_info[] */
} my_comp_master;
typedef my_comp_master * my_master_ptr;
typedef my_comp_master *my_master_ptr;
/*
@@ -168,12 +168,12 @@ validate_script (j_compress_ptr cinfo)
* determine whether it uses progressive JPEG, and set cinfo->progressive_mode.
*/
{
const jpeg_scan_info * scanptr;
const jpeg_scan_info *scanptr;
int scanno, ncomps, ci, coefi, thisi;
int Ss, Se, Ah, Al;
boolean component_sent[MAX_COMPONENTS];
#ifdef C_PROGRESSIVE_SUPPORTED
int * last_bitpos_ptr;
int *last_bitpos_ptr;
int last_bitpos[MAX_COMPONENTS][DCTSIZE2];
/* -1 until that coefficient has been seen; then last Al for it */
#endif
@@ -309,7 +309,7 @@ select_scan_parameters (j_compress_ptr cinfo)
if (cinfo->scan_info != NULL) {
/* Prepare for current scan --- the script is already validated */
my_master_ptr master = (my_master_ptr) cinfo->master;
const jpeg_scan_info * scanptr = cinfo->scan_info + master->scan_number;
const jpeg_scan_info *scanptr = cinfo->scan_info + master->scan_number;
cinfo->comps_in_scan = scanptr->comps_in_scan;
for (ci = 0; ci < scanptr->comps_in_scan; ci++) {

View File

@@ -322,7 +322,7 @@ jpeg_default_colorspace (j_compress_ptr cinfo)
GLOBAL(void)
jpeg_set_colorspace (j_compress_ptr cinfo, J_COLOR_SPACE colorspace)
{
jpeg_component_info * compptr;
jpeg_component_info *compptr;
int ci;
#define SET_COMP(index,id,hsamp,vsamp,quant,dctbl,actbl) \
@@ -404,7 +404,7 @@ jpeg_set_colorspace (j_compress_ptr cinfo, J_COLOR_SPACE colorspace)
#ifdef C_PROGRESSIVE_SUPPORTED
LOCAL(jpeg_scan_info *)
fill_a_scan (jpeg_scan_info * scanptr, int ci,
fill_a_scan (jpeg_scan_info *scanptr, int ci,
int Ss, int Se, int Ah, int Al)
/* Support routine: generate one scan for specified component */
{
@@ -419,7 +419,7 @@ fill_a_scan (jpeg_scan_info * scanptr, int ci,
}
LOCAL(jpeg_scan_info *)
fill_scans (jpeg_scan_info * scanptr, int ncomps,
fill_scans (jpeg_scan_info *scanptr, int ncomps,
int Ss, int Se, int Ah, int Al)
/* Support routine: generate one scan for each component */
{
@@ -438,7 +438,7 @@ fill_scans (jpeg_scan_info * scanptr, int ncomps,
}
LOCAL(jpeg_scan_info *)
fill_dc_scans (jpeg_scan_info * scanptr, int ncomps, int Ah, int Al)
fill_dc_scans (jpeg_scan_info *scanptr, int ncomps, int Ah, int Al)
/* Support routine: generate interleaved DC scan if possible, else N scans */
{
int ci;
@@ -470,7 +470,7 @@ jpeg_simple_progression (j_compress_ptr cinfo)
{
int ncomps = cinfo->num_components;
int nscans;
jpeg_scan_info * scanptr;
jpeg_scan_info *scanptr;
/* Safety check to ensure start_compress not called yet. */
if (cinfo->global_state != CSTATE_START)

View File

@@ -33,7 +33,7 @@ typedef struct {
/* Bit-level coding status.
* next_output_byte/free_in_buffer are local copies of cinfo->dest fields.
*/
JOCTET * next_output_byte; /* => next byte to write in buffer */
JOCTET *next_output_byte; /* => next byte to write in buffer */
size_t free_in_buffer; /* # of byte spaces remaining in buffer */
size_t put_buffer; /* current bit-accumulation buffer */
int put_bits; /* # of bits now in it */
@@ -46,7 +46,7 @@ typedef struct {
int ac_tbl_no; /* the table number of the single component */
unsigned int EOBRUN; /* run length of EOBs */
unsigned int BE; /* # of buffered correction bits before MCU */
char * bit_buffer; /* buffer for correction bits (1 per char) */
char *bit_buffer; /* buffer for correction bits (1 per char) */
/* packing correction bits tightly would save some space but cost time... */
unsigned int restarts_to_go; /* MCUs left in this restart interval */
@@ -56,13 +56,13 @@ typedef struct {
* Since any one scan codes only DC or only AC, we only need one set
* of tables, not one for DC and one for AC.
*/
c_derived_tbl * derived_tbls[NUM_HUFF_TBLS];
c_derived_tbl *derived_tbls[NUM_HUFF_TBLS];
/* Statistics tables for optimization; again, one set is enough */
long * count_ptrs[NUM_HUFF_TBLS];
long *count_ptrs[NUM_HUFF_TBLS];
} phuff_entropy_encoder;
typedef phuff_entropy_encoder * phuff_entropy_ptr;
typedef phuff_entropy_encoder *phuff_entropy_ptr;
/* MAX_CORR_BITS is the number of bits the AC refinement correction-bit
* buffer can hold. Larger sizes may slightly improve compression, but
@@ -111,7 +111,7 @@ start_pass_phuff (j_compress_ptr cinfo, boolean gather_statistics)
phuff_entropy_ptr entropy = (phuff_entropy_ptr) cinfo->entropy;
boolean is_DC_band;
int ci, tbl;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
entropy->cinfo = cinfo;
entropy->gather_statistics = gather_statistics;
@@ -208,7 +208,7 @@ LOCAL(void)
dump_buffer (phuff_entropy_ptr entropy)
/* Empty the output buffer; we do not support suspension in this module. */
{
struct jpeg_destination_mgr * dest = entropy->cinfo->dest;
struct jpeg_destination_mgr *dest = entropy->cinfo->dest;
if (! (*dest->empty_output_buffer) (entropy->cinfo))
ERREXIT(entropy->cinfo, JERR_CANT_SUSPEND);
@@ -284,7 +284,7 @@ emit_symbol (phuff_entropy_ptr entropy, int tbl_no, int symbol)
if (entropy->gather_statistics)
entropy->count_ptrs[tbl_no][symbol]++;
else {
c_derived_tbl * tbl = entropy->derived_tbls[tbl_no];
c_derived_tbl *tbl = entropy->derived_tbls[tbl_no];
emit_bits(entropy, tbl->ehufco[symbol], tbl->ehufsi[symbol]);
}
}
@@ -295,7 +295,7 @@ emit_symbol (phuff_entropy_ptr entropy, int tbl_no, int symbol)
*/
LOCAL(void)
emit_buffered_bits (phuff_entropy_ptr entropy, char * bufstart,
emit_buffered_bits (phuff_entropy_ptr entropy, char *bufstart,
unsigned int nbits)
{
if (entropy->gather_statistics)
@@ -383,7 +383,7 @@ encode_mcu_DC_first (j_compress_ptr cinfo, JBLOCKROW *MCU_data)
int blkn, ci;
int Al = cinfo->Al;
JBLOCKROW block;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
ISHIFT_TEMPS
entropy->next_output_byte = cinfo->dest->next_output_byte;
@@ -770,7 +770,7 @@ finish_pass_gather_phuff (j_compress_ptr cinfo)
phuff_entropy_ptr entropy = (phuff_entropy_ptr) cinfo->entropy;
boolean is_DC_band;
int ci, tbl;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
JHUFF_TBL **htblptr;
boolean did[NUM_HUFF_TBLS];

View File

@@ -70,7 +70,7 @@ typedef struct {
#endif
} my_prep_controller;
typedef my_prep_controller * my_prep_ptr;
typedef my_prep_controller *my_prep_ptr;
/*
@@ -137,7 +137,7 @@ pre_process_data (j_compress_ptr cinfo,
my_prep_ptr prep = (my_prep_ptr) cinfo->prep;
int numrows, ci;
JDIMENSION inrows;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
while (*in_row_ctr < in_rows_avail &&
*out_row_group_ctr < out_row_groups_avail) {
@@ -272,7 +272,7 @@ create_context_buffer (j_compress_ptr cinfo)
my_prep_ptr prep = (my_prep_ptr) cinfo->prep;
int rgroup_height = cinfo->max_v_samp_factor;
int ci, i;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
JSAMPARRAY true_buffer, fake_buffer;
/* Grab enough space for fake row pointers for all the components;
@@ -319,7 +319,7 @@ jinit_c_prep_controller (j_compress_ptr cinfo, boolean need_full_buffer)
{
my_prep_ptr prep;
int ci;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
if (need_full_buffer) /* safety check */
ERREXIT(cinfo, JERR_BAD_BUFFER_MODE);

View File

@@ -58,7 +58,7 @@
/* Pointer to routine to downsample a single component */
typedef void (*downsample1_ptr) (j_compress_ptr cinfo,
jpeg_component_info * compptr,
jpeg_component_info *compptr,
JSAMPARRAY input_data,
JSAMPARRAY output_data);
@@ -71,7 +71,7 @@ typedef struct {
downsample1_ptr methods[MAX_COMPONENTS];
} my_downsampler;
typedef my_downsampler * my_downsample_ptr;
typedef my_downsampler *my_downsample_ptr;
/*
@@ -124,7 +124,7 @@ sep_downsample (j_compress_ptr cinfo,
{
my_downsample_ptr downsample = (my_downsample_ptr) cinfo->downsample;
int ci;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
JSAMPARRAY in_ptr, out_ptr;
for (ci = 0, compptr = cinfo->comp_info; ci < cinfo->num_components;
@@ -144,7 +144,7 @@ sep_downsample (j_compress_ptr cinfo,
*/
METHODDEF(void)
int_downsample (j_compress_ptr cinfo, jpeg_component_info * compptr,
int_downsample (j_compress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY output_data)
{
int inrow, outrow, h_expand, v_expand, numpix, numpix2, h, v;
@@ -191,7 +191,7 @@ int_downsample (j_compress_ptr cinfo, jpeg_component_info * compptr,
*/
METHODDEF(void)
fullsize_downsample (j_compress_ptr cinfo, jpeg_component_info * compptr,
fullsize_downsample (j_compress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY output_data)
{
/* Copy the data */
@@ -216,7 +216,7 @@ fullsize_downsample (j_compress_ptr cinfo, jpeg_component_info * compptr,
*/
METHODDEF(void)
h2v1_downsample (j_compress_ptr cinfo, jpeg_component_info * compptr,
h2v1_downsample (j_compress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY output_data)
{
int outrow;
@@ -253,7 +253,7 @@ h2v1_downsample (j_compress_ptr cinfo, jpeg_component_info * compptr,
*/
METHODDEF(void)
h2v2_downsample (j_compress_ptr cinfo, jpeg_component_info * compptr,
h2v2_downsample (j_compress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY output_data)
{
int inrow, outrow;
@@ -296,7 +296,7 @@ h2v2_downsample (j_compress_ptr cinfo, jpeg_component_info * compptr,
*/
METHODDEF(void)
h2v2_smooth_downsample (j_compress_ptr cinfo, jpeg_component_info * compptr,
h2v2_smooth_downsample (j_compress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY output_data)
{
int inrow, outrow;
@@ -472,7 +472,7 @@ jinit_downsampler (j_compress_ptr cinfo)
{
my_downsample_ptr downsample;
int ci;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
boolean smoothok = TRUE;
downsample = (my_downsample_ptr)

View File

@@ -21,9 +21,9 @@
/* Forward declarations */
LOCAL(void) transencode_master_selection
(j_compress_ptr cinfo, jvirt_barray_ptr * coef_arrays);
(j_compress_ptr cinfo, jvirt_barray_ptr *coef_arrays);
LOCAL(void) transencode_coef_controller
(j_compress_ptr cinfo, jvirt_barray_ptr * coef_arrays);
(j_compress_ptr cinfo, jvirt_barray_ptr *coef_arrays);
/*
@@ -39,7 +39,7 @@ LOCAL(void) transencode_coef_controller
*/
GLOBAL(void)
jpeg_write_coefficients (j_compress_ptr cinfo, jvirt_barray_ptr * coef_arrays)
jpeg_write_coefficients (j_compress_ptr cinfo, jvirt_barray_ptr *coef_arrays)
{
if (cinfo->global_state != CSTATE_START)
ERREXIT1(cinfo, JERR_BAD_STATE, cinfo->global_state);
@@ -166,7 +166,7 @@ jpeg_copy_critical_parameters (j_decompress_ptr srcinfo,
LOCAL(void)
transencode_master_selection (j_compress_ptr cinfo,
jvirt_barray_ptr * coef_arrays)
jvirt_barray_ptr *coef_arrays)
{
/* Although we don't actually use input_components for transcoding,
* jcmaster.c's initial_setup will complain if input_components is 0.
@@ -228,13 +228,13 @@ typedef struct {
int MCU_rows_per_iMCU_row; /* number of such rows needed */
/* Virtual block array for each component. */
jvirt_barray_ptr * whole_image;
jvirt_barray_ptr *whole_image;
/* Workspace for constructing dummy blocks at right/bottom edges. */
JBLOCKROW dummy_buffer[C_MAX_BLOCKS_IN_MCU];
} my_coef_controller;
typedef my_coef_controller * my_coef_ptr;
typedef my_coef_controller *my_coef_ptr;
LOCAL(void)
@@ -375,7 +375,7 @@ compress_output (j_compress_ptr cinfo, JSAMPIMAGE input_buf)
LOCAL(void)
transencode_coef_controller (j_compress_ptr cinfo,
jvirt_barray_ptr * coef_arrays)
jvirt_barray_ptr *coef_arrays)
{
my_coef_ptr coef;
JBLOCKROW buffer;

View File

@@ -38,14 +38,14 @@ typedef struct {
unsigned int restarts_to_go; /* MCUs left in this restart interval */
/* Pointers to statistics areas (these workspaces have image lifespan) */
unsigned char * dc_stats[NUM_ARITH_TBLS];
unsigned char * ac_stats[NUM_ARITH_TBLS];
unsigned char *dc_stats[NUM_ARITH_TBLS];
unsigned char *ac_stats[NUM_ARITH_TBLS];
/* Statistics bin for coding with fixed probability 0.5 */
unsigned char fixed_bin[4];
} arith_entropy_decoder;
typedef arith_entropy_decoder * arith_entropy_ptr;
typedef arith_entropy_decoder *arith_entropy_ptr;
/* The following two definitions specify the allocation chunk size
* for the statistics area.
@@ -68,7 +68,7 @@ LOCAL(int)
get_byte (j_decompress_ptr cinfo)
/* Read next input byte; we do not support suspension in this module. */
{
struct jpeg_source_mgr * src = cinfo->src;
struct jpeg_source_mgr *src = cinfo->src;
if (src->bytes_in_buffer == 0)
if (! (*src->fill_input_buffer) (cinfo))
@@ -194,7 +194,7 @@ process_restart (j_decompress_ptr cinfo)
{
arith_entropy_ptr entropy = (arith_entropy_ptr) cinfo->entropy;
int ci;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
/* Advance past the RSTn marker */
if (! (*cinfo->marker->read_restart_marker) (cinfo))
@@ -499,7 +499,7 @@ METHODDEF(boolean)
decode_mcu (j_decompress_ptr cinfo, JBLOCKROW *MCU_data)
{
arith_entropy_ptr entropy = (arith_entropy_ptr) cinfo->entropy;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
JBLOCKROW block;
unsigned char *st;
int blkn, ci, tbl, sign, k;
@@ -627,7 +627,7 @@ start_pass (j_decompress_ptr cinfo)
{
arith_entropy_ptr entropy = (arith_entropy_ptr) cinfo->entropy;
int ci, tbl;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
if (cinfo->progressive_mode) {
/* Validate progressive scan parameters */

View File

@@ -24,7 +24,7 @@
#include "jerror.h"
#ifndef HAVE_STDLIB_H /* <stdlib.h> should declare malloc(),free() */
extern void * malloc (size_t size);
extern void *malloc (size_t size);
extern void free (void *ptr);
#endif
@@ -37,15 +37,15 @@ extern void free (void *ptr);
typedef struct {
struct jpeg_destination_mgr pub; /* public fields */
unsigned char ** outbuffer; /* target buffer */
unsigned long * outsize;
unsigned char * newbuffer; /* newly allocated buffer */
JOCTET * buffer; /* start of buffer */
unsigned char **outbuffer; /* target buffer */
unsigned long *outsize;
unsigned char *newbuffer; /* newly allocated buffer */
JOCTET *buffer; /* start of buffer */
size_t bufsize;
boolean alloc;
} my_mem_destination_mgr;
typedef my_mem_destination_mgr * my_mem_dest_ptr;
typedef my_mem_destination_mgr *my_mem_dest_ptr;
/*
@@ -87,7 +87,7 @@ METHODDEF(boolean)
empty_mem_output_buffer (j_compress_ptr cinfo)
{
size_t nextsize;
JOCTET * nextbuffer;
JOCTET *nextbuffer;
my_mem_dest_ptr dest = (my_mem_dest_ptr) cinfo->dest;
if (!dest->alloc) ERREXIT(cinfo, JERR_BUFFER_SIZE);
@@ -148,7 +148,7 @@ term_mem_destination (j_compress_ptr cinfo)
GLOBAL(void)
jpeg_mem_dest_tj (j_compress_ptr cinfo,
unsigned char ** outbuffer, unsigned long * outsize,
unsigned char **outbuffer, unsigned long *outsize,
boolean alloc)
{
boolean reused = FALSE;

View File

@@ -24,7 +24,7 @@
#include "jerror.h"
#ifndef HAVE_STDLIB_H /* <stdlib.h> should declare malloc(),free() */
extern void * malloc (size_t size);
extern void *malloc (size_t size);
extern void free (void *ptr);
#endif
@@ -34,11 +34,11 @@ extern void free (void *ptr);
typedef struct {
struct jpeg_destination_mgr pub; /* public fields */
FILE * outfile; /* target stream */
JOCTET * buffer; /* start of buffer */
FILE *outfile; /* target stream */
JOCTET *buffer; /* start of buffer */
} my_destination_mgr;
typedef my_destination_mgr * my_dest_ptr;
typedef my_destination_mgr *my_dest_ptr;
#define OUTPUT_BUF_SIZE 4096 /* choose an efficiently fwrite'able size */
@@ -49,14 +49,14 @@ typedef my_destination_mgr * my_dest_ptr;
typedef struct {
struct jpeg_destination_mgr pub; /* public fields */
unsigned char ** outbuffer; /* target buffer */
unsigned long * outsize;
unsigned char * newbuffer; /* newly allocated buffer */
JOCTET * buffer; /* start of buffer */
unsigned char **outbuffer; /* target buffer */
unsigned long *outsize;
unsigned char *newbuffer; /* newly allocated buffer */
JOCTET *buffer; /* start of buffer */
size_t bufsize;
} my_mem_destination_mgr;
typedef my_mem_destination_mgr * my_mem_dest_ptr;
typedef my_mem_destination_mgr *my_mem_dest_ptr;
#endif
@@ -131,7 +131,7 @@ METHODDEF(boolean)
empty_mem_output_buffer (j_compress_ptr cinfo)
{
size_t nextsize;
JOCTET * nextbuffer;
JOCTET *nextbuffer;
my_mem_dest_ptr dest = (my_mem_dest_ptr) cinfo->dest;
/* Try to allocate new buffer with double size */
@@ -204,7 +204,7 @@ term_mem_destination (j_compress_ptr cinfo)
*/
GLOBAL(void)
jpeg_stdio_dest (j_compress_ptr cinfo, FILE * outfile)
jpeg_stdio_dest (j_compress_ptr cinfo, FILE *outfile)
{
my_dest_ptr dest;
@@ -245,7 +245,7 @@ jpeg_stdio_dest (j_compress_ptr cinfo, FILE * outfile)
GLOBAL(void)
jpeg_mem_dest (j_compress_ptr cinfo,
unsigned char ** outbuffer, unsigned long * outsize)
unsigned char **outbuffer, unsigned long *outsize)
{
my_mem_dest_ptr dest;

View File

@@ -106,7 +106,7 @@ fill_mem_input_buffer (j_decompress_ptr cinfo)
METHODDEF(void)
skip_input_data (j_decompress_ptr cinfo, long num_bytes)
{
struct jpeg_source_mgr * src = cinfo->src;
struct jpeg_source_mgr *src = cinfo->src;
/* Just a dumb implementation for now. Could use fseek() except
* it doesn't work on pipes. Not clear that being smart is worth
@@ -158,9 +158,9 @@ term_source (j_decompress_ptr cinfo)
GLOBAL(void)
jpeg_mem_src_tj (j_decompress_ptr cinfo,
const unsigned char * inbuffer, unsigned long insize)
const unsigned char *inbuffer, unsigned long insize)
{
struct jpeg_source_mgr * src;
struct jpeg_source_mgr *src;
if (inbuffer == NULL || insize == 0) /* Treat empty input as fatal error */
ERREXIT(cinfo, JERR_INPUT_EMPTY);

View File

@@ -29,12 +29,12 @@
typedef struct {
struct jpeg_source_mgr pub; /* public fields */
FILE * infile; /* source stream */
JOCTET * buffer; /* start of buffer */
FILE *infile; /* source stream */
JOCTET *buffer; /* start of buffer */
boolean start_of_file; /* have we gotten any data yet? */
} my_source_mgr;
typedef my_source_mgr * my_src_ptr;
typedef my_source_mgr *my_src_ptr;
#define INPUT_BUF_SIZE 4096 /* choose an efficiently fread'able size */
@@ -162,7 +162,7 @@ fill_mem_input_buffer (j_decompress_ptr cinfo)
METHODDEF(void)
skip_input_data (j_decompress_ptr cinfo, long num_bytes)
{
struct jpeg_source_mgr * src = cinfo->src;
struct jpeg_source_mgr *src = cinfo->src;
/* Just a dumb implementation for now. Could use fseek() except
* it doesn't work on pipes. Not clear that being smart is worth
@@ -214,7 +214,7 @@ term_source (j_decompress_ptr cinfo)
*/
GLOBAL(void)
jpeg_stdio_src (j_decompress_ptr cinfo, FILE * infile)
jpeg_stdio_src (j_decompress_ptr cinfo, FILE *infile)
{
my_src_ptr src;
@@ -255,9 +255,9 @@ jpeg_stdio_src (j_decompress_ptr cinfo, FILE * infile)
GLOBAL(void)
jpeg_mem_src (j_decompress_ptr cinfo,
const unsigned char * inbuffer, unsigned long insize)
const unsigned char *inbuffer, unsigned long insize)
{
struct jpeg_source_mgr * src;
struct jpeg_source_mgr *src;
if (inbuffer == NULL || insize == 0) /* Treat empty input as fatal error */
ERREXIT(cinfo, JERR_INPUT_EMPTY);

View File

@@ -346,9 +346,9 @@ smoothing_ok (j_decompress_ptr cinfo)
boolean smoothing_useful = FALSE;
int ci, coefi;
jpeg_component_info *compptr;
JQUANT_TBL * qtable;
int * coef_bits;
int * coef_bits_latch;
JQUANT_TBL *qtable;
int *coef_bits;
int *coef_bits_latch;
if (! cinfo->progressive_mode || cinfo->coef_bits == NULL)
return FALSE;
@@ -409,7 +409,7 @@ decompress_smooth_data (j_decompress_ptr cinfo, JSAMPIMAGE output_buf)
jpeg_component_info *compptr;
inverse_DCT_method_ptr inverse_DCT;
boolean first_row, last_row;
JCOEF * workspace;
JCOEF *workspace;
int *coef_bits;
JQUANT_TBL *quanttbl;
JLONG Q00,Q01,Q02,Q10,Q11,Q20, num;

View File

@@ -41,7 +41,7 @@ typedef struct {
JBLOCKROW MCU_buffer[D_MAX_BLOCKS_IN_MCU];
/* Temporary workspace for one MCU */
JCOEF * workspace;
JCOEF *workspace;
#ifdef D_MULTISCAN_FILES_SUPPORTED
/* In multi-pass modes, we need a virtual block array for each component. */
@@ -50,12 +50,12 @@ typedef struct {
#ifdef BLOCK_SMOOTHING_SUPPORTED
/* When doing block smoothing, we latch coefficient Al values here */
int * coef_bits_latch;
int *coef_bits_latch;
#define SAVED_COEFS 6 /* we save coef_bits[0..5] */
#endif
} my_coef_controller;
typedef my_coef_controller * my_coef_ptr;
typedef my_coef_controller *my_coef_ptr;
LOCAL(void)

View File

@@ -27,16 +27,16 @@ typedef struct {
struct jpeg_color_deconverter pub; /* public fields */
/* Private state for YCC->RGB conversion */
int * Cr_r_tab; /* => table for Cr to R conversion */
int * Cb_b_tab; /* => table for Cb to B conversion */
JLONG * Cr_g_tab; /* => table for Cr to G conversion */
JLONG * Cb_g_tab; /* => table for Cb to G conversion */
int *Cr_r_tab; /* => table for Cr to R conversion */
int *Cb_b_tab; /* => table for Cb to B conversion */
JLONG *Cr_g_tab; /* => table for Cr to G conversion */
JLONG *Cb_g_tab; /* => table for Cb to G conversion */
/* Private state for RGB->Y conversion */
JLONG * rgb_y_tab; /* => table for RGB to Y conversion */
JLONG *rgb_y_tab; /* => table for RGB to Y conversion */
} my_color_deconverter;
typedef my_color_deconverter * my_cconvert_ptr;
typedef my_color_deconverter *my_cconvert_ptr;
/**************** YCbCr -> RGB conversion: most common case **************/
@@ -303,7 +303,7 @@ LOCAL(void)
build_rgb_y_table (j_decompress_ptr cinfo)
{
my_cconvert_ptr cconvert = (my_cconvert_ptr) cinfo->cconvert;
JLONG * rgb_y_tab;
JLONG *rgb_y_tab;
JLONG i;
/* Allocate and fill in the conversion tables. */
@@ -330,7 +330,7 @@ rgb_gray_convert (j_decompress_ptr cinfo,
{
my_cconvert_ptr cconvert = (my_cconvert_ptr) cinfo->cconvert;
register int r, g, b;
register JLONG * ctab = cconvert->rgb_y_tab;
register JLONG *ctab = cconvert->rgb_y_tab;
register JSAMPROW outptr;
register JSAMPROW inptr0, inptr1, inptr2;
register JDIMENSION col;
@@ -543,11 +543,11 @@ ycck_cmyk_convert (j_decompress_ptr cinfo,
register JDIMENSION col;
JDIMENSION num_cols = cinfo->output_width;
/* copy these pointers into registers if possible */
register JSAMPLE * range_limit = cinfo->sample_range_limit;
register int * Crrtab = cconvert->Cr_r_tab;
register int * Cbbtab = cconvert->Cb_b_tab;
register JLONG * Crgtab = cconvert->Cr_g_tab;
register JLONG * Cbgtab = cconvert->Cb_g_tab;
register JSAMPLE *range_limit = cinfo->sample_range_limit;
register int *Crrtab = cconvert->Cr_r_tab;
register int *Cbbtab = cconvert->Cb_b_tab;
register JLONG *Crgtab = cconvert->Cr_g_tab;
register JLONG *Cbgtab = cconvert->Cb_g_tab;
SHIFT_TEMPS
while (--num_rows >= 0) {

42
jdct.h
View File

@@ -90,63 +90,63 @@ typedef FAST_FLOAT FLOAT_MULT_TYPE; /* preferred floating type */
/* Extern declarations for the forward and inverse DCT routines. */
EXTERN(void) jpeg_fdct_islow (DCTELEM * data);
EXTERN(void) jpeg_fdct_ifast (DCTELEM * data);
EXTERN(void) jpeg_fdct_float (FAST_FLOAT * data);
EXTERN(void) jpeg_fdct_islow (DCTELEM *data);
EXTERN(void) jpeg_fdct_ifast (DCTELEM *data);
EXTERN(void) jpeg_fdct_float (FAST_FLOAT *data);
EXTERN(void) jpeg_idct_islow
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col);
EXTERN(void) jpeg_idct_ifast
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col);
EXTERN(void) jpeg_idct_float
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col);
EXTERN(void) jpeg_idct_7x7
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col);
EXTERN(void) jpeg_idct_6x6
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col);
EXTERN(void) jpeg_idct_5x5
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col);
EXTERN(void) jpeg_idct_4x4
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col);
EXTERN(void) jpeg_idct_3x3
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col);
EXTERN(void) jpeg_idct_2x2
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col);
EXTERN(void) jpeg_idct_1x1
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col);
EXTERN(void) jpeg_idct_9x9
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col);
EXTERN(void) jpeg_idct_10x10
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col);
EXTERN(void) jpeg_idct_11x11
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col);
EXTERN(void) jpeg_idct_12x12
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col);
EXTERN(void) jpeg_idct_13x13
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col);
EXTERN(void) jpeg_idct_14x14
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col);
EXTERN(void) jpeg_idct_15x15
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col);
EXTERN(void) jpeg_idct_16x16
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf, JDIMENSION output_col);

View File

@@ -59,7 +59,7 @@ typedef struct {
int cur_method[MAX_COMPONENTS];
} my_idct_controller;
typedef my_idct_controller * my_idct_ptr;
typedef my_idct_controller *my_idct_ptr;
/* Allocated multiplier tables: big enough for any supported variant */
@@ -101,7 +101,7 @@ start_pass (j_decompress_ptr cinfo)
jpeg_component_info *compptr;
int method = 0;
inverse_DCT_method_ptr method_ptr = NULL;
JQUANT_TBL * qtbl;
JQUANT_TBL *qtbl;
for (ci = 0, compptr = cinfo->comp_info; ci < cinfo->num_components;
ci++, compptr++) {
@@ -246,7 +246,7 @@ start_pass (j_decompress_ptr cinfo)
/* For LL&M IDCT method, multipliers are equal to raw quantization
* coefficients, but are stored as ints to ensure access efficiency.
*/
ISLOW_MULT_TYPE * ismtbl = (ISLOW_MULT_TYPE *) compptr->dct_table;
ISLOW_MULT_TYPE *ismtbl = (ISLOW_MULT_TYPE *) compptr->dct_table;
for (i = 0; i < DCTSIZE2; i++) {
ismtbl[i] = (ISLOW_MULT_TYPE) qtbl->quantval[i];
}
@@ -263,7 +263,7 @@ start_pass (j_decompress_ptr cinfo)
* For integer operation, the multiplier table is to be scaled by
* IFAST_SCALE_BITS.
*/
IFAST_MULT_TYPE * ifmtbl = (IFAST_MULT_TYPE *) compptr->dct_table;
IFAST_MULT_TYPE *ifmtbl = (IFAST_MULT_TYPE *) compptr->dct_table;
#define CONST_BITS 14
static const INT16 aanscales[DCTSIZE2] = {
/* precomputed values scaled up by 14 bits */
@@ -295,7 +295,7 @@ start_pass (j_decompress_ptr cinfo)
* scalefactor[0] = 1
* scalefactor[k] = cos(k*PI/16) * sqrt(2) for k=1..7
*/
FLOAT_MULT_TYPE * fmtbl = (FLOAT_MULT_TYPE *) compptr->dct_table;
FLOAT_MULT_TYPE *fmtbl = (FLOAT_MULT_TYPE *) compptr->dct_table;
int row, col;
static const double aanscalefactor[DCTSIZE] = {
1.0, 1.387039845, 1.306562965, 1.175875602,

View File

@@ -67,20 +67,20 @@ typedef struct {
unsigned int restarts_to_go; /* MCUs left in this restart interval */
/* Pointers to derived tables (these workspaces have image lifespan) */
d_derived_tbl * dc_derived_tbls[NUM_HUFF_TBLS];
d_derived_tbl * ac_derived_tbls[NUM_HUFF_TBLS];
d_derived_tbl *dc_derived_tbls[NUM_HUFF_TBLS];
d_derived_tbl *ac_derived_tbls[NUM_HUFF_TBLS];
/* Precalculated info set up by start_pass for use in decode_mcu: */
/* Pointers to derived tables to be used for each block within an MCU */
d_derived_tbl * dc_cur_tbls[D_MAX_BLOCKS_IN_MCU];
d_derived_tbl * ac_cur_tbls[D_MAX_BLOCKS_IN_MCU];
d_derived_tbl *dc_cur_tbls[D_MAX_BLOCKS_IN_MCU];
d_derived_tbl *ac_cur_tbls[D_MAX_BLOCKS_IN_MCU];
/* Whether we care about the DC and AC coefficient values for each block */
boolean dc_needed[D_MAX_BLOCKS_IN_MCU];
boolean ac_needed[D_MAX_BLOCKS_IN_MCU];
} huff_entropy_decoder;
typedef huff_entropy_decoder * huff_entropy_ptr;
typedef huff_entropy_decoder *huff_entropy_ptr;
/*
@@ -93,7 +93,7 @@ start_pass_huff_decoder (j_decompress_ptr cinfo)
huff_entropy_ptr entropy = (huff_entropy_ptr) cinfo->entropy;
int ci, blkn, dctbl, actbl;
d_derived_tbl **pdtbl;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
/* Check that the scan parameters Ss, Se, Ah/Al are OK for sequential JPEG.
* This ought to be an error condition, but we make it a warning because
@@ -296,13 +296,13 @@ jpeg_make_d_derived_tbl (j_decompress_ptr cinfo, boolean isDC, int tblno,
GLOBAL(boolean)
jpeg_fill_bit_buffer (bitread_working_state * state,
jpeg_fill_bit_buffer (bitread_working_state *state,
register bit_buf_type get_buffer, register int bits_left,
int nbits)
/* Load up the bit buffer to a depth of at least nbits */
{
/* Copy heavily used state fields into locals (hopefully registers) */
register const JOCTET * next_input_byte = state->next_input_byte;
register const JOCTET *next_input_byte = state->next_input_byte;
register size_t bytes_in_buffer = state->bytes_in_buffer;
j_decompress_ptr cinfo = state->cinfo;
@@ -446,9 +446,9 @@ jpeg_fill_bit_buffer (bitread_working_state * state,
*/
GLOBAL(int)
jpeg_huff_decode (bitread_working_state * state,
jpeg_huff_decode (bitread_working_state *state,
register bit_buf_type get_buffer, register int bits_left,
d_derived_tbl * htbl, int min_bits)
d_derived_tbl *htbl, int min_bits)
{
register int l = min_bits;
register JLONG code;
@@ -566,8 +566,8 @@ decode_mcu_slow (j_decompress_ptr cinfo, JBLOCKROW *MCU_data)
for (blkn = 0; blkn < cinfo->blocks_in_MCU; blkn++) {
JBLOCKROW block = MCU_data ? MCU_data[blkn] : NULL;
d_derived_tbl * dctbl = entropy->dc_cur_tbls[blkn];
d_derived_tbl * actbl = entropy->ac_cur_tbls[blkn];
d_derived_tbl *dctbl = entropy->dc_cur_tbls[blkn];
d_derived_tbl *actbl = entropy->ac_cur_tbls[blkn];
register int s, k, r;
/* Decode a single block's worth of coefficients */
@@ -665,8 +665,8 @@ decode_mcu_fast (j_decompress_ptr cinfo, JBLOCKROW *MCU_data)
for (blkn = 0; blkn < cinfo->blocks_in_MCU; blkn++) {
JBLOCKROW block = MCU_data ? MCU_data[blkn] : NULL;
d_derived_tbl * dctbl = entropy->dc_cur_tbls[blkn];
d_derived_tbl * actbl = entropy->ac_cur_tbls[blkn];
d_derived_tbl *dctbl = entropy->dc_cur_tbls[blkn];
d_derived_tbl *actbl = entropy->ac_cur_tbls[blkn];
register int s, k, r, l;
HUFF_DECODE_FAST(s, l, dctbl);

View File

@@ -101,7 +101,7 @@ typedef struct { /* Bitreading state saved across MCUs */
typedef struct { /* Bitreading working state within an MCU */
/* Current data source location */
/* We need a copy, rather than munging the original, in case of suspension */
const JOCTET * next_input_byte; /* => next byte to read from source */
const JOCTET *next_input_byte; /* => next byte to read from source */
size_t bytes_in_buffer; /* # of bytes remaining in source buffer */
/* Bit input buffer --- note these values are kept in register variables,
* not in this struct, inside the inner loops.
@@ -166,7 +166,7 @@ typedef struct { /* Bitreading working state within an MCU */
/* Load up the bit buffer to a depth of at least nbits */
EXTERN(boolean) jpeg_fill_bit_buffer
(bitread_working_state * state, register bit_buf_type get_buffer,
(bitread_working_state *state, register bit_buf_type get_buffer,
register int bits_left, int nbits);
@@ -230,5 +230,5 @@ slowlabel: \
/* Out-of-line case for Huffman code fetching */
EXTERN(int) jpeg_huff_decode
(bitread_working_state * state, register bit_buf_type get_buffer,
register int bits_left, d_derived_tbl * htbl, int min_bits);
(bitread_working_state *state, register bit_buf_type get_buffer,
register int bits_left, d_derived_tbl *htbl, int min_bits);

View File

@@ -28,7 +28,7 @@ typedef struct {
boolean inheaders; /* TRUE until first SOS is reached */
} my_input_controller;
typedef my_input_controller * my_inputctl_ptr;
typedef my_input_controller *my_inputctl_ptr;
/* Forward declarations */
@@ -239,7 +239,7 @@ latch_quant_tables (j_decompress_ptr cinfo)
{
int ci, qtblno;
jpeg_component_info *compptr;
JQUANT_TBL * qtbl;
JQUANT_TBL *qtbl;
for (ci = 0; ci < cinfo->comps_in_scan; ci++) {
compptr = cinfo->cur_comp_info[ci];

View File

@@ -34,7 +34,7 @@ typedef struct {
JDIMENSION iMCU_row_ctr; /* counts iMCU rows to detect image top/bot */
} my_main_controller;
typedef my_main_controller * my_main_ptr;
typedef my_main_controller *my_main_ptr;
/* context_state values: */

View File

@@ -107,7 +107,7 @@ typedef struct {
/* Note: cur_marker is not linked into marker_list until it's all read. */
} my_marker_reader;
typedef my_marker_reader * my_marker_ptr;
typedef my_marker_reader *my_marker_ptr;
/*
@@ -120,8 +120,8 @@ typedef my_marker_reader * my_marker_ptr;
/* Declare and initialize local copies of input pointer/count */
#define INPUT_VARS(cinfo) \
struct jpeg_source_mgr * datasrc = (cinfo)->src; \
const JOCTET * next_input_byte = datasrc->next_input_byte; \
struct jpeg_source_mgr *datasrc = (cinfo)->src; \
const JOCTET *next_input_byte = datasrc->next_input_byte; \
size_t bytes_in_buffer = datasrc->bytes_in_buffer
/* Unload the local copies --- do this only at a restart boundary */
@@ -242,7 +242,7 @@ get_sof (j_decompress_ptr cinfo, boolean is_prog, boolean is_arith)
{
JLONG length;
int c, ci;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
INPUT_VARS(cinfo);
cinfo->progressive_mode = is_prog;
@@ -306,7 +306,7 @@ get_sos (j_decompress_ptr cinfo)
{
JLONG length;
int i, ci, n, c, cc, pi;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
INPUT_VARS(cinfo);
if (! cinfo->marker->saw_SOF)
@@ -598,7 +598,7 @@ get_dri (j_decompress_ptr cinfo)
LOCAL(void)
examine_app0 (j_decompress_ptr cinfo, JOCTET * data,
examine_app0 (j_decompress_ptr cinfo, JOCTET *data,
unsigned int datalen, JLONG remaining)
/* Examine first few bytes from an APP0.
* Take appropriate action if it is a JFIF marker.
@@ -674,7 +674,7 @@ examine_app0 (j_decompress_ptr cinfo, JOCTET * data,
LOCAL(void)
examine_app14 (j_decompress_ptr cinfo, JOCTET * data,
examine_app14 (j_decompress_ptr cinfo, JOCTET *data,
unsigned int datalen, JLONG remaining)
/* Examine first few bytes from an APP14.
* Take appropriate action if it is an Adobe marker.
@@ -759,7 +759,7 @@ save_marker (j_decompress_ptr cinfo)
my_marker_ptr marker = (my_marker_ptr) cinfo->marker;
jpeg_saved_marker_ptr cur_marker = marker->cur_marker;
unsigned int bytes_read, data_length;
JOCTET * data;
JOCTET *data;
JLONG length = 0;
INPUT_VARS(cinfo);

View File

@@ -34,11 +34,11 @@ typedef struct {
/* Saved references to initialized quantizer modules,
* in case we need to switch modes.
*/
struct jpeg_color_quantizer * quantizer_1pass;
struct jpeg_color_quantizer * quantizer_2pass;
struct jpeg_color_quantizer *quantizer_1pass;
struct jpeg_color_quantizer *quantizer_2pass;
} my_decomp_master;
typedef my_decomp_master * my_master_ptr;
typedef my_decomp_master *my_master_ptr;
/*
@@ -425,7 +425,7 @@ LOCAL(void)
prepare_range_limit_table (j_decompress_ptr cinfo)
/* Allocate and fill in the sample_range_limit table */
{
JSAMPLE * table;
JSAMPLE *table;
int i;
table = (JSAMPLE *)

View File

@@ -56,10 +56,10 @@ typedef struct {
JDIMENSION in_row_group_ctr, JSAMPARRAY output_buf);
/* Private state for YCC->RGB conversion */
int * Cr_r_tab; /* => table for Cr to R conversion */
int * Cb_b_tab; /* => table for Cb to B conversion */
JLONG * Cr_g_tab; /* => table for Cr to G conversion */
JLONG * Cb_g_tab; /* => table for Cb to G conversion */
int *Cr_r_tab; /* => table for Cr to R conversion */
int *Cb_b_tab; /* => table for Cb to B conversion */
JLONG *Cr_g_tab; /* => table for Cr to G conversion */
JLONG *Cb_g_tab; /* => table for Cb to G conversion */
/* For 2:1 vertical sampling, we produce two output rows at a time.
* We need a "spare" row buffer to hold the second output row if the
@@ -73,7 +73,7 @@ typedef struct {
JDIMENSION rows_to_go; /* counts rows remaining in image */
} my_upsampler;
typedef my_upsampler * my_upsample_ptr;
typedef my_upsampler *my_upsample_ptr;
#define SCALEBITS 16 /* speediest right-shift on some machines */
#define ONE_HALF ((JLONG) 1 << (SCALEBITS-1))

View File

@@ -69,12 +69,12 @@ typedef struct {
unsigned int restarts_to_go; /* MCUs left in this restart interval */
/* Pointers to derived tables (these workspaces have image lifespan) */
d_derived_tbl * derived_tbls[NUM_HUFF_TBLS];
d_derived_tbl *derived_tbls[NUM_HUFF_TBLS];
d_derived_tbl * ac_derived_tbl; /* active table during an AC scan */
d_derived_tbl *ac_derived_tbl; /* active table during an AC scan */
} phuff_entropy_decoder;
typedef phuff_entropy_decoder * phuff_entropy_ptr;
typedef phuff_entropy_decoder *phuff_entropy_ptr;
/* Forward declarations */
METHODDEF(boolean) decode_mcu_DC_first (j_decompress_ptr cinfo,
@@ -99,7 +99,7 @@ start_pass_phuff_decoder (j_decompress_ptr cinfo)
int ci, coefi, tbl;
d_derived_tbl **pdtbl;
int *coef_bit_ptr;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
is_DC_band = (cinfo->Ss == 0);
@@ -298,8 +298,8 @@ decode_mcu_DC_first (j_decompress_ptr cinfo, JBLOCKROW *MCU_data)
JBLOCKROW block;
BITREAD_STATE_VARS;
savable_state state;
d_derived_tbl * tbl;
jpeg_component_info * compptr;
d_derived_tbl *tbl;
jpeg_component_info *compptr;
/* Process restart marker if needed; may have to suspend */
if (cinfo->restart_interval) {
@@ -369,7 +369,7 @@ decode_mcu_AC_first (j_decompress_ptr cinfo, JBLOCKROW *MCU_data)
unsigned int EOBRUN;
JBLOCKROW block;
BITREAD_STATE_VARS;
d_derived_tbl * tbl;
d_derived_tbl *tbl;
/* Process restart marker if needed; may have to suspend */
if (cinfo->restart_interval) {
@@ -505,7 +505,7 @@ decode_mcu_AC_refine (j_decompress_ptr cinfo, JBLOCKROW *MCU_data)
JBLOCKROW block;
JCOEFPTR thiscoef;
BITREAD_STATE_VARS;
d_derived_tbl * tbl;
d_derived_tbl *tbl;
int num_newnz;
int newnz_pos[DCTSIZE2];

View File

@@ -42,7 +42,7 @@ typedef struct {
JDIMENSION next_row; /* index of next row to fill/empty in strip */
} my_post_controller;
typedef my_post_controller * my_post_ptr;
typedef my_post_controller *my_post_ptr;
/* Forward declarations */

View File

@@ -63,7 +63,7 @@ sep_upsample (j_decompress_ptr cinfo,
{
my_upsample_ptr upsample = (my_upsample_ptr) cinfo->upsample;
int ci;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
JDIMENSION num_rows;
/* Fill the conversion buffer, if it's empty */
@@ -123,8 +123,8 @@ sep_upsample (j_decompress_ptr cinfo,
*/
METHODDEF(void)
fullsize_upsample (j_decompress_ptr cinfo, jpeg_component_info * compptr,
JSAMPARRAY input_data, JSAMPARRAY * output_data_ptr)
fullsize_upsample (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr)
{
*output_data_ptr = input_data;
}
@@ -136,8 +136,8 @@ fullsize_upsample (j_decompress_ptr cinfo, jpeg_component_info * compptr,
*/
METHODDEF(void)
noop_upsample (j_decompress_ptr cinfo, jpeg_component_info * compptr,
JSAMPARRAY input_data, JSAMPARRAY * output_data_ptr)
noop_upsample (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr)
{
*output_data_ptr = NULL; /* safety check */
}
@@ -155,8 +155,8 @@ noop_upsample (j_decompress_ptr cinfo, jpeg_component_info * compptr,
*/
METHODDEF(void)
int_upsample (j_decompress_ptr cinfo, jpeg_component_info * compptr,
JSAMPARRAY input_data, JSAMPARRAY * output_data_ptr)
int_upsample (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr)
{
my_upsample_ptr upsample = (my_upsample_ptr) cinfo->upsample;
JSAMPARRAY output_data = *output_data_ptr;
@@ -199,8 +199,8 @@ int_upsample (j_decompress_ptr cinfo, jpeg_component_info * compptr,
*/
METHODDEF(void)
h2v1_upsample (j_decompress_ptr cinfo, jpeg_component_info * compptr,
JSAMPARRAY input_data, JSAMPARRAY * output_data_ptr)
h2v1_upsample (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr)
{
JSAMPARRAY output_data = *output_data_ptr;
register JSAMPROW inptr, outptr;
@@ -227,8 +227,8 @@ h2v1_upsample (j_decompress_ptr cinfo, jpeg_component_info * compptr,
*/
METHODDEF(void)
h2v2_upsample (j_decompress_ptr cinfo, jpeg_component_info * compptr,
JSAMPARRAY input_data, JSAMPARRAY * output_data_ptr)
h2v2_upsample (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr)
{
JSAMPARRAY output_data = *output_data_ptr;
register JSAMPROW inptr, outptr;
@@ -270,8 +270,8 @@ h2v2_upsample (j_decompress_ptr cinfo, jpeg_component_info * compptr,
*/
METHODDEF(void)
h2v1_fancy_upsample (j_decompress_ptr cinfo, jpeg_component_info * compptr,
JSAMPARRAY input_data, JSAMPARRAY * output_data_ptr)
h2v1_fancy_upsample (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr)
{
JSAMPARRAY output_data = *output_data_ptr;
register JSAMPROW inptr, outptr;
@@ -311,8 +311,8 @@ h2v1_fancy_upsample (j_decompress_ptr cinfo, jpeg_component_info * compptr,
*/
METHODDEF(void)
h2v2_fancy_upsample (j_decompress_ptr cinfo, jpeg_component_info * compptr,
JSAMPARRAY input_data, JSAMPARRAY * output_data_ptr)
h2v2_fancy_upsample (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr)
{
JSAMPARRAY output_data = *output_data_ptr;
register JSAMPROW inptr0, inptr1, outptr;
@@ -369,7 +369,7 @@ jinit_upsampler (j_decompress_ptr cinfo)
{
my_upsample_ptr upsample;
int ci;
jpeg_component_info * compptr;
jpeg_component_info *compptr;
boolean need_buffer, do_fancy;
int h_in_group, v_in_group, h_out_group, v_out_group;

View File

@@ -13,9 +13,9 @@
/* Pointer to routine to upsample a single component */
typedef void (*upsample1_ptr) (j_decompress_ptr cinfo,
jpeg_component_info * compptr,
jpeg_component_info *compptr,
JSAMPARRAY input_data,
JSAMPARRAY * output_data_ptr);
JSAMPARRAY *output_data_ptr);
/* Private subobject */
@@ -47,4 +47,4 @@ typedef struct {
UINT8 v_expand[MAX_COMPONENTS];
} my_upsampler;
typedef my_upsampler * my_upsample_ptr;
typedef my_upsampler *my_upsample_ptr;

View File

@@ -126,7 +126,7 @@ output_message (j_common_ptr cinfo)
METHODDEF(void)
emit_message (j_common_ptr cinfo, int msg_level)
{
struct jpeg_error_mgr * err = cinfo->err;
struct jpeg_error_mgr *err = cinfo->err;
if (msg_level < 0) {
/* It's a warning message. Since corrupt files may generate many warnings,
@@ -153,12 +153,12 @@ emit_message (j_common_ptr cinfo, int msg_level)
*/
METHODDEF(void)
format_message (j_common_ptr cinfo, char * buffer)
format_message (j_common_ptr cinfo, char *buffer)
{
struct jpeg_error_mgr * err = cinfo->err;
struct jpeg_error_mgr *err = cinfo->err;
int msg_code = err->msg_code;
const char * msgtext = NULL;
const char * msgptr;
const char *msgtext = NULL;
const char *msgptr;
char ch;
boolean isstring;
@@ -227,7 +227,7 @@ reset_error_mgr (j_common_ptr cinfo)
*/
GLOBAL(struct jpeg_error_mgr *)
jpeg_std_error (struct jpeg_error_mgr * err)
jpeg_std_error (struct jpeg_error_mgr *err)
{
err->error_exit = error_exit;
err->emit_message = emit_message;

View File

@@ -57,7 +57,7 @@
*/
GLOBAL(void)
jpeg_fdct_float (FAST_FLOAT * data)
jpeg_fdct_float (FAST_FLOAT *data)
{
FAST_FLOAT tmp0, tmp1, tmp2, tmp3, tmp4, tmp5, tmp6, tmp7;
FAST_FLOAT tmp10, tmp11, tmp12, tmp13;

View File

@@ -114,7 +114,7 @@
*/
GLOBAL(void)
jpeg_fdct_ifast (DCTELEM * data)
jpeg_fdct_ifast (DCTELEM *data)
{
DCTELEM tmp0, tmp1, tmp2, tmp3, tmp4, tmp5, tmp6, tmp7;
DCTELEM tmp10, tmp11, tmp12, tmp13;

View File

@@ -140,7 +140,7 @@
*/
GLOBAL(void)
jpeg_fdct_islow (DCTELEM * data)
jpeg_fdct_islow (DCTELEM *data)
{
JLONG tmp0, tmp1, tmp2, tmp3, tmp4, tmp5, tmp6, tmp7;
JLONG tmp10, tmp11, tmp12, tmp13;

View File

@@ -69,7 +69,7 @@
*/
GLOBAL(void)
jpeg_idct_float (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jpeg_idct_float (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block,
JSAMPARRAY output_buf, JDIMENSION output_col)
{
@@ -77,8 +77,8 @@ jpeg_idct_float (j_decompress_ptr cinfo, jpeg_component_info * compptr,
FAST_FLOAT tmp10, tmp11, tmp12, tmp13;
FAST_FLOAT z5, z10, z11, z12, z13;
JCOEFPTR inptr;
FLOAT_MULT_TYPE * quantptr;
FAST_FLOAT * wsptr;
FLOAT_MULT_TYPE *quantptr;
FAST_FLOAT *wsptr;
JSAMPROW outptr;
JSAMPLE *range_limit = cinfo->sample_range_limit;
int ctr;

View File

@@ -168,7 +168,7 @@
*/
GLOBAL(void)
jpeg_idct_ifast (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jpeg_idct_ifast (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block,
JSAMPARRAY output_buf, JDIMENSION output_col)
{
@@ -176,8 +176,8 @@ jpeg_idct_ifast (j_decompress_ptr cinfo, jpeg_component_info * compptr,
DCTELEM tmp10, tmp11, tmp12, tmp13;
DCTELEM z5, z10, z11, z12, z13;
JCOEFPTR inptr;
IFAST_MULT_TYPE * quantptr;
int * wsptr;
IFAST_MULT_TYPE *quantptr;
int *wsptr;
JSAMPROW outptr;
JSAMPLE *range_limit = IDCT_range_limit(cinfo);
int ctr;

View File

@@ -170,7 +170,7 @@
*/
GLOBAL(void)
jpeg_idct_islow (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jpeg_idct_islow (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block,
JSAMPARRAY output_buf, JDIMENSION output_col)
{
@@ -178,8 +178,8 @@ jpeg_idct_islow (j_decompress_ptr cinfo, jpeg_component_info * compptr,
JLONG tmp10, tmp11, tmp12, tmp13;
JLONG z1, z2, z3, z4, z5;
JCOEFPTR inptr;
ISLOW_MULT_TYPE * quantptr;
int * wsptr;
ISLOW_MULT_TYPE *quantptr;
int *wsptr;
JSAMPROW outptr;
JSAMPLE *range_limit = IDCT_range_limit(cinfo);
int ctr;
@@ -424,15 +424,15 @@ jpeg_idct_islow (j_decompress_ptr cinfo, jpeg_component_info * compptr,
*/
GLOBAL(void)
jpeg_idct_7x7 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jpeg_idct_7x7 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block,
JSAMPARRAY output_buf, JDIMENSION output_col)
{
JLONG tmp0, tmp1, tmp2, tmp10, tmp11, tmp12, tmp13;
JLONG z1, z2, z3;
JCOEFPTR inptr;
ISLOW_MULT_TYPE * quantptr;
int * wsptr;
ISLOW_MULT_TYPE *quantptr;
int *wsptr;
JSAMPROW outptr;
JSAMPLE *range_limit = IDCT_range_limit(cinfo);
int ctr;
@@ -573,15 +573,15 @@ jpeg_idct_7x7 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
*/
GLOBAL(void)
jpeg_idct_6x6 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jpeg_idct_6x6 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block,
JSAMPARRAY output_buf, JDIMENSION output_col)
{
JLONG tmp0, tmp1, tmp2, tmp10, tmp11, tmp12;
JLONG z1, z2, z3;
JCOEFPTR inptr;
ISLOW_MULT_TYPE * quantptr;
int * wsptr;
ISLOW_MULT_TYPE *quantptr;
int *wsptr;
JSAMPROW outptr;
JSAMPLE *range_limit = IDCT_range_limit(cinfo);
int ctr;
@@ -694,15 +694,15 @@ jpeg_idct_6x6 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
*/
GLOBAL(void)
jpeg_idct_5x5 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jpeg_idct_5x5 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block,
JSAMPARRAY output_buf, JDIMENSION output_col)
{
JLONG tmp0, tmp1, tmp10, tmp11, tmp12;
JLONG z1, z2, z3;
JCOEFPTR inptr;
ISLOW_MULT_TYPE * quantptr;
int * wsptr;
ISLOW_MULT_TYPE *quantptr;
int *wsptr;
JSAMPROW outptr;
JSAMPLE *range_limit = IDCT_range_limit(cinfo);
int ctr;
@@ -809,14 +809,14 @@ jpeg_idct_5x5 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
*/
GLOBAL(void)
jpeg_idct_3x3 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jpeg_idct_3x3 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block,
JSAMPARRAY output_buf, JDIMENSION output_col)
{
JLONG tmp0, tmp2, tmp10, tmp12;
JCOEFPTR inptr;
ISLOW_MULT_TYPE * quantptr;
int * wsptr;
ISLOW_MULT_TYPE *quantptr;
int *wsptr;
JSAMPROW outptr;
JSAMPLE *range_limit = IDCT_range_limit(cinfo);
int ctr;
@@ -899,15 +899,15 @@ jpeg_idct_3x3 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
*/
GLOBAL(void)
jpeg_idct_9x9 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jpeg_idct_9x9 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block,
JSAMPARRAY output_buf, JDIMENSION output_col)
{
JLONG tmp0, tmp1, tmp2, tmp3, tmp10, tmp11, tmp12, tmp13, tmp14;
JLONG z1, z2, z3, z4;
JCOEFPTR inptr;
ISLOW_MULT_TYPE * quantptr;
int * wsptr;
ISLOW_MULT_TYPE *quantptr;
int *wsptr;
JSAMPROW outptr;
JSAMPLE *range_limit = IDCT_range_limit(cinfo);
int ctr;
@@ -1070,7 +1070,7 @@ jpeg_idct_9x9 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
*/
GLOBAL(void)
jpeg_idct_10x10 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jpeg_idct_10x10 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block,
JSAMPARRAY output_buf, JDIMENSION output_col)
{
@@ -1078,8 +1078,8 @@ jpeg_idct_10x10 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
JLONG tmp20, tmp21, tmp22, tmp23, tmp24;
JLONG z1, z2, z3, z4, z5;
JCOEFPTR inptr;
ISLOW_MULT_TYPE * quantptr;
int * wsptr;
ISLOW_MULT_TYPE *quantptr;
int *wsptr;
JSAMPROW outptr;
JSAMPLE *range_limit = IDCT_range_limit(cinfo);
int ctr;
@@ -1265,7 +1265,7 @@ jpeg_idct_10x10 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
*/
GLOBAL(void)
jpeg_idct_11x11 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jpeg_idct_11x11 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block,
JSAMPARRAY output_buf, JDIMENSION output_col)
{
@@ -1273,8 +1273,8 @@ jpeg_idct_11x11 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
JLONG tmp20, tmp21, tmp22, tmp23, tmp24, tmp25;
JLONG z1, z2, z3, z4;
JCOEFPTR inptr;
ISLOW_MULT_TYPE * quantptr;
int * wsptr;
ISLOW_MULT_TYPE *quantptr;
int *wsptr;
JSAMPROW outptr;
JSAMPLE *range_limit = IDCT_range_limit(cinfo);
int ctr;
@@ -1459,7 +1459,7 @@ jpeg_idct_11x11 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
*/
GLOBAL(void)
jpeg_idct_12x12 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jpeg_idct_12x12 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block,
JSAMPARRAY output_buf, JDIMENSION output_col)
{
@@ -1467,8 +1467,8 @@ jpeg_idct_12x12 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
JLONG tmp20, tmp21, tmp22, tmp23, tmp24, tmp25;
JLONG z1, z2, z3, z4;
JCOEFPTR inptr;
ISLOW_MULT_TYPE * quantptr;
int * wsptr;
ISLOW_MULT_TYPE *quantptr;
int *wsptr;
JSAMPROW outptr;
JSAMPLE *range_limit = IDCT_range_limit(cinfo);
int ctr;
@@ -1675,7 +1675,7 @@ jpeg_idct_12x12 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
*/
GLOBAL(void)
jpeg_idct_13x13 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jpeg_idct_13x13 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block,
JSAMPARRAY output_buf, JDIMENSION output_col)
{
@@ -1683,8 +1683,8 @@ jpeg_idct_13x13 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
JLONG tmp20, tmp21, tmp22, tmp23, tmp24, tmp25, tmp26;
JLONG z1, z2, z3, z4;
JCOEFPTR inptr;
ISLOW_MULT_TYPE * quantptr;
int * wsptr;
ISLOW_MULT_TYPE *quantptr;
int *wsptr;
JSAMPROW outptr;
JSAMPLE *range_limit = IDCT_range_limit(cinfo);
int ctr;
@@ -1903,7 +1903,7 @@ jpeg_idct_13x13 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
*/
GLOBAL(void)
jpeg_idct_14x14 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jpeg_idct_14x14 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block,
JSAMPARRAY output_buf, JDIMENSION output_col)
{
@@ -1911,8 +1911,8 @@ jpeg_idct_14x14 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
JLONG tmp20, tmp21, tmp22, tmp23, tmp24, tmp25, tmp26;
JLONG z1, z2, z3, z4;
JCOEFPTR inptr;
ISLOW_MULT_TYPE * quantptr;
int * wsptr;
ISLOW_MULT_TYPE *quantptr;
int *wsptr;
JSAMPROW outptr;
JSAMPLE *range_limit = IDCT_range_limit(cinfo);
int ctr;
@@ -2129,7 +2129,7 @@ jpeg_idct_14x14 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
*/
GLOBAL(void)
jpeg_idct_15x15 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jpeg_idct_15x15 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block,
JSAMPARRAY output_buf, JDIMENSION output_col)
{
@@ -2137,8 +2137,8 @@ jpeg_idct_15x15 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
JLONG tmp20, tmp21, tmp22, tmp23, tmp24, tmp25, tmp26, tmp27;
JLONG z1, z2, z3, z4;
JCOEFPTR inptr;
ISLOW_MULT_TYPE * quantptr;
int * wsptr;
ISLOW_MULT_TYPE *quantptr;
int *wsptr;
JSAMPROW outptr;
JSAMPLE *range_limit = IDCT_range_limit(cinfo);
int ctr;
@@ -2371,7 +2371,7 @@ jpeg_idct_15x15 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
*/
GLOBAL(void)
jpeg_idct_16x16 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jpeg_idct_16x16 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block,
JSAMPARRAY output_buf, JDIMENSION output_col)
{
@@ -2379,8 +2379,8 @@ jpeg_idct_16x16 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
JLONG tmp20, tmp21, tmp22, tmp23, tmp24, tmp25, tmp26, tmp27;
JLONG z1, z2, z3, z4;
JCOEFPTR inptr;
ISLOW_MULT_TYPE * quantptr;
int * wsptr;
ISLOW_MULT_TYPE *quantptr;
int *wsptr;
JSAMPROW outptr;
JSAMPLE *range_limit = IDCT_range_limit(cinfo);
int ctr;

View File

@@ -118,15 +118,15 @@
*/
GLOBAL(void)
jpeg_idct_4x4 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jpeg_idct_4x4 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block,
JSAMPARRAY output_buf, JDIMENSION output_col)
{
JLONG tmp0, tmp2, tmp10, tmp12;
JLONG z1, z2, z3, z4;
JCOEFPTR inptr;
ISLOW_MULT_TYPE * quantptr;
int * wsptr;
ISLOW_MULT_TYPE *quantptr;
int *wsptr;
JSAMPROW outptr;
JSAMPLE *range_limit = IDCT_range_limit(cinfo);
int ctr;
@@ -272,14 +272,14 @@ jpeg_idct_4x4 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
*/
GLOBAL(void)
jpeg_idct_2x2 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jpeg_idct_2x2 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block,
JSAMPARRAY output_buf, JDIMENSION output_col)
{
JLONG tmp0, tmp10, z1;
JCOEFPTR inptr;
ISLOW_MULT_TYPE * quantptr;
int * wsptr;
ISLOW_MULT_TYPE *quantptr;
int *wsptr;
JSAMPROW outptr;
JSAMPLE *range_limit = IDCT_range_limit(cinfo);
int ctr;
@@ -381,12 +381,12 @@ jpeg_idct_2x2 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
*/
GLOBAL(void)
jpeg_idct_1x1 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jpeg_idct_1x1 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block,
JSAMPARRAY output_buf, JDIMENSION output_col)
{
int dcval;
ISLOW_MULT_TYPE * quantptr;
ISLOW_MULT_TYPE *quantptr;
JSAMPLE *range_limit = IDCT_range_limit(cinfo);
SHIFT_TEMPS

View File

@@ -35,7 +35,7 @@
#ifndef NO_GETENV
#ifndef HAVE_STDLIB_H /* <stdlib.h> should declare getenv() */
extern char * getenv (const char * name);
extern char *getenv (const char *name);
#endif
#endif
@@ -97,7 +97,7 @@ round_up_pow2 (size_t a, size_t b)
* Small and large pool headers are identical.
*/
typedef struct small_pool_struct * small_pool_ptr;
typedef struct small_pool_struct *small_pool_ptr;
typedef struct small_pool_struct {
small_pool_ptr next; /* next in list of pools */
@@ -105,7 +105,7 @@ typedef struct small_pool_struct {
size_t bytes_left; /* bytes still available in this pool */
} small_pool_hdr;
typedef struct large_pool_struct * large_pool_ptr;
typedef struct large_pool_struct *large_pool_ptr;
typedef struct large_pool_struct {
large_pool_ptr next; /* next in list of pools */
@@ -141,7 +141,7 @@ typedef struct {
JDIMENSION last_rowsperchunk; /* from most recent alloc_sarray/barray */
} my_memory_mgr;
typedef my_memory_mgr * my_mem_ptr;
typedef my_memory_mgr *my_mem_ptr;
/*
@@ -267,7 +267,7 @@ alloc_small (j_common_ptr cinfo, int pool_id, size_t sizeofobject)
{
my_mem_ptr mem = (my_mem_ptr) cinfo->mem;
small_pool_ptr hdr_ptr, prev_hdr_ptr;
char * data_ptr;
char *data_ptr;
size_t min_request, slop;
/*
@@ -363,7 +363,7 @@ alloc_large (j_common_ptr cinfo, int pool_id, size_t sizeofobject)
{
my_mem_ptr mem = (my_mem_ptr) cinfo->mem;
large_pool_ptr hdr_ptr;
char * data_ptr;
char *data_ptr;
/*
* Round up the requested size to a multiple of ALIGN_SIZE so that
@@ -1154,7 +1154,7 @@ jinit_memory_mgr (j_common_ptr cinfo)
* this feature.
*/
#ifndef NO_GETENV
{ char * memenv;
{ char *memenv;
if ((memenv = getenv("JPEGMEM")) != NULL) {
char ch = 'x';

View File

@@ -24,7 +24,7 @@
#include "jmemsys.h" /* import the system-dependent declarations */
#ifndef HAVE_STDLIB_H /* <stdlib.h> should declare malloc(),free() */
extern void * malloc (size_t size);
extern void *malloc (size_t size);
extern void free (void *ptr);
#endif
@@ -41,7 +41,7 @@ jpeg_get_small (j_common_ptr cinfo, size_t sizeofobject)
}
GLOBAL(void)
jpeg_free_small (j_common_ptr cinfo, void * object, size_t sizeofobject)
jpeg_free_small (j_common_ptr cinfo, void *object, size_t sizeofobject)
{
free(object);
}
@@ -58,7 +58,7 @@ jpeg_get_large (j_common_ptr cinfo, size_t sizeofobject)
}
GLOBAL(void)
jpeg_free_large (j_common_ptr cinfo, void * object, size_t sizeofobject)
jpeg_free_large (j_common_ptr cinfo, void *object, size_t sizeofobject)
{
free(object);
}

View File

@@ -32,7 +32,7 @@
*/
EXTERN(void *) jpeg_get_small (j_common_ptr cinfo, size_t sizeofobject);
EXTERN(void) jpeg_free_small (j_common_ptr cinfo, void * object,
EXTERN(void) jpeg_free_small (j_common_ptr cinfo, void *object,
size_t sizeofobject);
/*
@@ -44,7 +44,7 @@ EXTERN(void) jpeg_free_small (j_common_ptr cinfo, void * object,
*/
EXTERN(void *) jpeg_get_large (j_common_ptr cinfo, size_t sizeofobject);
EXTERN(void) jpeg_free_large (j_common_ptr cinfo, void * object,
EXTERN(void) jpeg_free_large (j_common_ptr cinfo, void *object,
size_t sizeofobject);
/*
@@ -117,15 +117,15 @@ typedef union {
#endif /* USE_MAC_MEMMGR */
typedef struct backing_store_struct * backing_store_ptr;
typedef struct backing_store_struct *backing_store_ptr;
typedef struct backing_store_struct {
/* Methods for reading/writing/closing this backing-store object */
void (*read_backing_store) (j_common_ptr cinfo, backing_store_ptr info,
void * buffer_address, long file_offset,
void *buffer_address, long file_offset,
long byte_count);
void (*write_backing_store) (j_common_ptr cinfo, backing_store_ptr info,
void * buffer_address, long file_offset,
void *buffer_address, long file_offset,
long byte_count);
void (*close_backing_store) (j_common_ptr cinfo, backing_store_ptr info);
@@ -142,7 +142,7 @@ typedef struct backing_store_struct {
char temp_name[TEMP_NAME_LENGTH]; /* name if it's a file */
#else
/* For a typical implementation with temp files, we need: */
FILE * temp_file; /* stdio reference to temp file */
FILE *temp_file; /* stdio reference to temp file */
char temp_name[TEMP_NAME_LENGTH]; /* name of temp file */
#endif
#endif

View File

@@ -113,7 +113,7 @@ struct jpeg_downsampler {
struct jpeg_forward_dct {
void (*start_pass) (j_compress_ptr cinfo);
/* perhaps this should be an array??? */
void (*forward_DCT) (j_compress_ptr cinfo, jpeg_component_info * compptr,
void (*forward_DCT) (j_compress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY sample_data, JBLOCKROW coef_blocks,
JDIMENSION start_row, JDIMENSION start_col,
JDIMENSION num_blocks);
@@ -223,7 +223,7 @@ struct jpeg_entropy_decoder {
/* Inverse DCT (also performs dequantization) */
typedef void (*inverse_DCT_method_ptr) (j_decompress_ptr cinfo,
jpeg_component_info * compptr,
jpeg_component_info *compptr,
JCOEFPTR coef_block,
JSAMPARRAY output_buf,
JDIMENSION output_col);
@@ -340,7 +340,7 @@ EXTERN(void) jcopy_sample_rows (JSAMPARRAY input_array, int source_row,
int num_rows, JDIMENSION num_cols);
EXTERN(void) jcopy_block_row (JBLOCKROW input_row, JBLOCKROW output_row,
JDIMENSION num_blocks);
EXTERN(void) jzero_far (void * target, size_t bytestozero);
EXTERN(void) jzero_far (void *target, size_t bytestozero);
/* Constant tables in jutils.c */
#if 0 /* This table is not actually needed in v6a */
extern const int jpeg_zigzag_order[]; /* natural coef order to zigzag order */

132
jpeglib.h
View File

@@ -180,10 +180,10 @@ typedef struct {
* See jdinput.c comments about the need for this information.
* This field is currently used only for decompression.
*/
JQUANT_TBL * quant_table;
JQUANT_TBL *quant_table;
/* Private per-component storage for DCT or IDCT subsystem. */
void * dct_table;
void *dct_table;
} jpeg_component_info;
@@ -198,14 +198,14 @@ typedef struct {
/* The decompressor can save APPn and COM markers in a list of these: */
typedef struct jpeg_marker_struct * jpeg_saved_marker_ptr;
typedef struct jpeg_marker_struct *jpeg_saved_marker_ptr;
struct jpeg_marker_struct {
jpeg_saved_marker_ptr next; /* next in list, or NULL */
UINT8 marker; /* marker code: JPEG_COM, or JPEG_APP0+n */
unsigned int original_length; /* # bytes of data in the file */
unsigned int data_length; /* # bytes of data saved at data[] */
JOCTET * data; /* the data contained in the marker */
JOCTET *data; /* the data contained in the marker */
/* the marker length word is not counted in data_length or original_length */
};
@@ -268,10 +268,10 @@ typedef enum {
/* Common fields between JPEG compression and decompression master structs. */
#define jpeg_common_fields \
struct jpeg_error_mgr * err; /* Error handler module */\
struct jpeg_memory_mgr * mem; /* Memory manager module */\
struct jpeg_progress_mgr * progress; /* Progress monitor, or NULL if none */\
void * client_data; /* Available for use by application */\
struct jpeg_error_mgr *err; /* Error handler module */\
struct jpeg_memory_mgr *mem; /* Memory manager module */\
struct jpeg_progress_mgr *progress; /* Progress monitor, or NULL if none */\
void *client_data; /* Available for use by application */\
boolean is_decompressor; /* So common code can tell which is which */\
int global_state /* For checking call sequence validity */
@@ -287,9 +287,9 @@ struct jpeg_common_struct {
*/
};
typedef struct jpeg_common_struct * j_common_ptr;
typedef struct jpeg_compress_struct * j_compress_ptr;
typedef struct jpeg_decompress_struct * j_decompress_ptr;
typedef struct jpeg_common_struct *j_common_ptr;
typedef struct jpeg_compress_struct *j_compress_ptr;
typedef struct jpeg_decompress_struct *j_decompress_ptr;
/* Master record for a compression instance */
@@ -298,7 +298,7 @@ struct jpeg_compress_struct {
jpeg_common_fields; /* Fields shared with jpeg_decompress_struct */
/* Destination for compressed data */
struct jpeg_destination_mgr * dest;
struct jpeg_destination_mgr *dest;
/* Description of source image --- these fields must be filled in by
* outer application before starting compression. in_color_space must
@@ -338,10 +338,10 @@ struct jpeg_compress_struct {
int num_components; /* # of color components in JPEG image */
J_COLOR_SPACE jpeg_color_space; /* colorspace of JPEG image */
jpeg_component_info * comp_info;
jpeg_component_info *comp_info;
/* comp_info[i] describes component that appears i'th in SOF */
JQUANT_TBL * quant_tbl_ptrs[NUM_QUANT_TBLS];
JQUANT_TBL *quant_tbl_ptrs[NUM_QUANT_TBLS];
#if JPEG_LIB_VERSION >= 70
int q_scale_factor[NUM_QUANT_TBLS];
#endif
@@ -349,8 +349,8 @@ struct jpeg_compress_struct {
* and corresponding scale factors (percentage, initialized 100).
*/
JHUFF_TBL * dc_huff_tbl_ptrs[NUM_HUFF_TBLS];
JHUFF_TBL * ac_huff_tbl_ptrs[NUM_HUFF_TBLS];
JHUFF_TBL *dc_huff_tbl_ptrs[NUM_HUFF_TBLS];
JHUFF_TBL *ac_huff_tbl_ptrs[NUM_HUFF_TBLS];
/* ptrs to Huffman coding tables, or NULL if not defined */
UINT8 arith_dc_L[NUM_ARITH_TBLS]; /* L values for DC arith-coding tables */
@@ -358,7 +358,7 @@ struct jpeg_compress_struct {
UINT8 arith_ac_K[NUM_ARITH_TBLS]; /* Kx values for AC arith-coding tables */
int num_scans; /* # of entries in scan_info array */
const jpeg_scan_info * scan_info; /* script for multi-scan file, or NULL */
const jpeg_scan_info *scan_info; /* script for multi-scan file, or NULL */
/* The default value of scan_info is NULL, which causes a single-scan
* sequential JPEG file to be emitted. To create a multi-scan file,
* set num_scans and scan_info to point to an array of scan definitions.
@@ -431,7 +431,7 @@ struct jpeg_compress_struct {
* They describe the components and MCUs actually appearing in the scan.
*/
int comps_in_scan; /* # of JPEG components in this scan */
jpeg_component_info * cur_comp_info[MAX_COMPS_IN_SCAN];
jpeg_component_info *cur_comp_info[MAX_COMPS_IN_SCAN];
/* *cur_comp_info[i] describes component that appears i'th in SOS */
JDIMENSION MCUs_per_row; /* # of MCUs across the image */
@@ -446,23 +446,23 @@ struct jpeg_compress_struct {
#if JPEG_LIB_VERSION >= 80
int block_size; /* the basic DCT block size: 1..16 */
const int * natural_order; /* natural-order position array */
const int *natural_order; /* natural-order position array */
int lim_Se; /* min( Se, DCTSIZE2-1 ) */
#endif
/*
* Links to compression subobjects (methods and private variables of modules)
*/
struct jpeg_comp_master * master;
struct jpeg_c_main_controller * main;
struct jpeg_c_prep_controller * prep;
struct jpeg_c_coef_controller * coef;
struct jpeg_marker_writer * marker;
struct jpeg_color_converter * cconvert;
struct jpeg_downsampler * downsample;
struct jpeg_forward_dct * fdct;
struct jpeg_entropy_encoder * entropy;
jpeg_scan_info * script_space; /* workspace for jpeg_simple_progression */
struct jpeg_comp_master *master;
struct jpeg_c_main_controller *main;
struct jpeg_c_prep_controller *prep;
struct jpeg_c_coef_controller *coef;
struct jpeg_marker_writer *marker;
struct jpeg_color_converter *cconvert;
struct jpeg_downsampler *downsample;
struct jpeg_forward_dct *fdct;
struct jpeg_entropy_encoder *entropy;
jpeg_scan_info *script_space; /* workspace for jpeg_simple_progression */
int script_space_size;
};
@@ -473,7 +473,7 @@ struct jpeg_decompress_struct {
jpeg_common_fields; /* Fields shared with jpeg_compress_struct */
/* Source of compressed data */
struct jpeg_source_mgr * src;
struct jpeg_source_mgr *src;
/* Basic description of image --- filled in by jpeg_read_header(). */
/* Application may inspect these values to decide how to process image. */
@@ -580,11 +580,11 @@ struct jpeg_decompress_struct {
* datastreams when processing abbreviated JPEG datastreams.
*/
JQUANT_TBL * quant_tbl_ptrs[NUM_QUANT_TBLS];
JQUANT_TBL *quant_tbl_ptrs[NUM_QUANT_TBLS];
/* ptrs to coefficient quantization tables, or NULL if not defined */
JHUFF_TBL * dc_huff_tbl_ptrs[NUM_HUFF_TBLS];
JHUFF_TBL * ac_huff_tbl_ptrs[NUM_HUFF_TBLS];
JHUFF_TBL *dc_huff_tbl_ptrs[NUM_HUFF_TBLS];
JHUFF_TBL *ac_huff_tbl_ptrs[NUM_HUFF_TBLS];
/* ptrs to Huffman coding tables, or NULL if not defined */
/* These parameters are never carried across datastreams, since they
@@ -593,7 +593,7 @@ struct jpeg_decompress_struct {
int data_precision; /* bits of precision in image data */
jpeg_component_info * comp_info;
jpeg_component_info *comp_info;
/* comp_info[i] describes component that appears i'th in SOF */
#if JPEG_LIB_VERSION >= 80
@@ -655,7 +655,7 @@ struct jpeg_decompress_struct {
* v_samp_factor*DCT_[v_]scaled_size sample rows of a component per iMCU row.
*/
JSAMPLE * sample_range_limit; /* table for fast range-limiting */
JSAMPLE *sample_range_limit; /* table for fast range-limiting */
/*
* These fields are valid during any one scan.
@@ -663,7 +663,7 @@ struct jpeg_decompress_struct {
* Note that the decompressor output side must not use these fields.
*/
int comps_in_scan; /* # of JPEG components in this scan */
jpeg_component_info * cur_comp_info[MAX_COMPS_IN_SCAN];
jpeg_component_info *cur_comp_info[MAX_COMPS_IN_SCAN];
/* *cur_comp_info[i] describes component that appears i'th in SOS */
JDIMENSION MCUs_per_row; /* # of MCUs across the image */
@@ -680,7 +680,7 @@ struct jpeg_decompress_struct {
/* These fields are derived from Se of first SOS marker.
*/
int block_size; /* the basic DCT block size: 1..16 */
const int * natural_order; /* natural-order position array for entropy decode */
const int *natural_order; /* natural-order position array for entropy decode */
int lim_Se; /* min( Se, DCTSIZE2-1 ) for entropy decode */
#endif
@@ -693,17 +693,17 @@ struct jpeg_decompress_struct {
/*
* Links to decompression subobjects (methods, private variables of modules)
*/
struct jpeg_decomp_master * master;
struct jpeg_d_main_controller * main;
struct jpeg_d_coef_controller * coef;
struct jpeg_d_post_controller * post;
struct jpeg_input_controller * inputctl;
struct jpeg_marker_reader * marker;
struct jpeg_entropy_decoder * entropy;
struct jpeg_inverse_dct * idct;
struct jpeg_upsampler * upsample;
struct jpeg_color_deconverter * cconvert;
struct jpeg_color_quantizer * cquantize;
struct jpeg_decomp_master *master;
struct jpeg_d_main_controller *main;
struct jpeg_d_coef_controller *coef;
struct jpeg_d_post_controller *post;
struct jpeg_input_controller *inputctl;
struct jpeg_marker_reader *marker;
struct jpeg_entropy_decoder *entropy;
struct jpeg_inverse_dct *idct;
struct jpeg_upsampler *upsample;
struct jpeg_color_deconverter *cconvert;
struct jpeg_color_quantizer *cquantize;
};
@@ -725,7 +725,7 @@ struct jpeg_error_mgr {
/* Routine that actually outputs a trace or error message */
void (*output_message) (j_common_ptr cinfo);
/* Format a message string for the most recent JPEG error or message */
void (*format_message) (j_common_ptr cinfo, char * buffer);
void (*format_message) (j_common_ptr cinfo, char *buffer);
#define JMSG_LENGTH_MAX 200 /* recommended size of format_message buffer */
/* Reset error state variables at start of a new image */
void (*reset_error_mgr) (j_common_ptr cinfo);
@@ -762,12 +762,12 @@ struct jpeg_error_mgr {
* First table includes all errors generated by JPEG library itself.
* Error code 0 is reserved for a "no such error string" message.
*/
const char * const * jpeg_message_table; /* Library errors */
const char * const *jpeg_message_table; /* Library errors */
int last_jpeg_message; /* Table contains strings 0..last_jpeg_message */
/* Second table can be added by application (see cjpeg/djpeg for example).
* It contains strings numbered first_addon_message..last_addon_message.
*/
const char * const * addon_message_table; /* Non-library errors */
const char * const *addon_message_table; /* Non-library errors */
int first_addon_message; /* code for first string in addon table */
int last_addon_message; /* code for last string in addon table */
};
@@ -788,7 +788,7 @@ struct jpeg_progress_mgr {
/* Data destination object for compression */
struct jpeg_destination_mgr {
JOCTET * next_output_byte; /* => next byte to write in buffer */
JOCTET *next_output_byte; /* => next byte to write in buffer */
size_t free_in_buffer; /* # of byte spaces remaining in buffer */
void (*init_destination) (j_compress_ptr cinfo);
@@ -800,7 +800,7 @@ struct jpeg_destination_mgr {
/* Data source object for decompression */
struct jpeg_source_mgr {
const JOCTET * next_input_byte; /* => next byte to read from buffer */
const JOCTET *next_input_byte; /* => next byte to read from buffer */
size_t bytes_in_buffer; /* # of bytes remaining in buffer */
void (*init_source) (j_decompress_ptr cinfo);
@@ -826,15 +826,15 @@ struct jpeg_source_mgr {
#define JPOOL_IMAGE 1 /* lasts until done with image/datastream */
#define JPOOL_NUMPOOLS 2
typedef struct jvirt_sarray_control * jvirt_sarray_ptr;
typedef struct jvirt_barray_control * jvirt_barray_ptr;
typedef struct jvirt_sarray_control *jvirt_sarray_ptr;
typedef struct jvirt_barray_control *jvirt_barray_ptr;
struct jpeg_memory_mgr {
/* Method pointers */
void * (*alloc_small) (j_common_ptr cinfo, int pool_id, size_t sizeofobject);
void * (*alloc_large) (j_common_ptr cinfo, int pool_id,
size_t sizeofobject);
void *(*alloc_small) (j_common_ptr cinfo, int pool_id, size_t sizeofobject);
void *(*alloc_large) (j_common_ptr cinfo, int pool_id,
size_t sizeofobject);
JSAMPARRAY (*alloc_sarray) (j_common_ptr cinfo, int pool_id,
JDIMENSION samplesperrow, JDIMENSION numrows);
JBLOCKARRAY (*alloc_barray) (j_common_ptr cinfo, int pool_id,
@@ -888,7 +888,7 @@ typedef boolean (*jpeg_marker_parser_method) (j_decompress_ptr cinfo);
/* Default error-management setup */
EXTERN(struct jpeg_error_mgr *) jpeg_std_error (struct jpeg_error_mgr * err);
EXTERN(struct jpeg_error_mgr *) jpeg_std_error (struct jpeg_error_mgr *err);
/* Initialization of JPEG compression objects.
* jpeg_create_compress() and jpeg_create_decompress() are the exported
@@ -913,15 +913,15 @@ EXTERN(void) jpeg_destroy_decompress (j_decompress_ptr cinfo);
/* Standard data source and destination managers: stdio streams. */
/* Caller is responsible for opening the file before and closing after. */
EXTERN(void) jpeg_stdio_dest (j_compress_ptr cinfo, FILE * outfile);
EXTERN(void) jpeg_stdio_src (j_decompress_ptr cinfo, FILE * infile);
EXTERN(void) jpeg_stdio_dest (j_compress_ptr cinfo, FILE *outfile);
EXTERN(void) jpeg_stdio_src (j_decompress_ptr cinfo, FILE *infile);
#if JPEG_LIB_VERSION >= 80 || defined(MEM_SRCDST_SUPPORTED)
/* Data source and destination managers: memory buffers. */
EXTERN(void) jpeg_mem_dest (j_compress_ptr cinfo, unsigned char ** outbuffer,
unsigned long * outsize);
EXTERN(void) jpeg_mem_dest (j_compress_ptr cinfo, unsigned char **outbuffer,
unsigned long *outsize);
EXTERN(void) jpeg_mem_src (j_decompress_ptr cinfo,
const unsigned char * inbuffer,
const unsigned char *inbuffer,
unsigned long insize);
#endif
@@ -967,7 +967,7 @@ EXTERN(JDIMENSION) jpeg_write_raw_data (j_compress_ptr cinfo, JSAMPIMAGE data,
/* Write a special marker. See libjpeg.txt concerning safe usage. */
EXTERN(void) jpeg_write_marker (j_compress_ptr cinfo, int marker,
const JOCTET * dataptr, unsigned int datalen);
const JOCTET *dataptr, unsigned int datalen);
/* Same, but piecemeal. */
EXTERN(void) jpeg_write_m_header (j_compress_ptr cinfo, int marker,
unsigned int datalen);
@@ -1033,7 +1033,7 @@ EXTERN(void) jpeg_set_marker_processor (j_decompress_ptr cinfo,
/* Read or write raw DCT coefficients --- useful for lossless transcoding. */
EXTERN(jvirt_barray_ptr *) jpeg_read_coefficients (j_decompress_ptr cinfo);
EXTERN(void) jpeg_write_coefficients (j_compress_ptr cinfo,
jvirt_barray_ptr * coef_arrays);
jvirt_barray_ptr *coef_arrays);
EXTERN(void) jpeg_copy_critical_parameters (j_decompress_ptr srcinfo,
j_compress_ptr dstinfo);

View File

@@ -39,8 +39,8 @@
*/
static const char * progname; /* program name for error messages */
static char * outfilename; /* for -outfile switch */
static const char *progname; /* program name for error messages */
static char *outfilename; /* for -outfile switch */
static JCOPY_OPTION copyoption; /* -copy switch */
static jpeg_transform_info transformoption; /* image transformation options */
@@ -132,9 +132,9 @@ parse_switches (j_compress_ptr cinfo, int argc, char **argv,
*/
{
int argn;
char * arg;
char *arg;
boolean simple_progressive;
char * scansarg = NULL; /* saves -scans parm if any */
char *scansarg = NULL; /* saves -scans parm if any */
/* Set up default JPEG parameters. */
simple_progressive = FALSE;
@@ -378,13 +378,13 @@ main (int argc, char **argv)
#ifdef PROGRESS_REPORT
struct cdjpeg_progress_mgr progress;
#endif
jvirt_barray_ptr * src_coef_arrays;
jvirt_barray_ptr * dst_coef_arrays;
jvirt_barray_ptr *src_coef_arrays;
jvirt_barray_ptr *dst_coef_arrays;
int file_index;
/* We assume all-in-memory processing and can therefore use only a
* single file pointer for sequential input and output operation.
*/
FILE * fp;
FILE *fp;
/* On Mac, fetch a command line. */
#ifdef USE_CCOMMAND

View File

@@ -164,7 +164,7 @@ typedef struct {
boolean on_odd_row; /* flag to remember which row we are on */
} my_cquantizer;
typedef my_cquantizer * my_cquantize_ptr;
typedef my_cquantizer *my_cquantize_ptr;
/*
@@ -523,7 +523,7 @@ quantize_ord_dither (j_decompress_ptr cinfo, JSAMPARRAY input_buf,
register JSAMPROW input_ptr;
register JSAMPROW output_ptr;
JSAMPROW colorindex_ci;
int * dither; /* points to active row of dither matrix */
int *dither; /* points to active row of dither matrix */
int row_index, col_index; /* current indexes into dither matrix */
int nc = cinfo->out_color_components;
int ci;
@@ -575,9 +575,9 @@ quantize3_ord_dither (j_decompress_ptr cinfo, JSAMPARRAY input_buf,
JSAMPROW colorindex0 = cquantize->colorindex[0];
JSAMPROW colorindex1 = cquantize->colorindex[1];
JSAMPROW colorindex2 = cquantize->colorindex[2];
int * dither0; /* points to active row of dither matrix */
int * dither1;
int * dither2;
int *dither0; /* points to active row of dither matrix */
int *dither1;
int *dither2;
int row_index, col_index; /* current indexes into dither matrix */
int row;
JDIMENSION col;

View File

@@ -128,11 +128,11 @@ static const int c_scales[3]={R_SCALE, G_SCALE, B_SCALE};
typedef UINT16 histcell; /* histogram cell; prefer an unsigned type */
typedef histcell * histptr; /* for pointers to histogram cells */
typedef histcell *histptr; /* for pointers to histogram cells */
typedef histcell hist1d[HIST_C2_ELEMS]; /* typedefs for the array */
typedef hist1d * hist2d; /* type for the 2nd-level pointers */
typedef hist2d * hist3d; /* type for top-level pointer */
typedef hist1d *hist2d; /* type for the 2nd-level pointers */
typedef hist2d *hist3d; /* type for top-level pointer */
/* Declarations for Floyd-Steinberg dithering.
@@ -184,10 +184,10 @@ typedef struct {
/* Variables for Floyd-Steinberg dithering */
FSERRPTR fserrors; /* accumulated errors */
boolean on_odd_row; /* flag to remember which row we are on */
int * error_limiter; /* table for clamping the applied error */
int *error_limiter; /* table for clamping the applied error */
} my_cquantizer;
typedef my_cquantizer * my_cquantize_ptr;
typedef my_cquantizer *my_cquantize_ptr;
/*
@@ -245,7 +245,7 @@ typedef struct {
long colorcount;
} box;
typedef box * boxptr;
typedef box *boxptr;
LOCAL(boxptr)
@@ -763,8 +763,8 @@ find_best_colors (j_decompress_ptr cinfo, int minc0, int minc1, int minc2,
{
int ic0, ic1, ic2;
int i, icolor;
register JLONG * bptr; /* pointer into bestdist[] array */
JSAMPLE * cptr; /* pointer into bestcolor[] array */
register JLONG *bptr; /* pointer into bestdist[] array */
JSAMPLE *cptr; /* pointer into bestcolor[] array */
JLONG dist0, dist1; /* initial distance values */
register JLONG dist2; /* current distance in inner loop */
JLONG xx0, xx1; /* distance increments */
@@ -841,7 +841,7 @@ fill_inverse_cmap (j_decompress_ptr cinfo, int c0, int c1, int c2)
hist3d histogram = cquantize->histogram;
int minc0, minc1, minc2; /* lower left corner of update box */
int ic0, ic1, ic2;
register JSAMPLE * cptr; /* pointer into bestcolor[] array */
register JSAMPLE *cptr; /* pointer into bestcolor[] array */
register histptr cachep; /* pointer into main cache array */
/* This array lists the candidate colormap indexes. */
JSAMPLE colorlist[MAXNUMCOLORS];
@@ -1080,7 +1080,7 @@ init_error_limit (j_decompress_ptr cinfo)
/* Allocate and fill in the error_limiter table */
{
my_cquantize_ptr cquantize = (my_cquantize_ptr) cinfo->cquantize;
int * table;
int *table;
int in, out;
table = (int *) (*cinfo->mem->alloc_small)

28
jsimd.h
View File

@@ -39,17 +39,17 @@ EXTERN(int) jsimd_can_h2v2_downsample (void);
EXTERN(int) jsimd_can_h2v1_downsample (void);
EXTERN(void) jsimd_h2v2_downsample
(j_compress_ptr cinfo, jpeg_component_info * compptr,
(j_compress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY output_data);
EXTERN(int) jsimd_can_h2v2_smooth_downsample (void);
EXTERN(void) jsimd_h2v2_smooth_downsample
(j_compress_ptr cinfo, jpeg_component_info * compptr,
(j_compress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY output_data);
EXTERN(void) jsimd_h2v1_downsample
(j_compress_ptr cinfo, jpeg_component_info * compptr,
(j_compress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY output_data);
EXTERN(int) jsimd_can_h2v2_upsample (void);
@@ -57,24 +57,24 @@ EXTERN(int) jsimd_can_h2v1_upsample (void);
EXTERN(int) jsimd_can_int_upsample (void);
EXTERN(void) jsimd_h2v2_upsample
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
JSAMPARRAY input_data, JSAMPARRAY * output_data_ptr);
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr);
EXTERN(void) jsimd_h2v1_upsample
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
JSAMPARRAY input_data, JSAMPARRAY * output_data_ptr);
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr);
EXTERN(void) jsimd_int_upsample
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
JSAMPARRAY input_data, JSAMPARRAY * output_data_ptr);
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr);
EXTERN(int) jsimd_can_h2v2_fancy_upsample (void);
EXTERN(int) jsimd_can_h2v1_fancy_upsample (void);
EXTERN(void) jsimd_h2v2_fancy_upsample
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
JSAMPARRAY input_data, JSAMPARRAY * output_data_ptr);
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr);
EXTERN(void) jsimd_h2v1_fancy_upsample
(j_decompress_ptr cinfo, jpeg_component_info * compptr,
JSAMPARRAY input_data, JSAMPARRAY * output_data_ptr);
(j_decompress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr);
EXTERN(int) jsimd_can_h2v2_merged_upsample (void);
EXTERN(int) jsimd_can_h2v1_merged_upsample (void);
@@ -89,5 +89,5 @@ EXTERN(void) jsimd_h2v1_merged_upsample
EXTERN(int) jsimd_can_huff_encode_one_block (void);
EXTERN(JOCTET*) jsimd_huff_encode_one_block
(void * state, JOCTET *buffer, JCOEFPTR block, int last_dc_val,
(void *state, JOCTET *buffer, JCOEFPTR block, int last_dc_val,
c_derived_tbl *dctbl, c_derived_tbl *actbl);

View File

@@ -103,19 +103,20 @@ jsimd_can_h2v2_smooth_downsample (void)
}
GLOBAL(void)
jsimd_h2v2_downsample (j_compress_ptr cinfo, jpeg_component_info * compptr,
jsimd_h2v2_downsample (j_compress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY output_data)
{
}
GLOBAL(void)
jsimd_h2v2_smooth_downsample (j_compress_ptr cinfo, jpeg_component_info * compptr,
JSAMPARRAY input_data, JSAMPARRAY output_data)
jsimd_h2v2_smooth_downsample (j_compress_ptr cinfo,
jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY output_data)
{
}
GLOBAL(void)
jsimd_h2v1_downsample (j_compress_ptr cinfo, jpeg_component_info * compptr,
jsimd_h2v1_downsample (j_compress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY output_data)
{
}
@@ -139,24 +140,24 @@ jsimd_can_int_upsample (void)
}
GLOBAL(void)
jsimd_int_upsample (j_decompress_ptr cinfo, jpeg_component_info * compptr,
JSAMPARRAY input_data, JSAMPARRAY * output_data_ptr)
jsimd_int_upsample (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JSAMPARRAY input_data, JSAMPARRAY *output_data_ptr)
{
}
GLOBAL(void)
jsimd_h2v2_upsample (j_decompress_ptr cinfo,
jpeg_component_info * compptr,
jpeg_component_info *compptr,
JSAMPARRAY input_data,
JSAMPARRAY * output_data_ptr)
JSAMPARRAY *output_data_ptr)
{
}
GLOBAL(void)
jsimd_h2v1_upsample (j_decompress_ptr cinfo,
jpeg_component_info * compptr,
jpeg_component_info *compptr,
JSAMPARRAY input_data,
JSAMPARRAY * output_data_ptr)
JSAMPARRAY *output_data_ptr)
{
}
@@ -174,17 +175,17 @@ jsimd_can_h2v1_fancy_upsample (void)
GLOBAL(void)
jsimd_h2v2_fancy_upsample (j_decompress_ptr cinfo,
jpeg_component_info * compptr,
jpeg_component_info *compptr,
JSAMPARRAY input_data,
JSAMPARRAY * output_data_ptr)
JSAMPARRAY *output_data_ptr)
{
}
GLOBAL(void)
jsimd_h2v1_fancy_upsample (j_decompress_ptr cinfo,
jpeg_component_info * compptr,
jpeg_component_info *compptr,
JSAMPARRAY input_data,
JSAMPARRAY * output_data_ptr)
JSAMPARRAY *output_data_ptr)
{
}
@@ -230,13 +231,13 @@ jsimd_can_convsamp_float (void)
GLOBAL(void)
jsimd_convsamp (JSAMPARRAY sample_data, JDIMENSION start_col,
DCTELEM * workspace)
DCTELEM *workspace)
{
}
GLOBAL(void)
jsimd_convsamp_float (JSAMPARRAY sample_data, JDIMENSION start_col,
FAST_FLOAT * workspace)
FAST_FLOAT *workspace)
{
}
@@ -259,17 +260,17 @@ jsimd_can_fdct_float (void)
}
GLOBAL(void)
jsimd_fdct_islow (DCTELEM * data)
jsimd_fdct_islow (DCTELEM *data)
{
}
GLOBAL(void)
jsimd_fdct_ifast (DCTELEM * data)
jsimd_fdct_ifast (DCTELEM *data)
{
}
GLOBAL(void)
jsimd_fdct_float (FAST_FLOAT * data)
jsimd_fdct_float (FAST_FLOAT *data)
{
}
@@ -286,14 +287,14 @@ jsimd_can_quantize_float (void)
}
GLOBAL(void)
jsimd_quantize (JCOEFPTR coef_block, DCTELEM * divisors,
DCTELEM * workspace)
jsimd_quantize (JCOEFPTR coef_block, DCTELEM *divisors,
DCTELEM *workspace)
{
}
GLOBAL(void)
jsimd_quantize_float (JCOEFPTR coef_block, FAST_FLOAT * divisors,
FAST_FLOAT * workspace)
jsimd_quantize_float (JCOEFPTR coef_block, FAST_FLOAT *divisors,
FAST_FLOAT *workspace)
{
}
@@ -322,28 +323,28 @@ jsimd_can_idct_12x12 (void)
}
GLOBAL(void)
jsimd_idct_2x2 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jsimd_idct_2x2 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf,
JDIMENSION output_col)
{
}
GLOBAL(void)
jsimd_idct_4x4 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jsimd_idct_4x4 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf,
JDIMENSION output_col)
{
}
GLOBAL(void)
jsimd_idct_6x6 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jsimd_idct_6x6 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf,
JDIMENSION output_col)
{
}
GLOBAL(void)
jsimd_idct_12x12 (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jsimd_idct_12x12 (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf,
JDIMENSION output_col)
{
@@ -368,21 +369,21 @@ jsimd_can_idct_float (void)
}
GLOBAL(void)
jsimd_idct_islow (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jsimd_idct_islow (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf,
JDIMENSION output_col)
{
}
GLOBAL(void)
jsimd_idct_ifast (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jsimd_idct_ifast (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf,
JDIMENSION output_col)
{
}
GLOBAL(void)
jsimd_idct_float (j_decompress_ptr cinfo, jpeg_component_info * compptr,
jsimd_idct_float (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf,
JDIMENSION output_col)
{
@@ -395,7 +396,7 @@ jsimd_can_huff_encode_one_block (void)
}
GLOBAL(JOCTET*)
jsimd_huff_encode_one_block (void * state, JOCTET *buffer, JCOEFPTR block,
jsimd_huff_encode_one_block (void *state, JOCTET *buffer, JCOEFPTR block,
int last_dc_val, c_derived_tbl *dctbl,
c_derived_tbl *actbl)
{

View File

@@ -13,26 +13,26 @@ EXTERN(int) jsimd_can_convsamp (void);
EXTERN(int) jsimd_can_convsamp_float (void);
EXTERN(void) jsimd_convsamp (JSAMPARRAY sample_data, JDIMENSION start_col,
DCTELEM * workspace);
DCTELEM *workspace);
EXTERN(void) jsimd_convsamp_float (JSAMPARRAY sample_data,
JDIMENSION start_col,
FAST_FLOAT * workspace);
FAST_FLOAT *workspace);
EXTERN(int) jsimd_can_fdct_islow (void);
EXTERN(int) jsimd_can_fdct_ifast (void);
EXTERN(int) jsimd_can_fdct_float (void);
EXTERN(void) jsimd_fdct_islow (DCTELEM * data);
EXTERN(void) jsimd_fdct_ifast (DCTELEM * data);
EXTERN(void) jsimd_fdct_float (FAST_FLOAT * data);
EXTERN(void) jsimd_fdct_islow (DCTELEM *data);
EXTERN(void) jsimd_fdct_ifast (DCTELEM *data);
EXTERN(void) jsimd_fdct_float (FAST_FLOAT *data);
EXTERN(int) jsimd_can_quantize (void);
EXTERN(int) jsimd_can_quantize_float (void);
EXTERN(void) jsimd_quantize (JCOEFPTR coef_block, DCTELEM * divisors,
DCTELEM * workspace);
EXTERN(void) jsimd_quantize_float (JCOEFPTR coef_block, FAST_FLOAT * divisors,
FAST_FLOAT * workspace);
EXTERN(void) jsimd_quantize (JCOEFPTR coef_block, DCTELEM *divisors,
DCTELEM *workspace);
EXTERN(void) jsimd_quantize_float (JCOEFPTR coef_block, FAST_FLOAT *divisors,
FAST_FLOAT *workspace);
EXTERN(int) jsimd_can_idct_2x2 (void);
EXTERN(int) jsimd_can_idct_4x4 (void);
@@ -40,19 +40,19 @@ EXTERN(int) jsimd_can_idct_6x6 (void);
EXTERN(int) jsimd_can_idct_12x12 (void);
EXTERN(void) jsimd_idct_2x2 (j_decompress_ptr cinfo,
jpeg_component_info * compptr,
jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf,
JDIMENSION output_col);
EXTERN(void) jsimd_idct_4x4 (j_decompress_ptr cinfo,
jpeg_component_info * compptr,
jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf,
JDIMENSION output_col);
EXTERN(void) jsimd_idct_6x6 (j_decompress_ptr cinfo,
jpeg_component_info * compptr,
jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf,
JDIMENSION output_col);
EXTERN(void) jsimd_idct_12x12 (j_decompress_ptr cinfo,
jpeg_component_info * compptr,
jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf,
JDIMENSION output_col);
@@ -61,14 +61,14 @@ EXTERN(int) jsimd_can_idct_ifast (void);
EXTERN(int) jsimd_can_idct_float (void);
EXTERN(void) jsimd_idct_islow (j_decompress_ptr cinfo,
jpeg_component_info * compptr,
jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf,
JDIMENSION output_col);
EXTERN(void) jsimd_idct_ifast (j_decompress_ptr cinfo,
jpeg_component_info * compptr,
jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf,
JDIMENSION output_col);
EXTERN(void) jsimd_idct_float (j_decompress_ptr cinfo,
jpeg_component_info * compptr,
jpeg_component_info *compptr,
JCOEFPTR coef_block, JSAMPARRAY output_buf,
JDIMENSION output_col);

View File

@@ -125,7 +125,7 @@ jcopy_block_row (JBLOCKROW input_row, JBLOCKROW output_row,
GLOBAL(void)
jzero_far (void * target, size_t bytestozero)
jzero_far (void *target, size_t bytestozero)
/* Zero out a chunk of memory. */
/* This might be sample-array data, block-array data, or alloc_large data. */
{

View File

@@ -293,7 +293,7 @@ destination module if you want to do something else, as discussed later.
If you use the standard destination module, you must open the target stdio
stream beforehand. Typical code for this step looks like:
FILE * outfile;
FILE *outfile;
...
if ((outfile = fopen(filename, "wb")) == NULL) {
fprintf(stderr, "can't open %s\n", filename);
@@ -540,7 +540,7 @@ to do something else, as discussed later.
If you use the standard source module, you must open the source stdio stream
beforehand. Typical code for this step looks like:
FILE * infile;
FILE *infile;
...
if ((infile = fopen(filename, "rb")) == NULL) {
fprintf(stderr, "can't open %s\n", filename);
@@ -976,7 +976,7 @@ int restart_in_rows
If you use restarts, you may want to use larger intervals in those
cases.
const jpeg_scan_info * scan_info
const jpeg_scan_info *scan_info
int num_scans
By default, scan_info is NULL; this causes the compressor to write a
single-scan sequential JPEG file. If not NULL, scan_info points to
@@ -1022,7 +1022,7 @@ boolean write_Adobe_marker
default behavior ensures that the JPEG file's color space can be
recognized by the decoder.
JQUANT_TBL * quant_tbl_ptrs[NUM_QUANT_TBLS]
JQUANT_TBL *quant_tbl_ptrs[NUM_QUANT_TBLS]
Pointers to coefficient quantization tables, one per table slot,
or NULL if no table is defined for a slot. Usually these should
be set via one of the above helper routines; jpeg_add_quant_table()
@@ -1057,8 +1057,8 @@ int q_scale_factor[NUM_QUANT_TBLS]
cinfo->comp_info[0].v_samp_factor = 1;
cinfo->comp_info[0].h_samp_factor = 1;
JHUFF_TBL * dc_huff_tbl_ptrs[NUM_HUFF_TBLS]
JHUFF_TBL * ac_huff_tbl_ptrs[NUM_HUFF_TBLS]
JHUFF_TBL *dc_huff_tbl_ptrs[NUM_HUFF_TBLS]
JHUFF_TBL *ac_huff_tbl_ptrs[NUM_HUFF_TBLS]
Pointers to Huffman coding tables, one per table slot, or NULL if
no table is defined for a slot. Slots 0 and 1 are filled with the
JPEG sample tables by jpeg_set_defaults(). If you need to allocate
@@ -1442,7 +1442,7 @@ output_message (j_common_ptr cinfo)
somewhere other than stderr. Note that this method does not know
how to generate a message, only where to send it.
format_message (j_common_ptr cinfo, char * buffer)
format_message (j_common_ptr cinfo, char *buffer)
Constructs a readable error message string based on the error info
stored in cinfo->err. This method is called by output_message. Few
applications should need to override this method. One possible
@@ -1519,7 +1519,7 @@ on external storage.
A data destination manager struct contains a pointer and count defining the
next byte to write in the work buffer and the remaining free space:
JOCTET * next_output_byte; /* => next byte to write in buffer */
JOCTET *next_output_byte; /* => next byte to write in buffer */
size_t free_in_buffer; /* # of byte spaces remaining in buffer */
The library increments the pointer and decrements the count until the buffer
@@ -1568,7 +1568,7 @@ additional frammishes. The source manager struct contains a pointer and count
defining the next byte to read from the work buffer and the number of bytes
remaining:
const JOCTET * next_input_byte; /* => next byte to read from buffer */
const JOCTET *next_input_byte; /* => next byte to read from buffer */
size_t bytes_in_buffer; /* # of bytes remaining in buffer */
The library increments the pointer and decrements the count until the buffer

View File

@@ -52,7 +52,7 @@ typedef char U_CHAR;
/* Private version of data source object */
typedef struct _bmp_source_struct * bmp_source_ptr;
typedef struct _bmp_source_struct *bmp_source_ptr;
typedef struct _bmp_source_struct {
struct cjpeg_source_struct pub; /* public fields */

View File

@@ -77,7 +77,7 @@ add_map_entry (j_decompress_ptr cinfo, int R, int G, int B)
*/
LOCAL(void)
read_gif_map (j_decompress_ptr cinfo, FILE * infile)
read_gif_map (j_decompress_ptr cinfo, FILE *infile)
{
int header[13];
int i, colormaplen;
@@ -119,7 +119,7 @@ read_gif_map (j_decompress_ptr cinfo, FILE * infile)
LOCAL(int)
pbm_getc (FILE * infile)
pbm_getc (FILE *infile)
/* Read next char, skipping over any comments */
/* A comment/newline sequence is returned as a newline */
{
@@ -136,7 +136,7 @@ pbm_getc (FILE * infile)
LOCAL(unsigned int)
read_pbm_integer (j_decompress_ptr cinfo, FILE * infile)
read_pbm_integer (j_decompress_ptr cinfo, FILE *infile)
/* Read an unsigned decimal integer from the PPM file */
/* Swallows one trailing character after the integer */
/* Note that on a 16-bit-int machine, only values up to 64k can be read. */
@@ -169,7 +169,7 @@ read_pbm_integer (j_decompress_ptr cinfo, FILE * infile)
*/
LOCAL(void)
read_ppm_map (j_decompress_ptr cinfo, FILE * infile)
read_ppm_map (j_decompress_ptr cinfo, FILE *infile)
{
int c;
unsigned int w, h, maxval, row, col;
@@ -229,7 +229,7 @@ read_ppm_map (j_decompress_ptr cinfo, FILE * infile)
*/
GLOBAL(void)
read_color_map (j_decompress_ptr cinfo, FILE * infile)
read_color_map (j_decompress_ptr cinfo, FILE *infile)
{
/* Allocate space for a color map of maximum supported size. */
cinfo->colormap = (*cinfo->mem->alloc_sarray)

View File

@@ -57,7 +57,7 @@
* To reuse this code in another application, you might need to change these.
*/
static FILE * infile; /* input JPEG file */
static FILE *infile; /* input JPEG file */
/* Return next input byte, or EOF if no more */
#define NEXTBYTE() getc(infile)
@@ -279,7 +279,7 @@ process_SOFn (int marker)
unsigned int length;
unsigned int image_height, image_width;
int data_precision, num_components;
const char * process;
const char *process;
int ci;
length = read_2_bytes(); /* usual parameter length count */
@@ -397,7 +397,7 @@ scan_JPEG_header (int verbose, int raw)
/* Command line parsing code */
static const char * progname; /* program name for error messages */
static const char *progname; /* program name for error messages */
static void
@@ -417,7 +417,7 @@ usage (void)
static int
keymatch (char * arg, const char * keyword, int minchars)
keymatch (char *arg, const char *keyword, int minchars)
/* Case-insensitive matching of (possibly abbreviated) keyword switches. */
/* keyword is the constant keyword (must be lower case already), */
/* minchars is length of minimum legal abbreviation. */
@@ -449,7 +449,7 @@ int
main (int argc, char **argv)
{
int argn;
char * arg;
char *arg;
int verbose = 0, raw = 0;
/* On Mac, fetch a command line. */

18
rdppm.c
View File

@@ -72,11 +72,11 @@ typedef struct {
int maxval;
} ppm_source_struct;
typedef ppm_source_struct * ppm_source_ptr;
typedef ppm_source_struct *ppm_source_ptr;
LOCAL(int)
pbm_getc (FILE * infile)
pbm_getc (FILE *infile)
/* Read next char, skipping over any comments */
/* A comment/newline sequence is returned as a newline */
{
@@ -93,7 +93,7 @@ pbm_getc (FILE * infile)
LOCAL(unsigned int)
read_pbm_integer (j_compress_ptr cinfo, FILE * infile, unsigned int maxval)
read_pbm_integer (j_compress_ptr cinfo, FILE *infile, unsigned int maxval)
/* Read an unsigned decimal integer from the PPM file */
/* Swallows one trailing character after the integer */
/* Note that on a 16-bit-int machine, only values up to 64k can be read. */
@@ -141,7 +141,7 @@ get_text_gray_row (j_compress_ptr cinfo, cjpeg_source_ptr sinfo)
/* This version is for reading text-format PGM files with any maxval */
{
ppm_source_ptr source = (ppm_source_ptr) sinfo;
FILE * infile = source->pub.input_file;
FILE *infile = source->pub.input_file;
register JSAMPROW ptr;
register JSAMPLE *rescale = source->rescale;
JDIMENSION col;
@@ -160,7 +160,7 @@ get_text_rgb_row (j_compress_ptr cinfo, cjpeg_source_ptr sinfo)
/* This version is for reading text-format PPM files with any maxval */
{
ppm_source_ptr source = (ppm_source_ptr) sinfo;
FILE * infile = source->pub.input_file;
FILE *infile = source->pub.input_file;
register JSAMPROW ptr;
register JSAMPLE *rescale = source->rescale;
JDIMENSION col;
@@ -182,7 +182,7 @@ get_scaled_gray_row (j_compress_ptr cinfo, cjpeg_source_ptr sinfo)
{
ppm_source_ptr source = (ppm_source_ptr) sinfo;
register JSAMPROW ptr;
register U_CHAR * bufferptr;
register U_CHAR *bufferptr;
register JSAMPLE *rescale = source->rescale;
JDIMENSION col;
@@ -203,7 +203,7 @@ get_scaled_rgb_row (j_compress_ptr cinfo, cjpeg_source_ptr sinfo)
{
ppm_source_ptr source = (ppm_source_ptr) sinfo;
register JSAMPROW ptr;
register U_CHAR * bufferptr;
register U_CHAR *bufferptr;
register JSAMPLE *rescale = source->rescale;
JDIMENSION col;
@@ -241,7 +241,7 @@ get_word_gray_row (j_compress_ptr cinfo, cjpeg_source_ptr sinfo)
{
ppm_source_ptr source = (ppm_source_ptr) sinfo;
register JSAMPROW ptr;
register U_CHAR * bufferptr;
register U_CHAR *bufferptr;
register JSAMPLE *rescale = source->rescale;
JDIMENSION col;
@@ -265,7 +265,7 @@ get_word_rgb_row (j_compress_ptr cinfo, cjpeg_source_ptr sinfo)
{
ppm_source_ptr source = (ppm_source_ptr) sinfo;
register JSAMPROW ptr;
register U_CHAR * bufferptr;
register U_CHAR *bufferptr;
register JSAMPLE *rescale = source->rescale;
JDIMENSION col;

View File

@@ -62,7 +62,7 @@ typedef enum
* then fetch the required row from the virtual array on subsequent calls.
*/
typedef struct _rle_source_struct * rle_source_ptr;
typedef struct _rle_source_struct *rle_source_ptr;
typedef struct _rle_source_struct {
struct cjpeg_source_struct pub; /* public fields */
@@ -216,7 +216,7 @@ get_pseudocolor_row (j_compress_ptr cinfo, cjpeg_source_ptr sinfo)
colormap = source->header.cmap;
dest_row = source->pub.buffer[0];
source->row--;
src_row = * (*cinfo->mem->access_virt_sarray)
src_row = *(*cinfo->mem->access_virt_sarray)
((j_common_ptr) cinfo, source->image, source->row, (JDIMENSION) 1, FALSE);
for (col = cinfo->image_width; col > 0; col--) {
@@ -289,7 +289,7 @@ load_image (j_compress_ptr cinfo, cjpeg_source_ptr sinfo)
case MAPPEDGRAY:
case TRUECOLOR:
for (row = 0; row < cinfo->image_height; row++) {
scanline = * (*cinfo->mem->access_virt_sarray)
scanline = *(*cinfo->mem->access_virt_sarray)
((j_common_ptr) cinfo, source->image, row, (JDIMENSION) 1, TRUE);
rle_row = source->rle_row;
rle_getrow(&source->header, rle_row);
@@ -312,7 +312,7 @@ load_image (j_compress_ptr cinfo, cjpeg_source_ptr sinfo)
case DIRECTCOLOR:
for (row = 0; row < cinfo->image_height; row++) {
scanline = * (*cinfo->mem->access_virt_sarray)
scanline = *(*cinfo->mem->access_virt_sarray)
((j_common_ptr) cinfo, source->image, row, (JDIMENSION) 1, TRUE);
rle_getrow(&source->header, rle_row);

View File

@@ -22,7 +22,7 @@
LOCAL(int)
text_getc (FILE * file)
text_getc (FILE *file)
/* Read next char, skipping over any comments (# to end of line) */
/* A comment/newline sequence is returned as a newline */
{
@@ -39,7 +39,7 @@ text_getc (FILE * file)
LOCAL(boolean)
read_text_integer (FILE * file, long * result, int * termchar)
read_text_integer (FILE *file, long *result, int *termchar)
/* Read an unsigned decimal integer from a file, store it in result */
/* Reads one trailing character after the integer; returns it in termchar */
{
@@ -78,7 +78,8 @@ static int q_scale_factor[NUM_QUANT_TBLS] = {100, 100, 100, 100};
#endif
GLOBAL(boolean)
read_quant_tables (j_compress_ptr cinfo, char * filename, boolean force_baseline)
read_quant_tables (j_compress_ptr cinfo, char *filename,
boolean force_baseline)
/* Read a set of quantization tables from the specified file.
* The file is plain ASCII text: decimal numbers with whitespace between.
* Comments preceded by '#' may be included in the file.
@@ -89,7 +90,7 @@ read_quant_tables (j_compress_ptr cinfo, char * filename, boolean force_baseline
* You must use -qslots if you want a different component->table mapping.
*/
{
FILE * fp;
FILE *fp;
int tblno, i, termchar;
long val;
unsigned int table[DCTSIZE2];
@@ -139,7 +140,7 @@ read_quant_tables (j_compress_ptr cinfo, char * filename, boolean force_baseline
#ifdef C_MULTISCAN_FILES_SUPPORTED
LOCAL(boolean)
read_scan_integer (FILE * file, long * result, int * termchar)
read_scan_integer (FILE *file, long *result, int *termchar)
/* Variant of read_text_integer that always looks for a non-space termchar;
* this simplifies parsing of punctuation in scan scripts.
*/
@@ -168,7 +169,7 @@ read_scan_integer (FILE * file, long * result, int * termchar)
GLOBAL(boolean)
read_scan_script (j_compress_ptr cinfo, char * filename)
read_scan_script (j_compress_ptr cinfo, char *filename)
/* Read a scan script from the specified text file.
* Each entry in the file defines one scan to be emitted.
* Entries are separated by semicolons ';'.
@@ -185,10 +186,10 @@ read_scan_script (j_compress_ptr cinfo, char * filename)
* jcmaster.c will validate the script parameters.
*/
{
FILE * fp;
FILE *fp;
int scanno, ncomps, termchar;
long val;
jpeg_scan_info * scanptr;
jpeg_scan_info *scanptr;
#define MAX_SCANS 100 /* quite arbitrary limit */
jpeg_scan_info scans[MAX_SCANS];

View File

@@ -46,7 +46,7 @@ typedef char U_CHAR;
/* Private version of data source object */
typedef struct _tga_source_struct * tga_source_ptr;
typedef struct _tga_source_struct *tga_source_ptr;
typedef struct _tga_source_struct {
struct cjpeg_source_struct pub; /* public fields */

View File

@@ -165,7 +165,7 @@ EXTN(jconst_huff_encode_one_block):
; Encode a single block's worth of coefficients.
;
; GLOBAL(JOCTET*)
; jsimd_huff_encode_one_block_sse2 (working_state * state, JOCTET *buffer,
; jsimd_huff_encode_one_block_sse2 (working_state *state, JOCTET *buffer,
; JCOEFPTR block, int last_dc_val,
; c_derived_tbl *dctbl, c_derived_tbl *actbl)
;

View File

@@ -152,7 +152,7 @@ EXTN(jconst_huff_encode_one_block):
; Encode a single block's worth of coefficients.
;
; GLOBAL(JOCTET*)
; jsimd_huff_encode_one_block_sse2 (working_state * state, JOCTET *buffer,
; jsimd_huff_encode_one_block_sse2 (working_state *state, JOCTET *buffer,
; JCOEFPTR block, int last_dc_val,
; c_derived_tbl *dctbl, c_derived_tbl *actbl)
;
@@ -175,7 +175,7 @@ EXTN(jconst_huff_encode_one_block):
%define temp3 temp2+SIZEOF_DWORD
%define temp4 temp3+SIZEOF_DWORD
%define temp5 temp4+SIZEOF_DWORD
%define gotptr temp5+SIZEOF_DWORD ; void * gotptr
%define gotptr temp5+SIZEOF_DWORD ; void *gotptr
%define put_buffer ebx
%define put_bits edi

View File

@@ -310,7 +310,7 @@ void
jsimd_h2v1_upsample_altivec (int max_v_samp_factor,
JDIMENSION output_width,
JSAMPARRAY input_data,
JSAMPARRAY * output_data_ptr)
JSAMPARRAY *output_data_ptr)
{
JSAMPARRAY output_data = *output_data_ptr;
JSAMPROW inptr, outptr;
@@ -349,7 +349,7 @@ void
jsimd_h2v2_upsample_altivec (int max_v_samp_factor,
JDIMENSION output_width,
JSAMPARRAY input_data,
JSAMPARRAY * output_data_ptr)
JSAMPARRAY *output_data_ptr)
{
JSAMPARRAY output_data = *output_data_ptr;
JSAMPROW inptr, outptr0, outptr1;

View File

@@ -49,13 +49,13 @@ PW_EIGHT times 4 dw 8
; jsimd_h2v1_fancy_upsample_mmx (int max_v_samp_factor,
; JDIMENSION downsampled_width,
; JSAMPARRAY input_data,
; JSAMPARRAY * output_data_ptr);
; JSAMPARRAY *output_data_ptr);
;
%define max_v_samp(b) (b)+8 ; int max_v_samp_factor
%define downsamp_width(b) (b)+12 ; JDIMENSION downsampled_width
%define input_data(b) (b)+16 ; JSAMPARRAY input_data
%define output_data_ptr(b) (b)+20 ; JSAMPARRAY * output_data_ptr
%define output_data_ptr(b) (b)+20 ; JSAMPARRAY *output_data_ptr
align 16
global EXTN(jsimd_h2v1_fancy_upsample_mmx)
@@ -202,18 +202,18 @@ EXTN(jsimd_h2v1_fancy_upsample_mmx):
; jsimd_h2v2_fancy_upsample_mmx (int max_v_samp_factor,
; JDIMENSION downsampled_width,
; JSAMPARRAY input_data,
; JSAMPARRAY * output_data_ptr);
; JSAMPARRAY *output_data_ptr);
;
%define max_v_samp(b) (b)+8 ; int max_v_samp_factor
%define downsamp_width(b) (b)+12 ; JDIMENSION downsampled_width
%define input_data(b) (b)+16 ; JSAMPARRAY input_data
%define output_data_ptr(b) (b)+20 ; JSAMPARRAY * output_data_ptr
%define output_data_ptr(b) (b)+20 ; JSAMPARRAY *output_data_ptr
%define original_ebp ebp+0
%define wk(i) ebp-(WK_NUM-(i))*SIZEOF_MMWORD ; mmword wk[WK_NUM]
%define WK_NUM 4
%define gotptr wk(0)-SIZEOF_POINTER ; void * gotptr
%define gotptr wk(0)-SIZEOF_POINTER ; void *gotptr
align 16
global EXTN(jsimd_h2v2_fancy_upsample_mmx)
@@ -533,13 +533,13 @@ EXTN(jsimd_h2v2_fancy_upsample_mmx):
; jsimd_h2v1_upsample_mmx (int max_v_samp_factor,
; JDIMENSION output_width,
; JSAMPARRAY input_data,
; JSAMPARRAY * output_data_ptr);
; JSAMPARRAY *output_data_ptr);
;
%define max_v_samp(b) (b)+8 ; int max_v_samp_factor
%define output_width(b) (b)+12 ; JDIMENSION output_width
%define input_data(b) (b)+16 ; JSAMPARRAY input_data
%define output_data_ptr(b) (b)+20 ; JSAMPARRAY * output_data_ptr
%define output_data_ptr(b) (b)+20 ; JSAMPARRAY *output_data_ptr
align 16
global EXTN(jsimd_h2v1_upsample_mmx)
@@ -634,13 +634,13 @@ EXTN(jsimd_h2v1_upsample_mmx):
; jsimd_h2v2_upsample_mmx (int max_v_samp_factor,
; JDIMENSION output_width,
; JSAMPARRAY input_data,
; JSAMPARRAY * output_data_ptr);
; JSAMPARRAY *output_data_ptr);
;
%define max_v_samp(b) (b)+8 ; int max_v_samp_factor
%define output_width(b) (b)+12 ; JDIMENSION output_width
%define input_data(b) (b)+16 ; JSAMPARRAY input_data
%define output_data_ptr(b) (b)+20 ; JSAMPARRAY * output_data_ptr
%define output_data_ptr(b) (b)+20 ; JSAMPARRAY *output_data_ptr
align 16
global EXTN(jsimd_h2v2_upsample_mmx)

View File

@@ -50,13 +50,13 @@ PW_EIGHT times 8 dw 8
; jsimd_h2v1_fancy_upsample_sse2 (int max_v_samp_factor,
; JDIMENSION downsampled_width,
; JSAMPARRAY input_data,
; JSAMPARRAY * output_data_ptr);
; JSAMPARRAY *output_data_ptr);
;
; r10 = int max_v_samp_factor
; r11 = JDIMENSION downsampled_width
; r12 = JSAMPARRAY input_data
; r13 = JSAMPARRAY * output_data_ptr
; r13 = JSAMPARRAY *output_data_ptr
align 16
global EXTN(jsimd_h2v1_fancy_upsample_sse2)
@@ -189,13 +189,13 @@ EXTN(jsimd_h2v1_fancy_upsample_sse2):
; jsimd_h2v2_fancy_upsample_sse2 (int max_v_samp_factor,
; JDIMENSION downsampled_width,
; JSAMPARRAY input_data,
; JSAMPARRAY * output_data_ptr);
; JSAMPARRAY *output_data_ptr);
;
; r10 = int max_v_samp_factor
; r11 = JDIMENSION downsampled_width
; r12 = JSAMPARRAY input_data
; r13 = JSAMPARRAY * output_data_ptr
; r13 = JSAMPARRAY *output_data_ptr
%define wk(i) rbp-(WK_NUM-(i))*SIZEOF_XMMWORD ; xmmword wk[WK_NUM]
%define WK_NUM 4
@@ -489,13 +489,13 @@ EXTN(jsimd_h2v2_fancy_upsample_sse2):
; jsimd_h2v1_upsample_sse2 (int max_v_samp_factor,
; JDIMENSION output_width,
; JSAMPARRAY input_data,
; JSAMPARRAY * output_data_ptr);
; JSAMPARRAY *output_data_ptr);
;
; r10 = int max_v_samp_factor
; r11 = JDIMENSION output_width
; r12 = JSAMPARRAY input_data
; r13 = JSAMPARRAY * output_data_ptr
; r13 = JSAMPARRAY *output_data_ptr
align 16
global EXTN(jsimd_h2v1_upsample_sse2)
@@ -578,13 +578,13 @@ EXTN(jsimd_h2v1_upsample_sse2):
; jsimd_h2v2_upsample_sse2 (nt max_v_samp_factor,
; JDIMENSION output_width,
; JSAMPARRAY input_data,
; JSAMPARRAY * output_data_ptr);
; JSAMPARRAY *output_data_ptr);
;
; r10 = int max_v_samp_factor
; r11 = JDIMENSION output_width
; r12 = JSAMPARRAY input_data
; r13 = JSAMPARRAY * output_data_ptr
; r13 = JSAMPARRAY *output_data_ptr
align 16
global EXTN(jsimd_h2v2_upsample_sse2)

View File

@@ -49,13 +49,13 @@ PW_EIGHT times 8 dw 8
; jsimd_h2v1_fancy_upsample_sse2 (int max_v_samp_factor,
; JDIMENSION downsampled_width,
; JSAMPARRAY input_data,
; JSAMPARRAY * output_data_ptr);
; JSAMPARRAY *output_data_ptr);
;
%define max_v_samp(b) (b)+8 ; int max_v_samp_factor
%define downsamp_width(b) (b)+12 ; JDIMENSION downsampled_width
%define input_data(b) (b)+16 ; JSAMPARRAY input_data
%define output_data_ptr(b) (b)+20 ; JSAMPARRAY * output_data_ptr
%define output_data_ptr(b) (b)+20 ; JSAMPARRAY *output_data_ptr
align 16
global EXTN(jsimd_h2v1_fancy_upsample_sse2)
@@ -200,18 +200,18 @@ EXTN(jsimd_h2v1_fancy_upsample_sse2):
; jsimd_h2v2_fancy_upsample_sse2 (int max_v_samp_factor,
; JDIMENSION downsampled_width,
; JSAMPARRAY input_data,
; JSAMPARRAY * output_data_ptr);
; JSAMPARRAY *output_data_ptr);
;
%define max_v_samp(b) (b)+8 ; int max_v_samp_factor
%define downsamp_width(b) (b)+12 ; JDIMENSION downsampled_width
%define input_data(b) (b)+16 ; JSAMPARRAY input_data
%define output_data_ptr(b) (b)+20 ; JSAMPARRAY * output_data_ptr
%define output_data_ptr(b) (b)+20 ; JSAMPARRAY *output_data_ptr
%define original_ebp ebp+0
%define wk(i) ebp-(WK_NUM-(i))*SIZEOF_XMMWORD ; xmmword wk[WK_NUM]
%define WK_NUM 4
%define gotptr wk(0)-SIZEOF_POINTER ; void * gotptr
%define gotptr wk(0)-SIZEOF_POINTER ; void *gotptr
align 16
global EXTN(jsimd_h2v2_fancy_upsample_sse2)
@@ -529,13 +529,13 @@ EXTN(jsimd_h2v2_fancy_upsample_sse2):
; jsimd_h2v1_upsample_sse2 (int max_v_samp_factor,
; JDIMENSION output_width,
; JSAMPARRAY input_data,
; JSAMPARRAY * output_data_ptr);
; JSAMPARRAY *output_data_ptr);
;
%define max_v_samp(b) (b)+8 ; int max_v_samp_factor
%define output_width(b) (b)+12 ; JDIMENSION output_width
%define input_data(b) (b)+16 ; JSAMPARRAY input_data
%define output_data_ptr(b) (b)+20 ; JSAMPARRAY * output_data_ptr
%define output_data_ptr(b) (b)+20 ; JSAMPARRAY *output_data_ptr
align 16
global EXTN(jsimd_h2v1_upsample_sse2)
@@ -628,13 +628,13 @@ EXTN(jsimd_h2v1_upsample_sse2):
; jsimd_h2v2_upsample_sse2 (nt max_v_samp_factor,
; JDIMENSION output_width,
; JSAMPARRAY input_data,
; JSAMPARRAY * output_data_ptr);
; JSAMPARRAY *output_data_ptr);
;
%define max_v_samp(b) (b)+8 ; int max_v_samp_factor
%define output_width(b) (b)+12 ; JDIMENSION output_width
%define input_data(b) (b)+16 ; JSAMPARRAY input_data
%define output_data_ptr(b) (b)+20 ; JSAMPARRAY * output_data_ptr
%define output_data_ptr(b) (b)+20 ; JSAMPARRAY *output_data_ptr
align 16
global EXTN(jsimd_h2v2_upsample_sse2)

View File

@@ -45,10 +45,10 @@ PD_1_306 times 2 dd 1.306562964876376527856643
; Perform the forward DCT on one block of samples.
;
; GLOBAL(void)
; jsimd_fdct_float_3dnow (FAST_FLOAT * data)
; jsimd_fdct_float_3dnow (FAST_FLOAT *data)
;
%define data(b) (b)+8 ; FAST_FLOAT * data
%define data(b) (b)+8 ; FAST_FLOAT *data
%define original_ebp ebp+0
%define wk(i) ebp-(WK_NUM-(i))*SIZEOF_MMWORD ; mmword wk[WK_NUM]

View File

@@ -56,10 +56,10 @@ PD_1_306 times 4 dd 1.306562964876376527856643
; Perform the forward DCT on one block of samples.
;
; GLOBAL(void)
; jsimd_fdct_float_sse (FAST_FLOAT * data)
; jsimd_fdct_float_sse (FAST_FLOAT *data)
;
; r10 = FAST_FLOAT * data
; r10 = FAST_FLOAT *data
%define wk(i) rbp-(WK_NUM-(i))*SIZEOF_XMMWORD ; xmmword wk[WK_NUM]
%define WK_NUM 2

View File

@@ -55,10 +55,10 @@ PD_1_306 times 4 dd 1.306562964876376527856643
; Perform the forward DCT on one block of samples.
;
; GLOBAL(void)
; jsimd_fdct_float_sse (FAST_FLOAT * data)
; jsimd_fdct_float_sse (FAST_FLOAT *data)
;
%define data(b) (b)+8 ; FAST_FLOAT * data
%define data(b) (b)+8 ; FAST_FLOAT *data
%define original_ebp ebp+0
%define wk(i) ebp-(WK_NUM-(i))*SIZEOF_XMMWORD ; xmmword wk[WK_NUM]

View File

@@ -70,10 +70,10 @@ PW_F1306 times 4 dw F_1_306 << CONST_SHIFT
; Perform the forward DCT on one block of samples.
;
; GLOBAL(void)
; jsimd_fdct_ifast_mmx (DCTELEM * data)
; jsimd_fdct_ifast_mmx (DCTELEM *data)
;
%define data(b) (b)+8 ; DCTELEM * data
%define data(b) (b)+8 ; DCTELEM *data
%define original_ebp ebp+0
%define wk(i) ebp-(WK_NUM-(i))*SIZEOF_MMWORD ; mmword wk[WK_NUM]

View File

@@ -71,10 +71,10 @@ PW_F1306 times 8 dw F_1_306 << CONST_SHIFT
; Perform the forward DCT on one block of samples.
;
; GLOBAL(void)
; jsimd_fdct_ifast_sse2 (DCTELEM * data)
; jsimd_fdct_ifast_sse2 (DCTELEM *data)
;
; r10 = DCTELEM * data
; r10 = DCTELEM *data
%define wk(i) rbp-(WK_NUM-(i))*SIZEOF_XMMWORD ; xmmword wk[WK_NUM]
%define WK_NUM 2

View File

@@ -70,10 +70,10 @@ PW_F1306 times 8 dw F_1_306 << CONST_SHIFT
; Perform the forward DCT on one block of samples.
;
; GLOBAL(void)
; jsimd_fdct_ifast_sse2 (DCTELEM * data)
; jsimd_fdct_ifast_sse2 (DCTELEM *data)
;
%define data(b) (b)+8 ; DCTELEM * data
%define data(b) (b)+8 ; DCTELEM *data
%define original_ebp ebp+0
%define wk(i) ebp-(WK_NUM-(i))*SIZEOF_XMMWORD ; xmmword wk[WK_NUM]

View File

@@ -91,10 +91,10 @@ PW_DESCALE_P2X times 4 dw 1 << (PASS1_BITS-1)
; Perform the forward DCT on one block of samples.
;
; GLOBAL(void)
; jsimd_fdct_islow_mmx (DCTELEM * data)
; jsimd_fdct_islow_mmx (DCTELEM *data)
;
%define data(b) (b)+8 ; DCTELEM * data
%define data(b) (b)+8 ; DCTELEM *data
%define original_ebp ebp+0
%define wk(i) ebp-(WK_NUM-(i))*SIZEOF_MMWORD ; mmword wk[WK_NUM]

View File

@@ -92,10 +92,10 @@ PW_DESCALE_P2X times 8 dw 1 << (PASS1_BITS-1)
; Perform the forward DCT on one block of samples.
;
; GLOBAL(void)
; jsimd_fdct_islow_sse2 (DCTELEM * data)
; jsimd_fdct_islow_sse2 (DCTELEM *data)
;
; r10 = DCTELEM * data
; r10 = DCTELEM *data
%define wk(i) rbp-(WK_NUM-(i))*SIZEOF_XMMWORD ; xmmword wk[WK_NUM]
%define WK_NUM 6

View File

@@ -91,10 +91,10 @@ PW_DESCALE_P2X times 8 dw 1 << (PASS1_BITS-1)
; Perform the forward DCT on one block of samples.
;
; GLOBAL(void)
; jsimd_fdct_islow_sse2 (DCTELEM * data)
; jsimd_fdct_islow_sse2 (DCTELEM *data)
;
%define data(b) (b)+8 ; DCTELEM * data
%define data(b) (b)+8 ; DCTELEM *data
%define original_ebp ebp+0
%define wk(i) ebp-(WK_NUM-(i))*SIZEOF_XMMWORD ; xmmword wk[WK_NUM]

View File

@@ -47,11 +47,11 @@ PB_CENTERJSAMP times 8 db CENTERJSAMPLE
; Perform dequantization and inverse DCT on one block of coefficients.
;
; GLOBAL(void)
; jsimd_idct_float_3dnow (void * dct_table, JCOEFPTR coef_block,
; jsimd_idct_float_3dnow (void *dct_table, JCOEFPTR coef_block,
; JSAMPARRAY output_buf, JDIMENSION output_col)
;
%define dct_table(b) (b)+8 ; void * dct_table
%define dct_table(b) (b)+8 ; void *dct_table
%define coef_block(b) (b)+12 ; JCOEFPTR coef_block
%define output_buf(b) (b)+16 ; JSAMPARRAY output_buf
%define output_col(b) (b)+20 ; JDIMENSION output_col
@@ -86,7 +86,7 @@ EXTN(jsimd_idct_float_3dnow):
; mov eax, [original_ebp]
mov edx, POINTER [dct_table(eax)] ; quantptr
mov esi, JCOEFPTR [coef_block(eax)] ; inptr
lea edi, [workspace] ; FAST_FLOAT * wsptr
lea edi, [workspace] ; FAST_FLOAT *wsptr
mov ecx, DCTSIZE/2 ; ctr
alignx 16,7
.columnloop:
@@ -290,7 +290,7 @@ EXTN(jsimd_idct_float_3dnow):
; ---- Pass 2: process rows from work array, store into output array.
mov eax, [original_ebp]
lea esi, [workspace] ; FAST_FLOAT * wsptr
lea esi, [workspace] ; FAST_FLOAT *wsptr
mov edi, JSAMPARRAY [output_buf(eax)] ; (JSAMPROW *)
mov eax, JDIMENSION [output_col(eax)]
mov ecx, DCTSIZE/2 ; ctr

View File

@@ -57,11 +57,11 @@ PB_CENTERJSAMP times 8 db CENTERJSAMPLE
; Perform dequantization and inverse DCT on one block of coefficients.
;
; GLOBAL(void)
; jsimd_idct_float_sse (void * dct_table, JCOEFPTR coef_block,
; jsimd_idct_float_sse (void *dct_table, JCOEFPTR coef_block,
; JSAMPARRAY output_buf, JDIMENSION output_col)
;
%define dct_table(b) (b)+8 ; void * dct_table
%define dct_table(b) (b)+8 ; void *dct_table
%define coef_block(b) (b)+12 ; JCOEFPTR coef_block
%define output_buf(b) (b)+16 ; JSAMPARRAY output_buf
%define output_col(b) (b)+20 ; JDIMENSION output_col
@@ -96,7 +96,7 @@ EXTN(jsimd_idct_float_sse):
; mov eax, [original_ebp]
mov edx, POINTER [dct_table(eax)] ; quantptr
mov esi, JCOEFPTR [coef_block(eax)] ; inptr
lea edi, [workspace] ; FAST_FLOAT * wsptr
lea edi, [workspace] ; FAST_FLOAT *wsptr
mov ecx, DCTSIZE/4 ; ctr
alignx 16,7
.columnloop:
@@ -369,7 +369,7 @@ EXTN(jsimd_idct_float_sse):
; ---- Pass 2: process rows from work array, store into output array.
mov eax, [original_ebp]
lea esi, [workspace] ; FAST_FLOAT * wsptr
lea esi, [workspace] ; FAST_FLOAT *wsptr
mov edi, JSAMPARRAY [output_buf(eax)] ; (JSAMPROW *)
mov eax, JDIMENSION [output_col(eax)]
mov ecx, DCTSIZE/4 ; ctr

View File

@@ -58,11 +58,11 @@ PB_CENTERJSAMP times 16 db CENTERJSAMPLE
; Perform dequantization and inverse DCT on one block of coefficients.
;
; GLOBAL(void)
; jsimd_idct_float_sse2 (void * dct_table, JCOEFPTR coef_block,
; jsimd_idct_float_sse2 (void *dct_table, JCOEFPTR coef_block,
; JSAMPARRAY output_buf, JDIMENSION output_col)
;
; r10 = void * dct_table
; r10 = void *dct_table
; r11 = JCOEFPTR coef_block
; r12 = JSAMPARRAY output_buf
; r13 = JDIMENSION output_col
@@ -91,7 +91,7 @@ EXTN(jsimd_idct_float_sse2):
mov rdx, r10 ; quantptr
mov rsi, r11 ; inptr
lea rdi, [workspace] ; FAST_FLOAT * wsptr
lea rdi, [workspace] ; FAST_FLOAT *wsptr
mov rcx, DCTSIZE/4 ; ctr
.columnloop:
%ifndef NO_ZERO_COLUMN_TEST_FLOAT_SSE
@@ -324,7 +324,7 @@ EXTN(jsimd_idct_float_sse2):
; ---- Pass 2: process rows from work array, store into output array.
mov rax, [original_rbp]
lea rsi, [workspace] ; FAST_FLOAT * wsptr
lea rsi, [workspace] ; FAST_FLOAT *wsptr
mov rdi, r12 ; (JSAMPROW *)
mov eax, r13d
mov rcx, DCTSIZE/4 ; ctr

View File

@@ -57,11 +57,11 @@ PB_CENTERJSAMP times 16 db CENTERJSAMPLE
; Perform dequantization and inverse DCT on one block of coefficients.
;
; GLOBAL(void)
; jsimd_idct_float_sse2 (void * dct_table, JCOEFPTR coef_block,
; jsimd_idct_float_sse2 (void *dct_table, JCOEFPTR coef_block,
; JSAMPARRAY output_buf, JDIMENSION output_col)
;
%define dct_table(b) (b)+8 ; void * dct_table
%define dct_table(b) (b)+8 ; void *dct_table
%define coef_block(b) (b)+12 ; JCOEFPTR coef_block
%define output_buf(b) (b)+16 ; JSAMPARRAY output_buf
%define output_col(b) (b)+20 ; JDIMENSION output_col
@@ -96,7 +96,7 @@ EXTN(jsimd_idct_float_sse2):
; mov eax, [original_ebp]
mov edx, POINTER [dct_table(eax)] ; quantptr
mov esi, JCOEFPTR [coef_block(eax)] ; inptr
lea edi, [workspace] ; FAST_FLOAT * wsptr
lea edi, [workspace] ; FAST_FLOAT *wsptr
mov ecx, DCTSIZE/4 ; ctr
alignx 16,7
.columnloop:
@@ -331,7 +331,7 @@ EXTN(jsimd_idct_float_sse2):
; ---- Pass 2: process rows from work array, store into output array.
mov eax, [original_ebp]
lea esi, [workspace] ; FAST_FLOAT * wsptr
lea esi, [workspace] ; FAST_FLOAT *wsptr
mov edi, JSAMPARRAY [output_buf(eax)] ; (JSAMPROW *)
mov eax, JDIMENSION [output_col(eax)]
mov ecx, DCTSIZE/4 ; ctr

View File

@@ -111,7 +111,7 @@
void
jsimd_idct_ifast_altivec (void * dct_table_, JCOEFPTR coef_block,
jsimd_idct_ifast_altivec (void *dct_table_, JCOEFPTR coef_block,
JSAMPARRAY output_buf, JDIMENSION output_col)
{
short *dct_table = (short *)dct_table_;

View File

@@ -78,11 +78,11 @@ PB_CENTERJSAMP times 8 db CENTERJSAMPLE
; Perform dequantization and inverse DCT on one block of coefficients.
;
; GLOBAL(void)
; jsimd_idct_ifast_mmx (void * dct_table, JCOEFPTR coef_block,
; jsimd_idct_ifast_mmx (void *dct_table, JCOEFPTR coef_block,
; JSAMPARRAY output_buf, JDIMENSION output_col)
;
%define dct_table(b) (b)+8 ; jpeg_component_info * compptr
%define dct_table(b) (b)+8 ; jpeg_component_info *compptr
%define coef_block(b) (b)+12 ; JCOEFPTR coef_block
%define output_buf(b) (b)+16 ; JSAMPARRAY output_buf
%define output_col(b) (b)+20 ; JDIMENSION output_col
@@ -117,7 +117,7 @@ EXTN(jsimd_idct_ifast_mmx):
; mov eax, [original_ebp]
mov edx, POINTER [dct_table(eax)] ; quantptr
mov esi, JCOEFPTR [coef_block(eax)] ; inptr
lea edi, [workspace] ; JCOEF * wsptr
lea edi, [workspace] ; JCOEF *wsptr
mov ecx, DCTSIZE/4 ; ctr
alignx 16,7
.columnloop:
@@ -323,7 +323,7 @@ EXTN(jsimd_idct_ifast_mmx):
; ---- Pass 2: process rows from work array, store into output array.
mov eax, [original_ebp]
lea esi, [workspace] ; JCOEF * wsptr
lea esi, [workspace] ; JCOEF *wsptr
mov edi, JSAMPARRAY [output_buf(eax)] ; (JSAMPROW *)
mov eax, JDIMENSION [output_col(eax)]
mov ecx, DCTSIZE/4 ; ctr

View File

@@ -79,11 +79,11 @@ PB_CENTERJSAMP times 16 db CENTERJSAMPLE
; Perform dequantization and inverse DCT on one block of coefficients.
;
; GLOBAL(void)
; jsimd_idct_ifast_sse2 (void * dct_table, JCOEFPTR coef_block,
; jsimd_idct_ifast_sse2 (void *dct_table, JCOEFPTR coef_block,
; JSAMPARRAY output_buf, JDIMENSION output_col)
;
; r10 = jpeg_component_info * compptr
; r10 = jpeg_component_info *compptr
; r11 = JCOEFPTR coef_block
; r12 = JSAMPARRAY output_buf
; r13 = JDIMENSION output_col

View File

@@ -78,11 +78,11 @@ PB_CENTERJSAMP times 16 db CENTERJSAMPLE
; Perform dequantization and inverse DCT on one block of coefficients.
;
; GLOBAL(void)
; jsimd_idct_ifast_sse2 (void * dct_table, JCOEFPTR coef_block,
; jsimd_idct_ifast_sse2 (void *dct_table, JCOEFPTR coef_block,
; JSAMPARRAY output_buf, JDIMENSION output_col)
;
%define dct_table(b) (b)+8 ; jpeg_component_info * compptr
%define dct_table(b) (b)+8 ; jpeg_component_info *compptr
%define coef_block(b) (b)+12 ; JCOEFPTR coef_block
%define output_buf(b) (b)+16 ; JSAMPARRAY output_buf
%define output_col(b) (b)+20 ; JDIMENSION output_col

View File

@@ -206,7 +206,7 @@
void
jsimd_idct_islow_altivec (void * dct_table_, JCOEFPTR coef_block,
jsimd_idct_islow_altivec (void *dct_table_, JCOEFPTR coef_block,
JSAMPARRAY output_buf, JDIMENSION output_col)
{
short *dct_table = (short *)dct_table_;

View File

@@ -91,11 +91,11 @@ PB_CENTERJSAMP times 8 db CENTERJSAMPLE
; Perform dequantization and inverse DCT on one block of coefficients.
;
; GLOBAL(void)
; jsimd_idct_islow_mmx (void * dct_table, JCOEFPTR coef_block,
; jsimd_idct_islow_mmx (void *dct_table, JCOEFPTR coef_block,
; JSAMPARRAY output_buf, JDIMENSION output_col)
;
%define dct_table(b) (b)+8 ; jpeg_component_info * compptr
%define dct_table(b) (b)+8 ; jpeg_component_info *compptr
%define coef_block(b) (b)+12 ; JCOEFPTR coef_block
%define output_buf(b) (b)+16 ; JSAMPARRAY output_buf
%define output_col(b) (b)+20 ; JDIMENSION output_col
@@ -130,7 +130,7 @@ EXTN(jsimd_idct_islow_mmx):
; mov eax, [original_ebp]
mov edx, POINTER [dct_table(eax)] ; quantptr
mov esi, JCOEFPTR [coef_block(eax)] ; inptr
lea edi, [workspace] ; JCOEF * wsptr
lea edi, [workspace] ; JCOEF *wsptr
mov ecx, DCTSIZE/4 ; ctr
alignx 16,7
.columnloop:
@@ -510,7 +510,7 @@ EXTN(jsimd_idct_islow_mmx):
; ---- Pass 2: process rows from work array, store into output array.
mov eax, [original_ebp]
lea esi, [workspace] ; JCOEF * wsptr
lea esi, [workspace] ; JCOEF *wsptr
mov edi, JSAMPARRAY [output_buf(eax)] ; (JSAMPROW *)
mov eax, JDIMENSION [output_col(eax)]
mov ecx, DCTSIZE/4 ; ctr

View File

@@ -92,11 +92,11 @@ PB_CENTERJSAMP times 16 db CENTERJSAMPLE
; Perform dequantization and inverse DCT on one block of coefficients.
;
; GLOBAL(void)
; jsimd_idct_islow_sse2 (void * dct_table, JCOEFPTR coef_block,
; jsimd_idct_islow_sse2 (void *dct_table, JCOEFPTR coef_block,
; JSAMPARRAY output_buf, JDIMENSION output_col)
;
; r10 = jpeg_component_info * compptr
; r10 = jpeg_component_info *compptr
; r11 = JCOEFPTR coef_block
; r12 = JSAMPARRAY output_buf
; r13 = JDIMENSION output_col

View File

@@ -91,11 +91,11 @@ PB_CENTERJSAMP times 16 db CENTERJSAMPLE
; Perform dequantization and inverse DCT on one block of coefficients.
;
; GLOBAL(void)
; jsimd_idct_islow_sse2 (void * dct_table, JCOEFPTR coef_block,
; jsimd_idct_islow_sse2 (void *dct_table, JCOEFPTR coef_block,
; JSAMPARRAY output_buf, JDIMENSION output_col)
;
%define dct_table(b) (b)+8 ; jpeg_component_info * compptr
%define dct_table(b) (b)+8 ; jpeg_component_info *compptr
%define coef_block(b) (b)+12 ; JCOEFPTR coef_block
%define output_buf(b) (b)+16 ; JSAMPARRAY output_buf
%define output_col(b) (b)+20 ; JDIMENSION output_col

View File

@@ -99,11 +99,11 @@ PB_CENTERJSAMP times 8 db CENTERJSAMPLE
; producing a reduced-size 4x4 output block.
;
; GLOBAL(void)
; jsimd_idct_4x4_mmx (void * dct_table, JCOEFPTR coef_block,
; jsimd_idct_4x4_mmx (void *dct_table, JCOEFPTR coef_block,
; JSAMPARRAY output_buf, JDIMENSION output_col)
;
%define dct_table(b) (b)+8 ; void * dct_table
%define dct_table(b) (b)+8 ; void *dct_table
%define coef_block(b) (b)+12 ; JCOEFPTR coef_block
%define output_buf(b) (b)+16 ; JSAMPARRAY output_buf
%define output_col(b) (b)+20 ; JDIMENSION output_col
@@ -138,7 +138,7 @@ EXTN(jsimd_idct_4x4_mmx):
; mov eax, [original_ebp]
mov edx, POINTER [dct_table(eax)] ; quantptr
mov esi, JCOEFPTR [coef_block(eax)] ; inptr
lea edi, [workspace] ; JCOEF * wsptr
lea edi, [workspace] ; JCOEF *wsptr
mov ecx, DCTSIZE/4 ; ctr
alignx 16,7
.columnloop:
@@ -332,7 +332,7 @@ EXTN(jsimd_idct_4x4_mmx):
; ---- Pass 2: process rows from work array, store into output array.
mov eax, [original_ebp]
lea esi, [workspace] ; JCOEF * wsptr
lea esi, [workspace] ; JCOEF *wsptr
mov edi, JSAMPARRAY [output_buf(eax)] ; (JSAMPROW *)
mov eax, JDIMENSION [output_col(eax)]
@@ -493,11 +493,11 @@ EXTN(jsimd_idct_4x4_mmx):
; producing a reduced-size 2x2 output block.
;
; GLOBAL(void)
; jsimd_idct_2x2_mmx (void * dct_table, JCOEFPTR coef_block,
; jsimd_idct_2x2_mmx (void *dct_table, JCOEFPTR coef_block,
; JSAMPARRAY output_buf, JDIMENSION output_col)
;
%define dct_table(b) (b)+8 ; void * dct_table
%define dct_table(b) (b)+8 ; void *dct_table
%define coef_block(b) (b)+12 ; JCOEFPTR coef_block
%define output_buf(b) (b)+16 ; JSAMPARRAY output_buf
%define output_col(b) (b)+20 ; JDIMENSION output_col

View File

@@ -100,11 +100,11 @@ PB_CENTERJSAMP times 16 db CENTERJSAMPLE
; producing a reduced-size 4x4 output block.
;
; GLOBAL(void)
; jsimd_idct_4x4_sse2 (void * dct_table, JCOEFPTR coef_block,
; jsimd_idct_4x4_sse2 (void *dct_table, JCOEFPTR coef_block,
; JSAMPARRAY output_buf, JDIMENSION output_col)
;
; r10 = void * dct_table
; r10 = void *dct_table
; r11 = JCOEFPTR coef_block
; r12 = JSAMPARRAY output_buf
; r13 = JDIMENSION output_col
@@ -403,11 +403,11 @@ EXTN(jsimd_idct_4x4_sse2):
; producing a reduced-size 2x2 output block.
;
; GLOBAL(void)
; jsimd_idct_2x2_sse2 (void * dct_table, JCOEFPTR coef_block,
; jsimd_idct_2x2_sse2 (void *dct_table, JCOEFPTR coef_block,
; JSAMPARRAY output_buf, JDIMENSION output_col)
;
; r10 = void * dct_table
; r10 = void *dct_table
; r11 = JCOEFPTR coef_block
; r12 = JSAMPARRAY output_buf
; r13 = JDIMENSION output_col

View File

@@ -99,11 +99,11 @@ PB_CENTERJSAMP times 16 db CENTERJSAMPLE
; producing a reduced-size 4x4 output block.
;
; GLOBAL(void)
; jsimd_idct_4x4_sse2 (void * dct_table, JCOEFPTR coef_block,
; jsimd_idct_4x4_sse2 (void *dct_table, JCOEFPTR coef_block,
; JSAMPARRAY output_buf, JDIMENSION output_col)
;
%define dct_table(b) (b)+8 ; void * dct_table
%define dct_table(b) (b)+8 ; void *dct_table
%define coef_block(b) (b)+12 ; JCOEFPTR coef_block
%define output_buf(b) (b)+16 ; JSAMPARRAY output_buf
%define output_col(b) (b)+20 ; JDIMENSION output_col
@@ -414,11 +414,11 @@ EXTN(jsimd_idct_4x4_sse2):
; producing a reduced-size 2x2 output block.
;
; GLOBAL(void)
; jsimd_idct_2x2_sse2 (void * dct_table, JCOEFPTR coef_block,
; jsimd_idct_2x2_sse2 (void *dct_table, JCOEFPTR coef_block,
; JSAMPARRAY output_buf, JDIMENSION output_col)
;
%define dct_table(b) (b)+8 ; void * dct_table
%define dct_table(b) (b)+8 ; void *dct_table
%define coef_block(b) (b)+12 ; JCOEFPTR coef_block
%define output_buf(b) (b)+16 ; JSAMPARRAY output_buf
%define output_col(b) (b)+20 ; JDIMENSION output_col

Some files were not shown because too many files have changed in this diff Show More