summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--base/gdevp14.c4
-rw-r--r--base/gxblend.c4
2 files changed, 4 insertions, 4 deletions
diff --git a/base/gdevp14.c b/base/gdevp14.c
index b3409adbc..78958f4b4 100644
--- a/base/gdevp14.c
+++ b/base/gdevp14.c
@@ -4170,7 +4170,7 @@ do_pdf14_copy_alpha_color(gx_device * dev, const byte * data, int data_x,
4170 blend_mode == BLEND_MODE_Compatible || 4170 blend_mode == BLEND_MODE_Compatible ||
4171 blend_mode == BLEND_MODE_CompatibleOverprint; 4171 blend_mode == BLEND_MODE_CompatibleOverprint;
4172 int num_chan = buf->n_chan; 4172 int num_chan = buf->n_chan;
4173 int num_comp = num_chan - 1 - has_tags; 4173 int num_comp = num_chan - 1;
4174 int shape_off = num_chan * planestride; 4174 int shape_off = num_chan * planestride;
4175 int alpha_g_off = shape_off + (has_shape ? planestride : 0); 4175 int alpha_g_off = shape_off + (has_shape ? planestride : 0);
4176 int tag_off = alpha_g_off + (has_alpha_g ? planestride : 0); 4176 int tag_off = alpha_g_off + (has_alpha_g ? planestride : 0);
@@ -4359,7 +4359,7 @@ do_pdf14_copy_alpha_color_16(gx_device * dev, const byte * data, int data_x,
4359 bool has_tags = buf->has_tags; 4359 bool has_tags = buf->has_tags;
4360 bool knockout = buf->knockout; 4360 bool knockout = buf->knockout;
4361 int num_chan = buf->n_chan; 4361 int num_chan = buf->n_chan;
4362 int num_comp = num_chan - 1 - has_tags; 4362 int num_comp = num_chan - 1;
4363 int shape_off = num_chan * planestride; 4363 int shape_off = num_chan * planestride;
4364 int alpha_g_off = shape_off + (has_shape ? planestride : 0); 4364 int alpha_g_off = shape_off + (has_shape ? planestride : 0);
4365 int tag_off = alpha_g_off + (has_alpha_g ? planestride : 0); 4365 int tag_off = alpha_g_off + (has_alpha_g ? planestride : 0);
diff --git a/base/gxblend.c b/base/gxblend.c
index 410594836..1f027cdd1 100644
--- a/base/gxblend.c
+++ b/base/gxblend.c
@@ -1244,7 +1244,7 @@ art_blend_pixel_8_inline(byte *gs_restrict dst, const byte *gs_restrict backdrop
1244 break; 1244 break;
1245 case BLEND_MODE_Hue: 1245 case BLEND_MODE_Hue:
1246 { 1246 {
1247 byte tmp[4]; 1247 byte tmp[ART_MAX_CHAN];
1248 1248
1249 pblend_procs->blend_luminosity(n_chan, tmp, src, backdrop); 1249 pblend_procs->blend_luminosity(n_chan, tmp, src, backdrop);
1250 pblend_procs->blend_saturation(n_chan, dst, tmp, backdrop); 1250 pblend_procs->blend_saturation(n_chan, dst, tmp, backdrop);
@@ -1504,7 +1504,7 @@ art_blend_pixel_16_inline(uint16_t *gs_restrict dst, const uint16_t *gs_restrict
1504 break; 1504 break;
1505 case BLEND_MODE_Hue: 1505 case BLEND_MODE_Hue:
1506 { 1506 {
1507 uint16_t tmp[4]; 1507 uint16_t tmp[ART_MAX_CHAN];
1508 1508
1509 pblend_procs->blend_luminosity16(n_chan, tmp, src, backdrop); 1509 pblend_procs->blend_luminosity16(n_chan, tmp, src, backdrop);
1510 pblend_procs->blend_saturation16(n_chan, dst, tmp, backdrop); 1510 pblend_procs->blend_saturation16(n_chan, dst, tmp, backdrop);