7 struct jpeg_common_struct
{
8 struct jpeg_error_mgr
* err
;
10 typedef struct jpeg_common_struct
* j_common_ptr
;
11 typedef struct jpeg_compress_struct
* j_compress_ptr
;
12 struct jpeg_compress_struct
{
13 struct jpeg_error_mgr
* err
;
15 jpeg_component_info
* comp_info
;
16 int max_h_samp_factor
;
17 int max_v_samp_factor
;
19 struct jpeg_error_mgr
{
24 jinit_downsampler (j_compress_ptr cinfo
)
27 jpeg_component_info
* compptr
;
29 for (ci
= 0, compptr
= cinfo
->comp_info
; ci
< cinfo
->num_components
;
31 if (compptr
->h_samp_factor
== cinfo
->max_h_samp_factor
&&
32 compptr
->v_samp_factor
== cinfo
->max_v_samp_factor
) {
33 } else if ((cinfo
->max_h_samp_factor
% compptr
->h_samp_factor
) == 0 &&
34 (cinfo
->max_v_samp_factor
% compptr
->v_samp_factor
) == 0) {
36 cinfo
->err
->msg_code
= 0;