[Top][All Lists]

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

RE: Converting Outlines to postscript Vector

From: Satpal Chander
Subject: RE: Converting Outlines to postscript Vector
Date: Tue, 29 Feb 2000 09:07:16 -0000

> >Hi,
> >   Has anyone tried doing the above from the outline structure
> as returned
> >buy
> >TT_Load_Glyph().
> >I have found a page
> >
> >It does give a good definition there of howto do it but I'm new to fonts/
> >beziers /postscript and the like.
> >Can anyone tell me if I can/should get at the curve data
> directly of through
> >the
> >api, I'm using 1.3.1.
> >Also if the cruve data split into segements or is it just one long curve.
> I'm not 100% sure, but it seems FT1.x doesn't have the decompose outline
> API like FT2 has, so I guess you'll have to walk trhough the
> outline object yourself.

If this is the case then how stable is the FT2 stuff considering that I'm
interested in the outline data for each glyph.

> Even so, it should be fairly straightforward, though:
> - There are on-curve and off-curve points in TT (and therefore in FT1.x)
> - Between any two consecutive off-curve points there is an
> implied on-curve
> point (exactly in the middle between them).
> - A quadratic segment (onCurve, offCurve, onCurve) can be converted to
> cubic beziers (as used by PS) like so:
>    let (from, control, to) be the three points making up de
> quadratic curve
>    you need to convert these three points to four points for
> cubics: (from,
> control1, control2, to)
>        control1 = from + (control - from) * 2.0/3.0
>        control2 = to + (control - to) * 2.0/3.0
>    from and to remain the same.

Does the algorithm above meant that I don't have to actually
do anything with the curves using the curve maths, just manipulating the
control points and outputting them to postscript. ;-))


reply via email to

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