<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=big5">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<span class="smartReply">Much better. Thanks!</span></div>
looks great, seemingly use freetype library to draw text, will learn further.</div>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
James</div>
<div id="appendonsend"></div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> cecashon@aol.com <cecashon@aol.com><br>
<b>Sent:</b> Thursday, June 3, 2021 2:19 AM<br>
<b>To:</b> mhao1999@live.cn <mhao1999@live.cn>; cairo@cairographics.org <cairo@cairographics.org><br>
<b>Subject:</b> Re: [cairo] How to get truetype contour points with cairo</font>
<div> </div>
</div>
<div>
<div style="color:black; font:10pt arial">
<div><font size="2">Hi James,</font></div>
<div><font size="2"><br>
</font></div>
<div><font size="2">Give the following a try and see if it is close to what you are after.</font></div>
<div><font size="2"><br>
</font></div>
<div><font size="2">cairo3d_text_UI.c at</font></div>
<div><font size="2">https://gitlab.com/cecashon/OrderedSetVelociRaptor/-/blob/master/Misc/cairo3d/cairo3d_text_UI.c</font></div>
<div><font size="2"><br>
</font></div>
<div><font size="2">Eric</font><br>
</div>
<div><br>
</div>
<div><br>
</div>
<div style="font-family:arial,helvetica; font-size:10pt; color:black"><font size="2">-----Original Message-----<br>
From: mhao1999@live.cn <mhao1999@live.cn><br>
To: cairo@cairographics.org <cairo@cairographics.org><br>
Sent: Wed, Jun 2, 2021 8:45 am<br>
Subject: [cairo] How to get truetype contour points with cairo<br>
<br>
<div id="x_yiv9516126581"><style type="text/css">
<!--
#x_yiv9516126581 p
{margin-top:0;
margin-bottom:0}
-->
</style>
<div dir="ltr">
<div style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
For rendering text with cairo, my understanding is that:</div>
<div style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<ol>
<li><span>use pango to get each position of glyph</span></li><li><span>use cairo to render such glyph</span></li></ol>
<div><span>For 2, I think the cairo use some libraries (x rendering or xft library) to parse font file (installed in the system) and get vector information of each glyph and convert such vector information to screen pixel (rasterization and anti-alias, etc).</span></div>
<div><span><br>
</span></div>
<div><span>My question is: </span></div>
<div>
<ol>
<li><span>does cairo use freetype library (called by x rendering or xft) to parse the truetype font file?</span></li><li><span>can I get vector information of each glyph (like contour points and bezier control points)?</span></li></ol>
<div><span>Thanks</span></div>
</div>
<div><span>James Hao</span></div>
</div>
</div>
</div>
-- <br>
cairo mailing list<br>
<a href="mailto:cairo@cairographics.org">cairo@cairographics.org</a><br>
<a href="https://lists.cairographics.org/mailman/listinfo/cairo" target="_blank">https://lists.cairographics.org/mailman/listinfo/cairo</a><br>
</font></div>
</div>
</div>
</body>
</html>