php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #13197 ImageTTFText broken on truecolor images
Submitted: 2001-09-07 12:09 UTC Modified: 2001-11-19 11:09 UTC
From: jeremy at deadbeef dot com Assigned:
Status: Not a bug Package: GD related
PHP Version: 4.0.6 OS: Linux
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: jeremy at deadbeef dot com
New email:
PHP Version: OS:

 

 [2001-09-07 12:09 UTC] jeremy at deadbeef dot com
The resulting image is blank, works fine for palette images.



$img = ImageCreateTrueColor(300, 300);
$black = ImageColorAllocate ($img, 0, 0, 0);
$white = ImageColorAllocate ($img, 255, 255, 255);
ImageTTFText ($img, 40, 0, 20, ImageSY($img)-20, -$white, "/home/sageconspiracy/lib/fonts/bio.ttf", "TextText");
ImageJPEG($img, "", 50);

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2001-11-19 11:09 UTC] rasmus@php.net
Remove the - in front of $white there in your ImageTTFText() call and you should see something.  There is a known issue with anti-aliased ttf text on truecolor images in gd-2.0.1.  Hopefully this will be fixed in gd-2.0.2, but regardless, it is not a PHP bug.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Apr 23 07:01:29 2024 UTC