Coverage Report

Created: 2026-08-13 06:24

next uncovered line (L), next uncovered region (R), next uncovered branch (B)
/src/libjpeg-turbo.main/src/jdcolext.c
Line
Count
Source
1
/*
2
 * jdcolext.c
3
 *
4
 * This file was part of the Independent JPEG Group's software:
5
 * Copyright (C) 1991-1997, Thomas G. Lane.
6
 * libjpeg-turbo Modifications:
7
 * Copyright (C) 2009, 2011, 2015, 2022-2023, 2025, D. R. Commander.
8
 * For conditions of distribution and use, see the accompanying README.ijg
9
 * file.
10
 *
11
 * This file contains output colorspace conversion routines.
12
 */
13
14
15
/* This file is included by jdcolor.c */
16
17
18
/*
19
 * Convert some rows of samples to the output colorspace.
20
 *
21
 * Note that we change from noninterleaved, one-plane-per-component format
22
 * to interleaved-pixel format.  The output buffer is therefore three times
23
 * as wide as the input buffer.
24
 * A starting row offset is provided only for the input buffer.  The caller
25
 * can easily adjust the passed output_buf value to accommodate any row
26
 * offset required on that side.
27
 */
28
29
INLINE
30
LOCAL(void)
31
ycc_rgb_convert(j_decompress_ptr cinfo, _JSAMPIMAGE input_buf,
32
                JDIMENSION input_row, _JSAMPARRAY output_buf, int num_rows)
33
1.37M
{
34
#if BITS_IN_JSAMPLE != 16
35
  my_cconvert_ptr cconvert = (my_cconvert_ptr)cinfo->cconvert;
36
  register int y, cb, cr;
37
  register _JSAMPROW outptr;
38
  register _JSAMPROW inptr0, inptr1, inptr2;
39
  register JDIMENSION col;
40
  JDIMENSION num_cols = cinfo->output_width;
41
  /* copy these pointers into registers if possible */
42
  register _JSAMPLE *range_limit = (_JSAMPLE *)cinfo->sample_range_limit;
43
  register int *Crrtab = cconvert->Cr_r_tab;
44
  register int *Cbbtab = cconvert->Cb_b_tab;
45
  register JLONG *Crgtab = cconvert->Cr_g_tab;
46
  register JLONG *Cbgtab = cconvert->Cb_g_tab;
47
  SHIFT_TEMPS
48
49
4.58M
  while (--num_rows >= 0) {
50
3.21M
    inptr0 = input_buf[0][input_row];
51
3.21M
    inptr1 = input_buf[1][input_row];
52
3.21M
    inptr2 = input_buf[2][input_row];
53
3.21M
    input_row++;
54
3.21M
    outptr = *output_buf++;
55
68.6M
    for (col = 0; col < num_cols; col++) {
56
65.4M
      y  = inptr0[col];
57
65.4M
      cb = inptr1[col];
58
65.4M
      cr = inptr2[col];
59
      /* Range-limiting is essential due to noise introduced by DCT losses. */
60
65.4M
      outptr[RGB_RED] =   range_limit[y + Crrtab[cr]];
61
65.4M
      outptr[RGB_GREEN] = range_limit[y +
62
65.4M
                              ((int)RIGHT_SHIFT(Cbgtab[cb] + Crgtab[cr],
63
65.4M
                                                SCALEBITS))];
64
65.4M
      outptr[RGB_BLUE] =  range_limit[y + Cbbtab[cb]];
65
      /* Set unused byte to _MAXJSAMPLE so it can be interpreted as an */
66
      /* opaque alpha channel value */
67
#ifdef RGB_ALPHA
68
19.9M
      outptr[RGB_ALPHA] = _MAXJSAMPLE;
69
#endif
70
65.4M
      outptr += RGB_PIXELSIZE;
71
65.4M
    }
72
3.21M
  }
73
#else
74
0
  ERREXIT(cinfo, JERR_CONVERSION_NOTIMPL);
75
#endif
76
1.37M
}
Unexecuted instantiation: jdcolor-8.c:ycc_extrgb_convert
Unexecuted instantiation: jdcolor-8.c:ycc_extrgbx_convert
Unexecuted instantiation: jdcolor-8.c:ycc_extbgr_convert
Unexecuted instantiation: jdcolor-8.c:ycc_extbgrx_convert
Unexecuted instantiation: jdcolor-8.c:ycc_extxbgr_convert
Unexecuted instantiation: jdcolor-8.c:ycc_extxrgb_convert
Unexecuted instantiation: jdcolor-8.c:ycc_rgb_convert
jdcolor-12.c:ycc_extrgb_convert
Line
Count
Source
33
629k
{
34
629k
#if BITS_IN_JSAMPLE != 16
35
629k
  my_cconvert_ptr cconvert = (my_cconvert_ptr)cinfo->cconvert;
36
629k
  register int y, cb, cr;
37
629k
  register _JSAMPROW outptr;
38
629k
  register _JSAMPROW inptr0, inptr1, inptr2;
39
629k
  register JDIMENSION col;
40
629k
  JDIMENSION num_cols = cinfo->output_width;
41
  /* copy these pointers into registers if possible */
42
629k
  register _JSAMPLE *range_limit = (_JSAMPLE *)cinfo->sample_range_limit;
43
629k
  register int *Crrtab = cconvert->Cr_r_tab;
44
629k
  register int *Cbbtab = cconvert->Cb_b_tab;
45
629k
  register JLONG *Crgtab = cconvert->Cr_g_tab;
46
629k
  register JLONG *Cbgtab = cconvert->Cb_g_tab;
47
629k
  SHIFT_TEMPS
48
49
2.27M
  while (--num_rows >= 0) {
50
1.64M
    inptr0 = input_buf[0][input_row];
51
1.64M
    inptr1 = input_buf[1][input_row];
52
1.64M
    inptr2 = input_buf[2][input_row];
53
1.64M
    input_row++;
54
1.64M
    outptr = *output_buf++;
55
47.0M
    for (col = 0; col < num_cols; col++) {
56
45.4M
      y  = inptr0[col];
57
45.4M
      cb = inptr1[col];
58
45.4M
      cr = inptr2[col];
59
      /* Range-limiting is essential due to noise introduced by DCT losses. */
60
45.4M
      outptr[RGB_RED] =   range_limit[y + Crrtab[cr]];
61
45.4M
      outptr[RGB_GREEN] = range_limit[y +
62
45.4M
                              ((int)RIGHT_SHIFT(Cbgtab[cb] + Crgtab[cr],
63
45.4M
                                                SCALEBITS))];
64
45.4M
      outptr[RGB_BLUE] =  range_limit[y + Cbbtab[cb]];
65
      /* Set unused byte to _MAXJSAMPLE so it can be interpreted as an */
66
      /* opaque alpha channel value */
67
#ifdef RGB_ALPHA
68
      outptr[RGB_ALPHA] = _MAXJSAMPLE;
69
#endif
70
45.4M
      outptr += RGB_PIXELSIZE;
71
45.4M
    }
72
1.64M
  }
73
#else
74
  ERREXIT(cinfo, JERR_CONVERSION_NOTIMPL);
75
#endif
76
629k
}
Unexecuted instantiation: jdcolor-12.c:ycc_extrgbx_convert
Unexecuted instantiation: jdcolor-12.c:ycc_extbgr_convert
jdcolor-12.c:ycc_extbgrx_convert
Line
Count
Source
33
593k
{
34
593k
#if BITS_IN_JSAMPLE != 16
35
593k
  my_cconvert_ptr cconvert = (my_cconvert_ptr)cinfo->cconvert;
36
593k
  register int y, cb, cr;
37
593k
  register _JSAMPROW outptr;
38
593k
  register _JSAMPROW inptr0, inptr1, inptr2;
39
593k
  register JDIMENSION col;
40
593k
  JDIMENSION num_cols = cinfo->output_width;
41
  /* copy these pointers into registers if possible */
42
593k
  register _JSAMPLE *range_limit = (_JSAMPLE *)cinfo->sample_range_limit;
43
593k
  register int *Crrtab = cconvert->Cr_r_tab;
44
593k
  register int *Cbbtab = cconvert->Cb_b_tab;
45
593k
  register JLONG *Crgtab = cconvert->Cr_g_tab;
46
593k
  register JLONG *Cbgtab = cconvert->Cb_g_tab;
47
593k
  SHIFT_TEMPS
48
49
1.84M
  while (--num_rows >= 0) {
50
1.25M
    inptr0 = input_buf[0][input_row];
51
1.25M
    inptr1 = input_buf[1][input_row];
52
1.25M
    inptr2 = input_buf[2][input_row];
53
1.25M
    input_row++;
54
1.25M
    outptr = *output_buf++;
55
19.7M
    for (col = 0; col < num_cols; col++) {
56
18.4M
      y  = inptr0[col];
57
18.4M
      cb = inptr1[col];
58
18.4M
      cr = inptr2[col];
59
      /* Range-limiting is essential due to noise introduced by DCT losses. */
60
18.4M
      outptr[RGB_RED] =   range_limit[y + Crrtab[cr]];
61
18.4M
      outptr[RGB_GREEN] = range_limit[y +
62
18.4M
                              ((int)RIGHT_SHIFT(Cbgtab[cb] + Crgtab[cr],
63
18.4M
                                                SCALEBITS))];
64
18.4M
      outptr[RGB_BLUE] =  range_limit[y + Cbbtab[cb]];
65
      /* Set unused byte to _MAXJSAMPLE so it can be interpreted as an */
66
      /* opaque alpha channel value */
67
18.4M
#ifdef RGB_ALPHA
68
18.4M
      outptr[RGB_ALPHA] = _MAXJSAMPLE;
69
18.4M
#endif
70
18.4M
      outptr += RGB_PIXELSIZE;
71
18.4M
    }
72
1.25M
  }
73
#else
74
  ERREXIT(cinfo, JERR_CONVERSION_NOTIMPL);
75
#endif
76
593k
}
jdcolor-12.c:ycc_extxbgr_convert
Line
Count
Source
33
148k
{
34
148k
#if BITS_IN_JSAMPLE != 16
35
148k
  my_cconvert_ptr cconvert = (my_cconvert_ptr)cinfo->cconvert;
36
148k
  register int y, cb, cr;
37
148k
  register _JSAMPROW outptr;
38
148k
  register _JSAMPROW inptr0, inptr1, inptr2;
39
148k
  register JDIMENSION col;
40
148k
  JDIMENSION num_cols = cinfo->output_width;
41
  /* copy these pointers into registers if possible */
42
148k
  register _JSAMPLE *range_limit = (_JSAMPLE *)cinfo->sample_range_limit;
43
148k
  register int *Crrtab = cconvert->Cr_r_tab;
44
148k
  register int *Cbbtab = cconvert->Cb_b_tab;
45
148k
  register JLONG *Crgtab = cconvert->Cr_g_tab;
46
148k
  register JLONG *Cbgtab = cconvert->Cb_g_tab;
47
148k
  SHIFT_TEMPS
48
49
462k
  while (--num_rows >= 0) {
50
313k
    inptr0 = input_buf[0][input_row];
51
313k
    inptr1 = input_buf[1][input_row];
52
313k
    inptr2 = input_buf[2][input_row];
53
313k
    input_row++;
54
313k
    outptr = *output_buf++;
55
1.80M
    for (col = 0; col < num_cols; col++) {
56
1.49M
      y  = inptr0[col];
57
1.49M
      cb = inptr1[col];
58
1.49M
      cr = inptr2[col];
59
      /* Range-limiting is essential due to noise introduced by DCT losses. */
60
1.49M
      outptr[RGB_RED] =   range_limit[y + Crrtab[cr]];
61
1.49M
      outptr[RGB_GREEN] = range_limit[y +
62
1.49M
                              ((int)RIGHT_SHIFT(Cbgtab[cb] + Crgtab[cr],
63
1.49M
                                                SCALEBITS))];
64
1.49M
      outptr[RGB_BLUE] =  range_limit[y + Cbbtab[cb]];
65
      /* Set unused byte to _MAXJSAMPLE so it can be interpreted as an */
66
      /* opaque alpha channel value */
67
1.49M
#ifdef RGB_ALPHA
68
1.49M
      outptr[RGB_ALPHA] = _MAXJSAMPLE;
69
1.49M
#endif
70
1.49M
      outptr += RGB_PIXELSIZE;
71
1.49M
    }
72
313k
  }
73
#else
74
  ERREXIT(cinfo, JERR_CONVERSION_NOTIMPL);
75
#endif
76
148k
}
Unexecuted instantiation: jdcolor-12.c:ycc_extxrgb_convert
Unexecuted instantiation: jdcolor-12.c:ycc_rgb_convert
Unexecuted instantiation: jdcolor-16.c:ycc_extrgb_convert
Unexecuted instantiation: jdcolor-16.c:ycc_extrgbx_convert
Unexecuted instantiation: jdcolor-16.c:ycc_extbgr_convert
Unexecuted instantiation: jdcolor-16.c:ycc_extbgrx_convert
Unexecuted instantiation: jdcolor-16.c:ycc_extxbgr_convert
Unexecuted instantiation: jdcolor-16.c:ycc_extxrgb_convert
Unexecuted instantiation: jdcolor-16.c:ycc_rgb_convert
77
78
79
/*
80
 * Convert grayscale to RGB: just duplicate the graylevel three times.
81
 * This is provided to support applications that don't want to cope
82
 * with grayscale as a separate case.
83
 */
84
85
INLINE
86
LOCAL(void)
87
gray_rgb_convert(j_decompress_ptr cinfo, _JSAMPIMAGE input_buf,
88
                 JDIMENSION input_row, _JSAMPARRAY output_buf, int num_rows)
89
7.33M
{
90
7.33M
  register _JSAMPROW inptr, outptr;
91
7.33M
  register JDIMENSION col;
92
7.33M
  JDIMENSION num_cols = cinfo->output_width;
93
94
18.9M
  while (--num_rows >= 0) {
95
11.6M
    inptr = input_buf[0][input_row++];
96
11.6M
    outptr = *output_buf++;
97
1.14G
    for (col = 0; col < num_cols; col++) {
98
1.12G
      outptr[RGB_RED] = outptr[RGB_GREEN] = outptr[RGB_BLUE] = inptr[col];
99
      /* Set unused byte to _MAXJSAMPLE so it can be interpreted as an */
100
      /* opaque alpha channel value */
101
#ifdef RGB_ALPHA
102
162M
      outptr[RGB_ALPHA] = _MAXJSAMPLE;
103
#endif
104
1.12G
      outptr += RGB_PIXELSIZE;
105
1.12G
    }
106
11.6M
  }
107
7.33M
}
jdcolor-8.c:gray_extrgb_convert
Line
Count
Source
89
2.62M
{
90
2.62M
  register _JSAMPROW inptr, outptr;
91
2.62M
  register JDIMENSION col;
92
2.62M
  JDIMENSION num_cols = cinfo->output_width;
93
94
6.54M
  while (--num_rows >= 0) {
95
3.91M
    inptr = input_buf[0][input_row++];
96
3.91M
    outptr = *output_buf++;
97
555M
    for (col = 0; col < num_cols; col++) {
98
551M
      outptr[RGB_RED] = outptr[RGB_GREEN] = outptr[RGB_BLUE] = inptr[col];
99
      /* Set unused byte to _MAXJSAMPLE so it can be interpreted as an */
100
      /* opaque alpha channel value */
101
#ifdef RGB_ALPHA
102
      outptr[RGB_ALPHA] = _MAXJSAMPLE;
103
#endif
104
551M
      outptr += RGB_PIXELSIZE;
105
551M
    }
106
3.91M
  }
107
2.62M
}
Unexecuted instantiation: jdcolor-8.c:gray_extrgbx_convert
Unexecuted instantiation: jdcolor-8.c:gray_extbgr_convert
jdcolor-8.c:gray_extbgrx_convert
Line
Count
Source
89
1.19M
{
90
1.19M
  register _JSAMPROW inptr, outptr;
91
1.19M
  register JDIMENSION col;
92
1.19M
  JDIMENSION num_cols = cinfo->output_width;
93
94
3.00M
  while (--num_rows >= 0) {
95
1.81M
    inptr = input_buf[0][input_row++];
96
1.81M
    outptr = *output_buf++;
97
86.4M
    for (col = 0; col < num_cols; col++) {
98
84.6M
      outptr[RGB_RED] = outptr[RGB_GREEN] = outptr[RGB_BLUE] = inptr[col];
99
      /* Set unused byte to _MAXJSAMPLE so it can be interpreted as an */
100
      /* opaque alpha channel value */
101
84.6M
#ifdef RGB_ALPHA
102
84.6M
      outptr[RGB_ALPHA] = _MAXJSAMPLE;
103
84.6M
#endif
104
84.6M
      outptr += RGB_PIXELSIZE;
105
84.6M
    }
106
1.81M
  }
107
1.19M
}
jdcolor-8.c:gray_extxbgr_convert
Line
Count
Source
89
326k
{
90
326k
  register _JSAMPROW inptr, outptr;
91
326k
  register JDIMENSION col;
92
326k
  JDIMENSION num_cols = cinfo->output_width;
93
94
815k
  while (--num_rows >= 0) {
95
488k
    inptr = input_buf[0][input_row++];
96
488k
    outptr = *output_buf++;
97
9.63M
    for (col = 0; col < num_cols; col++) {
98
9.15M
      outptr[RGB_RED] = outptr[RGB_GREEN] = outptr[RGB_BLUE] = inptr[col];
99
      /* Set unused byte to _MAXJSAMPLE so it can be interpreted as an */
100
      /* opaque alpha channel value */
101
9.15M
#ifdef RGB_ALPHA
102
9.15M
      outptr[RGB_ALPHA] = _MAXJSAMPLE;
103
9.15M
#endif
104
9.15M
      outptr += RGB_PIXELSIZE;
105
9.15M
    }
106
488k
  }
107
326k
}
Unexecuted instantiation: jdcolor-8.c:gray_extxrgb_convert
Unexecuted instantiation: jdcolor-8.c:gray_rgb_convert
jdcolor-12.c:gray_extrgb_convert
Line
Count
Source
89
1.98M
{
90
1.98M
  register _JSAMPROW inptr, outptr;
91
1.98M
  register JDIMENSION col;
92
1.98M
  JDIMENSION num_cols = cinfo->output_width;
93
94
5.37M
  while (--num_rows >= 0) {
95
3.38M
    inptr = input_buf[0][input_row++];
96
3.38M
    outptr = *output_buf++;
97
419M
    for (col = 0; col < num_cols; col++) {
98
416M
      outptr[RGB_RED] = outptr[RGB_GREEN] = outptr[RGB_BLUE] = inptr[col];
99
      /* Set unused byte to _MAXJSAMPLE so it can be interpreted as an */
100
      /* opaque alpha channel value */
101
#ifdef RGB_ALPHA
102
      outptr[RGB_ALPHA] = _MAXJSAMPLE;
103
#endif
104
416M
      outptr += RGB_PIXELSIZE;
105
416M
    }
106
3.38M
  }
107
1.98M
}
Unexecuted instantiation: jdcolor-12.c:gray_extrgbx_convert
Unexecuted instantiation: jdcolor-12.c:gray_extbgr_convert
jdcolor-12.c:gray_extbgrx_convert
Line
Count
Source
89
951k
{
90
951k
  register _JSAMPROW inptr, outptr;
91
951k
  register JDIMENSION col;
92
951k
  JDIMENSION num_cols = cinfo->output_width;
93
94
2.56M
  while (--num_rows >= 0) {
95
1.61M
    inptr = input_buf[0][input_row++];
96
1.61M
    outptr = *output_buf++;
97
62.9M
    for (col = 0; col < num_cols; col++) {
98
61.2M
      outptr[RGB_RED] = outptr[RGB_GREEN] = outptr[RGB_BLUE] = inptr[col];
99
      /* Set unused byte to _MAXJSAMPLE so it can be interpreted as an */
100
      /* opaque alpha channel value */
101
61.2M
#ifdef RGB_ALPHA
102
61.2M
      outptr[RGB_ALPHA] = _MAXJSAMPLE;
103
61.2M
#endif
104
61.2M
      outptr += RGB_PIXELSIZE;
105
61.2M
    }
106
1.61M
  }
107
951k
}
jdcolor-12.c:gray_extxbgr_convert
Line
Count
Source
89
248k
{
90
248k
  register _JSAMPROW inptr, outptr;
91
248k
  register JDIMENSION col;
92
248k
  JDIMENSION num_cols = cinfo->output_width;
93
94
670k
  while (--num_rows >= 0) {
95
422k
    inptr = input_buf[0][input_row++];
96
422k
    outptr = *output_buf++;
97
7.38M
    for (col = 0; col < num_cols; col++) {
98
6.96M
      outptr[RGB_RED] = outptr[RGB_GREEN] = outptr[RGB_BLUE] = inptr[col];
99
      /* Set unused byte to _MAXJSAMPLE so it can be interpreted as an */
100
      /* opaque alpha channel value */
101
6.96M
#ifdef RGB_ALPHA
102
6.96M
      outptr[RGB_ALPHA] = _MAXJSAMPLE;
103
6.96M
#endif
104
6.96M
      outptr += RGB_PIXELSIZE;
105
6.96M
    }
106
422k
  }
107
248k
}
Unexecuted instantiation: jdcolor-12.c:gray_extxrgb_convert
Unexecuted instantiation: jdcolor-12.c:gray_rgb_convert
Unexecuted instantiation: jdcolor-16.c:gray_extrgb_convert
Unexecuted instantiation: jdcolor-16.c:gray_extrgbx_convert
Unexecuted instantiation: jdcolor-16.c:gray_extbgr_convert
Unexecuted instantiation: jdcolor-16.c:gray_extbgrx_convert
Unexecuted instantiation: jdcolor-16.c:gray_extxbgr_convert
Unexecuted instantiation: jdcolor-16.c:gray_extxrgb_convert
Unexecuted instantiation: jdcolor-16.c:gray_rgb_convert
108
109
110
/*
111
 * Convert RGB to extended RGB: just swap the order of source pixels
112
 */
113
114
INLINE
115
LOCAL(void)
116
rgb_rgb_convert(j_decompress_ptr cinfo, _JSAMPIMAGE input_buf,
117
                JDIMENSION input_row, _JSAMPARRAY output_buf, int num_rows)
118
1.13M
{
119
1.13M
  register _JSAMPROW inptr0, inptr1, inptr2;
120
1.13M
  register _JSAMPROW outptr;
121
1.13M
  register JDIMENSION col;
122
1.13M
  JDIMENSION num_cols = cinfo->output_width;
123
124
3.44M
  while (--num_rows >= 0) {
125
2.31M
    inptr0 = input_buf[0][input_row];
126
2.31M
    inptr1 = input_buf[1][input_row];
127
2.31M
    inptr2 = input_buf[2][input_row];
128
2.31M
    input_row++;
129
2.31M
    outptr = *output_buf++;
130
83.2M
    for (col = 0; col < num_cols; col++) {
131
80.9M
      outptr[RGB_RED] = inptr0[col];
132
80.9M
      outptr[RGB_GREEN] = inptr1[col];
133
80.9M
      outptr[RGB_BLUE] = inptr2[col];
134
      /* Set unused byte to _MAXJSAMPLE so it can be interpreted as an */
135
      /* opaque alpha channel value */
136
#ifdef RGB_ALPHA
137
80.9M
      outptr[RGB_ALPHA] = _MAXJSAMPLE;
138
#endif
139
80.9M
      outptr += RGB_PIXELSIZE;
140
80.9M
    }
141
2.31M
  }
142
1.13M
}
Unexecuted instantiation: jdcolor-8.c:rgb_extrgb_convert
Unexecuted instantiation: jdcolor-8.c:rgb_extrgbx_convert
Unexecuted instantiation: jdcolor-8.c:rgb_extbgr_convert
jdcolor-8.c:rgb_extbgrx_convert
Line
Count
Source
118
198k
{
119
198k
  register _JSAMPROW inptr0, inptr1, inptr2;
120
198k
  register _JSAMPROW outptr;
121
198k
  register JDIMENSION col;
122
198k
  JDIMENSION num_cols = cinfo->output_width;
123
124
679k
  while (--num_rows >= 0) {
125
481k
    inptr0 = input_buf[0][input_row];
126
481k
    inptr1 = input_buf[1][input_row];
127
481k
    inptr2 = input_buf[2][input_row];
128
481k
    input_row++;
129
481k
    outptr = *output_buf++;
130
10.9M
    for (col = 0; col < num_cols; col++) {
131
10.4M
      outptr[RGB_RED] = inptr0[col];
132
10.4M
      outptr[RGB_GREEN] = inptr1[col];
133
10.4M
      outptr[RGB_BLUE] = inptr2[col];
134
      /* Set unused byte to _MAXJSAMPLE so it can be interpreted as an */
135
      /* opaque alpha channel value */
136
10.4M
#ifdef RGB_ALPHA
137
10.4M
      outptr[RGB_ALPHA] = _MAXJSAMPLE;
138
10.4M
#endif
139
10.4M
      outptr += RGB_PIXELSIZE;
140
10.4M
    }
141
481k
  }
142
198k
}
jdcolor-8.c:rgb_extxbgr_convert
Line
Count
Source
118
162k
{
119
162k
  register _JSAMPROW inptr0, inptr1, inptr2;
120
162k
  register _JSAMPROW outptr;
121
162k
  register JDIMENSION col;
122
162k
  JDIMENSION num_cols = cinfo->output_width;
123
124
537k
  while (--num_rows >= 0) {
125
374k
    inptr0 = input_buf[0][input_row];
126
374k
    inptr1 = input_buf[1][input_row];
127
374k
    inptr2 = input_buf[2][input_row];
128
374k
    input_row++;
129
374k
    outptr = *output_buf++;
130
9.57M
    for (col = 0; col < num_cols; col++) {
131
9.19M
      outptr[RGB_RED] = inptr0[col];
132
9.19M
      outptr[RGB_GREEN] = inptr1[col];
133
9.19M
      outptr[RGB_BLUE] = inptr2[col];
134
      /* Set unused byte to _MAXJSAMPLE so it can be interpreted as an */
135
      /* opaque alpha channel value */
136
9.19M
#ifdef RGB_ALPHA
137
9.19M
      outptr[RGB_ALPHA] = _MAXJSAMPLE;
138
9.19M
#endif
139
9.19M
      outptr += RGB_PIXELSIZE;
140
9.19M
    }
141
374k
  }
142
162k
}
Unexecuted instantiation: jdcolor-8.c:rgb_extxrgb_convert
Unexecuted instantiation: jdcolor-8.c:rgb_rgb_convert
Unexecuted instantiation: jdcolor-12.c:rgb_extrgb_convert
Unexecuted instantiation: jdcolor-12.c:rgb_extrgbx_convert
Unexecuted instantiation: jdcolor-12.c:rgb_extbgr_convert
jdcolor-12.c:rgb_extbgrx_convert
Line
Count
Source
118
156k
{
119
156k
  register _JSAMPROW inptr0, inptr1, inptr2;
120
156k
  register _JSAMPROW outptr;
121
156k
  register JDIMENSION col;
122
156k
  JDIMENSION num_cols = cinfo->output_width;
123
124
503k
  while (--num_rows >= 0) {
125
347k
    inptr0 = input_buf[0][input_row];
126
347k
    inptr1 = input_buf[1][input_row];
127
347k
    inptr2 = input_buf[2][input_row];
128
347k
    input_row++;
129
347k
    outptr = *output_buf++;
130
15.9M
    for (col = 0; col < num_cols; col++) {
131
15.6M
      outptr[RGB_RED] = inptr0[col];
132
15.6M
      outptr[RGB_GREEN] = inptr1[col];
133
15.6M
      outptr[RGB_BLUE] = inptr2[col];
134
      /* Set unused byte to _MAXJSAMPLE so it can be interpreted as an */
135
      /* opaque alpha channel value */
136
15.6M
#ifdef RGB_ALPHA
137
15.6M
      outptr[RGB_ALPHA] = _MAXJSAMPLE;
138
15.6M
#endif
139
15.6M
      outptr += RGB_PIXELSIZE;
140
15.6M
    }
141
347k
  }
142
156k
}
jdcolor-12.c:rgb_extxbgr_convert
Line
Count
Source
118
113k
{
119
113k
  register _JSAMPROW inptr0, inptr1, inptr2;
120
113k
  register _JSAMPROW outptr;
121
113k
  register JDIMENSION col;
122
113k
  JDIMENSION num_cols = cinfo->output_width;
123
124
335k
  while (--num_rows >= 0) {
125
221k
    inptr0 = input_buf[0][input_row];
126
221k
    inptr1 = input_buf[1][input_row];
127
221k
    inptr2 = input_buf[2][input_row];
128
221k
    input_row++;
129
221k
    outptr = *output_buf++;
130
12.4M
    for (col = 0; col < num_cols; col++) {
131
12.2M
      outptr[RGB_RED] = inptr0[col];
132
12.2M
      outptr[RGB_GREEN] = inptr1[col];
133
12.2M
      outptr[RGB_BLUE] = inptr2[col];
134
      /* Set unused byte to _MAXJSAMPLE so it can be interpreted as an */
135
      /* opaque alpha channel value */
136
12.2M
#ifdef RGB_ALPHA
137
12.2M
      outptr[RGB_ALPHA] = _MAXJSAMPLE;
138
12.2M
#endif
139
12.2M
      outptr += RGB_PIXELSIZE;
140
12.2M
    }
141
221k
  }
142
113k
}
Unexecuted instantiation: jdcolor-12.c:rgb_extxrgb_convert
Unexecuted instantiation: jdcolor-12.c:rgb_rgb_convert
Unexecuted instantiation: jdcolor-16.c:rgb_extrgb_convert
Unexecuted instantiation: jdcolor-16.c:rgb_extrgbx_convert
Unexecuted instantiation: jdcolor-16.c:rgb_extbgr_convert
jdcolor-16.c:rgb_extbgrx_convert
Line
Count
Source
118
251k
{
119
251k
  register _JSAMPROW inptr0, inptr1, inptr2;
120
251k
  register _JSAMPROW outptr;
121
251k
  register JDIMENSION col;
122
251k
  JDIMENSION num_cols = cinfo->output_width;
123
124
695k
  while (--num_rows >= 0) {
125
444k
    inptr0 = input_buf[0][input_row];
126
444k
    inptr1 = input_buf[1][input_row];
127
444k
    inptr2 = input_buf[2][input_row];
128
444k
    input_row++;
129
444k
    outptr = *output_buf++;
130
17.1M
    for (col = 0; col < num_cols; col++) {
131
16.6M
      outptr[RGB_RED] = inptr0[col];
132
16.6M
      outptr[RGB_GREEN] = inptr1[col];
133
16.6M
      outptr[RGB_BLUE] = inptr2[col];
134
      /* Set unused byte to _MAXJSAMPLE so it can be interpreted as an */
135
      /* opaque alpha channel value */
136
16.6M
#ifdef RGB_ALPHA
137
16.6M
      outptr[RGB_ALPHA] = _MAXJSAMPLE;
138
16.6M
#endif
139
16.6M
      outptr += RGB_PIXELSIZE;
140
16.6M
    }
141
444k
  }
142
251k
}
jdcolor-16.c:rgb_extxbgr_convert
Line
Count
Source
118
251k
{
119
251k
  register _JSAMPROW inptr0, inptr1, inptr2;
120
251k
  register _JSAMPROW outptr;
121
251k
  register JDIMENSION col;
122
251k
  JDIMENSION num_cols = cinfo->output_width;
123
124
695k
  while (--num_rows >= 0) {
125
444k
    inptr0 = input_buf[0][input_row];
126
444k
    inptr1 = input_buf[1][input_row];
127
444k
    inptr2 = input_buf[2][input_row];
128
444k
    input_row++;
129
444k
    outptr = *output_buf++;
130
17.1M
    for (col = 0; col < num_cols; col++) {
131
16.6M
      outptr[RGB_RED] = inptr0[col];
132
16.6M
      outptr[RGB_GREEN] = inptr1[col];
133
16.6M
      outptr[RGB_BLUE] = inptr2[col];
134
      /* Set unused byte to _MAXJSAMPLE so it can be interpreted as an */
135
      /* opaque alpha channel value */
136
16.6M
#ifdef RGB_ALPHA
137
16.6M
      outptr[RGB_ALPHA] = _MAXJSAMPLE;
138
16.6M
#endif
139
16.6M
      outptr += RGB_PIXELSIZE;
140
16.6M
    }
141
444k
  }
142
251k
}
Unexecuted instantiation: jdcolor-16.c:rgb_extxrgb_convert
Unexecuted instantiation: jdcolor-16.c:rgb_rgb_convert