ps/pdf: fix the polarity of stencil masks

This commit is contained in:
Adrian Johnson 2011-09-06 23:41:12 +09:30
parent a7ed3dd914
commit d47e05f8c2
2 changed files with 3 additions and 2 deletions

View file

@ -1972,7 +1972,8 @@ _cairo_pdf_surface_emit_smask (cairo_pdf_surface_t *surface,
" /ImageMask true\n"
" /Width %d\n"
" /Height %d\n"
" /BitsPerComponent 1\n",
" /BitsPerComponent 1\n"
" /Decode [1 0]\n",
image->width, image->height);
} else {
stream_res->id = 0;

View file

@ -2453,7 +2453,7 @@ _cairo_ps_surface_emit_image (cairo_ps_surface_t *surface,
ps_image->height,
interpolate,
color == CAIRO_IMAGE_IS_MONOCHROME ? 1 : 8,
color == CAIRO_IMAGE_IS_COLOR ? "0 1 0 1 0 1" : "0 1");
stencil_mask ? "1 0" : color == CAIRO_IMAGE_IS_COLOR ? "0 1 0 1 0 1" : "0 1");
if (surface->use_string_datasource) {
_cairo_output_stream_printf (surface->stream,
" /DataSource {\n"