Bug 688032 - Rotated text is not antialiased.
Summary: Rotated text is not antialiased.
Status: RESOLVED FIXED
Alias: None
Product: Ghostscript
Classification: Unclassified
Component: Graphics Library (show other bugs)
Version: master
Hardware: All All
: P3 normal
Assignee: Ken Sharp
URL:
Keywords: bountiable
Depends on:
Blocks:
 
Reported: 2005-04-12 06:35 UTC by Alex Cherepanov
Modified: 2009-02-10 03:59 UTC (History)
0 users

See Also:
Customer:
Word Size: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alex Cherepanov 2005-04-12 06:35:31 UTC
The following was posted on comp.text.pdf.  I confirm that this problem
exists in the current CVS version. -DNOCACHE restores the correct rendering.

Here is a minimal example:
 
%!PS-Adobe-2.0
%%BoundingBox: 0 0 100 100
/Helvetica findfont 20 scalefont setfont
gsave 20 50 moveto 45 rotate (Test)show grestore
20 20 moveto (Test)show 
showpage
 
gs -dBATCH -dNOPAUSE -sDEVICE=bmp16m -dDEVICEWIDTHPOINTS=100 
-dDEVICEHEIGHTPOINTS=100 -r300 -dGraphicsAlphaBits=4 -dTextAlphaBits=4 
-sOutputFile=bg815.bmp bg.eps
GPL Ghostscript 8.15 (2004-09-22)

/usr/bin/gs -dBATCH -dNOPAUSE -sDEVICE=bmp16m -dDEVICEWIDTHPOINTS=100 
 -dDEVICEHEIGHTPOINTS=100 -r300 -dGraphicsAlphaBits=4 -dTextAlphaBits=4 
 -sOutputFile=bg707.bmp bg.eps
ESP Ghostscript 7.07 (2003-07-12)

bg707.bmp looks much better then bg815.bmp (similarly with other raster
devices).
Comment 1 Igor Melichev 2005-08-23 09:58:30 UTC
The problem happens due to is_matrix_good_for_caching returns 'false'. There is 
a comment in gxchar.c ln 1463 :

/* Oversampling rotated characters doesn't work well. */

I do not know why such solution has been taken a long ago.
Likely Raph knows.
If we don't longer need this constraint, is_matrix_good_for_caching should 
always return true.

Passing the bug to Raph for obtaining his response.
Comment 2 Ken Sharp 2009-02-10 03:59:57 UTC
Fixed in revision 9465, patch at:

http://ghostscript.com/pipermail/gs-cvs/2009-February/009042.html