freetype
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: FT Performance Regression?


From: Werner LEMBERG
Subject: Re: FT Performance Regression?
Date: Sat, 26 Oct 2019 17:54:53 +0200 (CEST)

> FreeType 2.6 used to use an unbounded clip_box in the
> FT_Raster_Params struct, and internally the gray_compute_cbox
> function would clamp it to a reasonable range.
> 
> That clamping no longer happens, so you have to do it yourself
> before calling the function. The docs don't really explain how that
> would be calculated, but from looking at the old 2.6 code I think it
> should be this:
> 
> FT_Outline_Get_CBox(outline, &rp.clip_box);
> rp.clip_box.xMin = rp.clip_box.xMin >> 6;
> rp.clip_box.yMin = rp.clip_box.yMin >> 6;
> rp.clip_box.xMax = (rp.clip_box.xMax + 63) >> 6;
> rp.clip_box.yMax = (rp.clip_box.yMax + 63) >> 6;
> 
> Does that seem correct?

Alexei?


    Werner



reply via email to

[Prev in Thread] Current Thread [Next in Thread]