ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> image-sig
image-sig
Re: [Image-SIG] drawing antialised text
by W.T. Bridgman other posts by this author
Jul 22 2004 2:02PM messages near this date
[Image-SIG] drawing antialised text | [Image-SIG] gimp-2.0 palette
If you define the image as RGBA with (0,0,0,255) and then call 
draw.text with fill=(255,255,255,0) for white text with no 
transparency, you can do simple compositing.

Is that what you're looking for?

I'm having antialiasing problems as well with this setup.

Tom
On Jul 9, 2004, at 5:15 PM, Björn Platzen wrote:

>  Hello List,
> 
>  I'm trying to draw some antialiased Text on an 8-bit PNG with
>  alphatransparency. But my text always looks horrible. It looks kind of
>  distorted.
> 
>  As a workaround, I initialized a new RGB Image, pasted my PNG and wrote
>  my text. After that, I converted the new image to mode "P".  Everything
>  worked fine and my text looked ok.
> 
>  But now, I need the produced image with a transparent background. Is
>  there any way to write the text directly into my PNG so that it is
>  nicely rendered and antialiased?
>  Another approach would be to make the background of the RGB image
>  transparent. But I don't have any idea how to get this working...
> 
> 
>  I'm workin with PIL 1.15a3 on a Linux-Machine. The server has only PIL
>  1.14, so solutions should work under 1.14 as well...
> 
>  Thanks in advance,
> 
>  Bjoern.
> 
> 
>  _______________________________________________
>  Image-SIG maillist  -  Image-SIG@[...].org
>  http://mail.python.org/mailman/listinfo/image-sig
> 
> 
--
***********************************************************************
**** NOTE NEW EMAIL ADDRESS AS THE WYETH ADDRESS WILL GO AWAY SOON ****
***********************************************************************
Dr. William T."Tom" Bridgman               Scientific Visualization 
Studio
Global Science & Technology, Inc.          NASA/Goddard Space Flight 
Center
Email: William.T.Bridgman.1@[...].gov  Code 935
Phone: 301-286-1346                        Greenbelt, MD 20771
FAX:   TBD                                 http://svs.gsfc.nasa.gov/

_______________________________________________
Image-SIG maillist  -  Image-SIG@[...].org
http://mail.python.org/mailman/listinfo/image-sig
Thread:
=?ISO-8859-1?Q?Bj=F6rn?= Platzen
W.T. Bridgman

Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState Software Inc. All rights reserved