On Wed, Jun 3, 2020 at 10:48 PM Anuj Verma <an...@iitbhilai.ac.in> wrote:
>
> Hello Behdad, Jim,
>
> > I see that in your implementation you are converting cubics to quadratic 
> > spline. That makes a lot of sense and I support that.
>
> Is it better to split the cubic bezier into quadratic one? why? Currently I 
> am using Newton-Raphson's iteration to find the
> closest point on cubic curves, which is a bit slow but works well and 
> produces accurate results. (https://imgur.com/QSGCoIj)

Indeed, iterations or bisections might be better if some analytical
solution for quadratic curves has a square root, which is not allowed
in FreeType. Behdad will send me to my cave again, of course...

>
> > I think we do want a 8bit representation at least, and possible a higher 
> > one.
>
> Currently I am using 32bit floats, but since freetype doesn't use floats I am
> thinking of using 32bit 16.16 fixed point instead. The problem with 16.16 is 
> that
> most of the bits in the integer part will not be used because I am 
> normalizing the
> values between [-1.0, 1.0] before outputting the data.

Is 1/65563 not enough accuracy for you? Do not be greedy. What would
you gain from extra accuracy in the world of discrete pixels?

Alexei

Reply via email to