Re: Floating point in pango



> On Wed, 2006-07-12 at 08:47 +0200, Murray Cumming wrote:
>> > Hi;
>> >
>> > On Tue, 2006-07-11 at 12:04 +0300, Jorn Baayen wrote:
>> >> >
>> >> > True.  That's because cairo's public API uses floating point.  Do
>> you
>> >> > have any idea how Pango can do better here?
>> >>
>> >> No :(
>> >>
>> >
>> > Neither that nice but;
>> >
>> >  - Have cairo expose a new alternate fixed point API that pango-cairo
>> >    makes use of ( openGL API does a similar thing ). Internally cairo
>> >    is mostly fixed point I believe.
>>
>> Is this something that we can do with just a typedef?
>
> Not without a C++ compiler.

I'm not sure I understand. I'm not talking about a template.

For instance, exactly what functions are we talking about in the API?

>  But that may be feasible still.  We use
> floats like others do, add, multiply, sin(), cos(), and add & multiply
> won't work straight on fixed.

So this is more than just API, but I guess it can still be adapted.

>> I don't think we should be afraid of adding an --enable-fixed-point=yes
>> or
>> --enable-embedded-api=yes build option so that the API is slightly
>> different on some platforms. Backwards ABI compatibility isn't a big
>> concern. Dependant software can then #ifdef where necessary to adapt its
>> build to the alternative API.
>
> Agreed.  At some point I started making the 16.16 fixed split in cairo
> configurable, but didn't finish the patch.  That helps here too.



Murray Cumming
murrayc murrayc com
www.murrayc.com
www.openismus.com




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