List Info

Thread: ImageFont getmask() bug?




ImageFont getmask() bug?
user name
2006-05-15 16:54:25
Hi,

following code, which uses PIL 1.1.5,
generates a bitmap of text "of" rendered in
Georgia font,
but the result is strange, it seems like the rightmost
pixel column is shifted to the left,
it belongs to the "f" letter.

import ImageFont
fp = '/usr/share/fonts/corefonts/'
font = ImageFont.truetype(fp+'georgia.ttf', 10)
m = font.getmask('of', mode='1')
m.save_ppm('of.ppm')

The result PPM file and magnified PNG file should be
attached.

--michal

_______________________________________________
Image-SIG maillist  -  Image-SIGpython.org
htt
p://mail.python.org/mailman/listinfo/image-sig
[1]

about | contact  Other archives ( Real Estate discussion Medical topics )