[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [ft] python_freetype Design: Bitmap Objects
From: |
Lawrence D'Oliveiro |
Subject: |
Re: [ft] python_freetype Design: Bitmap Objects |
Date: |
Thu, 19 Feb 2015 12:49:05 +1300 |
On Wed, 18 Feb 2015 23:47:17 +0100 (CET), Werner LEMBERG wrote:
>> I guess it’s a question of understanding the intended conventions
>> for use of FT_Bitmap objects. Seems like all the calls that fill
>> them in will also allocate them for you, but this is more implied
>> than stated outright (e.g. the description of FT_Outline_Render).
>
> I'm always grateful for corrections and/or additions to the
> documentation :-)
I’ll have another read and suggest some clarifications.
One potentially misleading thing, I think, is the routine name
“FT_Bitmap_New”: it does not allocate any storage at all (contrast
“FT_Outline_New” and “FT_Stroker_New”), but initializes the Bitmap
structure to indicate “zero width, zero height, no pixels”. A better
name might have been “FT_Bitmap_Init”, or even “FT_Bitmap_Null” or
“FT_Bitmap_Empty”.