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:
@@ -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
|
||||
|
||||
Reference in New Issue
Block a user