summaryrefslogtreecommitdiff
path: root/fitz
diff options
context:
space:
mode:
Diffstat (limited to 'fitz')
-rw-r--r--fitz/dev_draw.c15
-rw-r--r--fitz/fitz_draw.h4
2 files changed, 18 insertions, 1 deletions
diff --git a/fitz/dev_draw.c b/fitz/dev_draw.c
index 0b909f85..2698f22d 100644
--- a/fitz/dev_draw.c
+++ b/fitz/dev_draw.c
@@ -277,7 +277,20 @@ drawglyph(unsigned char *argb, fz_pixmap *dst, fz_pixmap *src, int xorig, int yo
h = sy1 - sy0;
if (dst->colorspace)
- fz_text_w4i1o4(argb, sp, src->w, dp, dst->w * 4, w, h);
+ {
+ switch (dst->n)
+ {
+ case 2:
+ fz_text_w2i1o2(argb, sp, src->w, dp, dst->w * 2, w, h);
+ break;
+ case 4:
+ fz_text_w4i1o4(argb, sp, src->w, dp, dst->w * 4, w, h);
+ break;
+ default:
+ assert("Write fz_text_wni1on" != NULL);
+ break;
+ }
+ }
else
fz_text_1o1(sp, src->w, dp, dst->w, w, h);
}
diff --git a/fitz/fitz_draw.h b/fitz/fitz_draw.h
index 077edd0b..abd94a1e 100644
--- a/fitz/fitz_draw.h
+++ b/fitz/fitz_draw.h
@@ -487,14 +487,18 @@ extern void (*fz_duff_1i1o1)(unsigned char*,int,unsigned char*,int,unsigned char
extern void (*fz_duff_4i1o4)(unsigned char*,int,unsigned char*,int,unsigned char*,int,int,int);
extern void (*fz_path_1o1)(unsigned char*,unsigned char,int,unsigned char*);
+extern void (*fz_path_w2i1o2)(unsigned char*,unsigned char*,unsigned char,int,unsigned char*);
extern void (*fz_path_w4i1o4)(unsigned char*,unsigned char*,unsigned char,int,unsigned char*);
extern void (*fz_text_1o1)(unsigned char*,int,unsigned char*,int,int,int);
+extern void (*fz_text_w2i1o2)(unsigned char*,unsigned char*,int,unsigned char*,int,int,int);
extern void (*fz_text_w4i1o4)(unsigned char*,unsigned char*,int,unsigned char*,int,int,int);
extern void (*fz_img_non)(unsigned char*,unsigned char,int,unsigned char*,fz_pixmap*,fz_matrix*);
extern void (*fz_img_1o1)(unsigned char*,unsigned char,int,unsigned char*,fz_pixmap*,int u, int v, int fa, int fb);
extern void (*fz_img_4o4)(unsigned char*,unsigned char,int,unsigned char*,fz_pixmap*,int u, int v, int fa, int fb);
+extern void (*fz_img_2o2)(unsigned char*,unsigned char,int,unsigned char*,fz_pixmap*,int u, int v, int fa, int fb);
+extern void (*fz_img_w2i1o2)(unsigned char*,unsigned char*,unsigned char,int,unsigned char*,fz_pixmap*,int u, int v, int fa, int fb);
extern void (*fz_img_w4i1o4)(unsigned char*,unsigned char*,unsigned char,int,unsigned char*,fz_pixmap*,int u, int v, int fa, int fb);
extern void (*fz_decodetile)(fz_pixmap *pix, int skip, float *decode);