aboutsummaryrefslogtreecommitdiff
path: root/docs/doxygen/nel/a02541.html
diff options
context:
space:
mode:
authorneodarz <neodarz@neodarz.net>2018-08-11 20:21:34 +0200
committerneodarz <neodarz@neodarz.net>2018-08-11 20:21:34 +0200
commit0ea5fc66924303d1bf73ba283a383e2aadee02f2 (patch)
tree2568e71a7ccc44ec23b8bb3f0ff97fb6bf2ed709 /docs/doxygen/nel/a02541.html
downloadnevrax-website-self-hostable-0ea5fc66924303d1bf73ba283a383e2aadee02f2.tar.xz
nevrax-website-self-hostable-0ea5fc66924303d1bf73ba283a383e2aadee02f2.zip
Initial commit
Diffstat (limited to 'docs/doxygen/nel/a02541.html')
-rw-r--r--docs/doxygen/nel/a02541.html778
1 files changed, 778 insertions, 0 deletions
diff --git a/docs/doxygen/nel/a02541.html b/docs/doxygen/nel/a02541.html
new file mode 100644
index 00000000..c8c7d72f
--- /dev/null
+++ b/docs/doxygen/nel/a02541.html
@@ -0,0 +1,778 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
+<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
+<title>NeL: NL3D::CFontGenerator class Reference</title>
+<link href="doxygen.css" rel="stylesheet" type="text/css">
+</head><body>
+<!-- Generated by Doxygen 1.3.6 -->
+<div class="qindex"> <form class="search" action="search.php" method="get">
+<a class="qindex" href="main.html">Main&nbsp;Page</a> | <a class="qindex" href="namespaces.html">Namespace List</a> | <a class="qindex" href="hierarchy.html">Class&nbsp;Hierarchy</a> | <a class="qindex" href="classes.html">Alphabetical&nbsp;List</a> | <a class="qindex" href="annotated.html">Data&nbsp;Structures</a> | <a class="qindex" href="files.html">File&nbsp;List</a> | <a class="qindex" href="namespacemembers.html">Namespace&nbsp;Members</a> | <a class="qindex" href="functions.html">Data&nbsp;Fields</a> | <a class="qindex" href="globals.html">Globals</a> | <a class="qindex" href="pages.html">Related&nbsp;Pages</a> | <span class="search"><u>S</u>earch&nbsp;for&nbsp;<input class="search" type="text" name="query" value="" size="20" accesskey="s"/></span></form></div>
+<h1>NL3D::CFontGenerator Class Reference</h1><code>#include &lt;<a class="el" href="a05721.html">font_generator.h</a>&gt;</code>
+<p>
+<hr><a name="_details"></a><h2>Detailed Description</h2>
+Generate bitmap based on a true type font (using freetype2) <dl compact><dt><b>Author:</b></dt><dd>Vianney Lecroart <p>
+Nevrax France </dd></dl>
+<dl compact><dt><b>Date:</b></dt><dd>2000 </dd></dl>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05721.html#l00052">52</a> of file <a class="el" href="a05721.html">font_generator.h</a>.<table border=0 cellpadding=0 cellspacing=0>
+<tr><td></td></tr>
+<tr><td colspan=2><br><h2>Public Member Functions</h2></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02541.html#NL3D_1_1CFontGeneratora0">CFontGenerator</a> (const std::string &amp;fontFileName, const std::string &amp;fontExFileName="")</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a7">uint8</a> *&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02541.html#NL3D_1_1CFontGeneratora1">getBitmap</a> (<a class="el" href="a05167.html#a18">ucchar</a> c, <a class="el" href="a04558.html#a11">uint32</a> <a class="el" href="a04223.html#a587">size</a>, <a class="el" href="a04558.html#a11">uint32</a> &amp;<a class="el" href="a04223.html#a632">width</a>, <a class="el" href="a04558.html#a11">uint32</a> &amp;<a class="el" href="a04223.html#a633">height</a>, <a class="el" href="a04558.html#a11">uint32</a> &amp;pitch, <a class="el" href="a04558.html#a10">sint32</a> &amp;left, <a class="el" href="a04558.html#a10">sint32</a> &amp;top, <a class="el" href="a04558.html#a10">sint32</a> &amp;advx, <a class="el" href="a04558.html#a11">uint32</a> &amp;glyphIndex)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a11">uint32</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02541.html#NL3D_1_1CFontGeneratora2">getCharIndex</a> (<a class="el" href="a05167.html#a18">ucchar</a> c)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02541.html#NL3D_1_1CFontGeneratora3">getKerning</a> (<a class="el" href="a05167.html#a18">ucchar</a> left, <a class="el" href="a05167.html#a18">ucchar</a> right, <a class="el" href="a04558.html#a10">sint32</a> &amp;kernx)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02541.html#NL3D_1_1CFontGeneratora4">getSizes</a> (<a class="el" href="a05167.html#a18">ucchar</a> c, <a class="el" href="a04558.html#a11">uint32</a> <a class="el" href="a04223.html#a587">size</a>, <a class="el" href="a04558.html#a11">uint32</a> &amp;<a class="el" href="a04223.html#a632">width</a>, <a class="el" href="a04558.html#a11">uint32</a> &amp;<a class="el" href="a04223.html#a633">height</a>)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a11">uint32</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02541.html#NL3D_1_1CFontGeneratora5">getUID</a> ()</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>virtual&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02541.html#NL3D_1_1CFontGeneratora6">~CFontGenerator</a> ()</td></tr>
+
+<tr><td colspan=2><br><h2>Private Member Functions</h2></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>const char *&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02541.html#NL3D_1_1CFontGeneratord0">getFT2Error</a> (FT_Error fte)</td></tr>
+
+<tr><td colspan=2><br><h2>Private Attributes</h2></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>FT_Face&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02541.html#NL3D_1_1CFontGeneratorr0">_Face</a></td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>std::string&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02541.html#NL3D_1_1CFontGeneratorr1">_FontFileName</a></td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a11">uint32</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02541.html#NL3D_1_1CFontGeneratorr2">_UID</a></td></tr>
+
+<tr><td colspan=2><br><h2>Static Private Attributes</h2></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a04558.html#a11">uint32</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02541.html#NL3D_1_1CFontGeneratorv0">_FontGeneratorCounterUID</a> = 1</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>FT_Library&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02541.html#NL3D_1_1CFontGeneratorv1">_Library</a></td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>bool&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02541.html#NL3D_1_1CFontGeneratorv2">_LibraryInit</a> = false</td></tr>
+
+</table>
+<hr><h2>Constructor &amp; Destructor Documentation</h2>
+<a class="anchor" name="NL3D_1_1CFontGeneratora0" doxytag="NL3D::CFontGenerator::CFontGenerator" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> NL3D::CFontGenerator::CFontGenerator </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top">const std::string &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>fontFileName</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap>const std::string &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>fontExFileName</em> = ""</td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Constructor <dl compact><dt><b>Parameters:</b></dt><dd>
+ <table border="0" cellspacing="2" cellpadding="0">
+ <tr><td valign=top><em>fontFileName</em>&nbsp;</td><td>path+filename (ex: "c:\winnt\fonts\arial.ttf")</td></tr>
+ </table>
+</dl>
+
+<p>
+Definition at line <a class="el" href="a05720.html#l00093">93</a> of file <a class="el" href="a05720.html">font_generator.cpp</a>.
+<p>
+References <a class="el" href="a05721.html#l00096">_Face</a>, <a class="el" href="a05721.html#l00088">_FontFileName</a>, <a class="el" href="a05720.html#l00071">_FontGeneratorCounterUID</a>, <a class="el" href="a05720.html#l00069">_Library</a>, <a class="el" href="a05720.html#l00070">_LibraryInit</a>, <a class="el" href="a05721.html#l00087">_UID</a>, <a class="el" href="a05720.html#l00073">getFT2Error()</a>, <a class="el" href="a05622.html#l00154">nlerror</a>, and <a class="el" href="a05622.html#l00135">nlwarning</a>.
+<p>
+<div class="fragment"><pre>00094 {
+00095 NL_ALLOC_CONTEXT (FreeTyp);
+00096
+00097 <a class="code" href="a02541.html#NL3D_1_1CFontGeneratorr2">_UID</a> = <a class="code" href="a02541.html#NL3D_1_1CFontGeneratorv0">_FontGeneratorCounterUID</a>;
+00098 _FontGeneratorCounterUID++;
+00099 <a class="code" href="a02541.html#NL3D_1_1CFontGeneratorr1">_FontFileName</a> = fontFileName;
+00100
+00101 FT_Error error;
+00102
+00103 <span class="keywordflow">if</span> (!<a class="code" href="a02541.html#NL3D_1_1CFontGeneratorv2">_LibraryInit</a>)
+00104 {
+00105 error = FT_Init_FreeType (&amp;_Library);
+00106 <span class="keywordflow">if</span> (error)
+00107 {
+00108 <a class="code" href="a04199.html#a3">nlerror</a> (<span class="stringliteral">"FT_Init_FreeType() failed: %s"</span>, <a class="code" href="a02541.html#NL3D_1_1CFontGeneratord0">getFT2Error</a>(error));
+00109 }
+00110 <a class="code" href="a02541.html#NL3D_1_1CFontGeneratorv2">_LibraryInit</a> = <span class="keyword">true</span>;
+00111 }
+00112
+00113 error = FT_New_Face (_Library, fontFileName.c_str (), 0, &amp;<a class="code" href="a02541.html#NL3D_1_1CFontGeneratorr0">_Face</a>);
+00114 <span class="keywordflow">if</span> (error)
+00115 {
+00116 <a class="code" href="a04199.html#a3">nlerror</a> (<span class="stringliteral">"FT_New_Face() failed with file '%s': %s"</span>, fontFileName.c_str(), <a class="code" href="a02541.html#NL3D_1_1CFontGeneratord0">getFT2Error</a>(error));
+00117 }
+00118
+00119 string fontEx = fontExFileName;
+00120 <span class="keywordflow">if</span> (fontEx == <span class="stringliteral">""</span>)
+00121 {
+00122 <span class="comment">// try to see if the ex filename exists based on the fontExFileName</span>
+00123 fontEx = CPath::lookup(CFile::getFilenameWithoutExtension (fontFileName)+<span class="stringliteral">".afm"</span>, <span class="keyword">false</span>, <span class="keyword">false</span>);
+00124 }
+00125
+00126 <span class="keywordflow">if</span> (fontEx != <span class="stringliteral">""</span>)
+00127 {
+00128 error = FT_Attach_File (_Face, fontEx.c_str ());
+00129 <span class="keywordflow">if</span> (error)
+00130 {
+00131 <a class="code" href="a04199.html#a2">nlwarning</a> (<span class="stringliteral">"FT_Attach_File() failed with file '%s': %s"</span>, fontEx.c_str(), <a class="code" href="a02541.html#NL3D_1_1CFontGeneratord0">getFT2Error</a>(error));
+00132 }
+00133 }
+00134
+00135 error = FT_Select_Charmap (_Face, ft_encoding_unicode);
+00136 <span class="keywordflow">if</span> (error)
+00137 {
+00138 <a class="code" href="a04199.html#a3">nlerror</a> (<span class="stringliteral">"FT_Select_Charmap() failed with file '%s': %s"</span>, fontFileName.c_str(), <a class="code" href="a02541.html#NL3D_1_1CFontGeneratord0">getFT2Error</a>(error));
+00139 }
+00140 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NL3D_1_1CFontGeneratora6" doxytag="NL3D::CFontGenerator::~CFontGenerator" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> NL3D::CFontGenerator::~<a class="el" href="a02541.html">CFontGenerator</a> </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05720.html#l00142">142</a> of file <a class="el" href="a05720.html">font_generator.cpp</a>.
+<p>
+<div class="fragment"><pre>00143 {
+00144 }
+</pre></div> </td>
+ </tr>
+</table>
+<hr><h2>Member Function Documentation</h2>
+<a class="anchor" name="NL3D_1_1CFontGeneratora1" doxytag="NL3D::CFontGenerator::getBitmap" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a7">uint8</a> * NL3D::CFontGenerator::getBitmap </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a05167.html#a18">ucchar</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>c</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a04558.html#a11">uint32</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>size</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a04558.html#a11">uint32</a> &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>width</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a04558.html#a11">uint32</a> &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>height</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a04558.html#a11">uint32</a> &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>pitch</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a04558.html#a10">sint32</a> &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>left</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a04558.html#a10">sint32</a> &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>top</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a04558.html#a10">sint32</a> &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>advx</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a04558.html#a11">uint32</a> &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>glyphIndex</em></td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+generate and return a bitmap <dl compact><dt><b>Parameters:</b></dt><dd>
+ <table border="0" cellspacing="2" cellpadding="0">
+ <tr><td valign=top><em>c</em>&nbsp;</td><td>the unicode char </td></tr>
+ <tr><td valign=top><em>size</em>&nbsp;</td><td>size of the generated font in ??? format </td></tr>
+ <tr><td valign=top><em>width</em>&nbsp;</td><td>width of the generated bitmap, this value is set by this function </td></tr>
+ <tr><td valign=top><em>height</em>&nbsp;</td><td>height of the generated bitmap, this value is set by this function </td></tr>
+ <tr><td valign=top><em>pitch</em>&nbsp;</td><td>pitch of the generated bitmap (+ or - the number of bytes per row), this value is set by this function</td></tr>
+ </table>
+</dl>
+
+<p>
+Definition at line <a class="el" href="a05720.html#l00173">173</a> of file <a class="el" href="a05720.html">font_generator.cpp</a>.
+<p>
+References <a class="el" href="a05721.html#l00096">_Face</a>, <a class="el" href="a05720.html#l00073">getFT2Error()</a>, <a class="el" href="a05646.html#l01013">height</a>, <a class="el" href="a05622.html#l00154">nlerror</a>, <a class="el" href="a05981.html#l00099">sint32</a>, <a class="el" href="a05646.html#l00645">size</a>, <a class="el" href="a06590.html#l00236">ucchar</a>, <a class="el" href="a05981.html#l00100">uint32</a>, <a class="el" href="a05981.html#l00096">uint8</a>, and <a class="el" href="a05646.html#l01013">width</a>.
+<p>
+Referenced by <a class="el" href="a06523.html#l00273">NL3D::CTextureFont::getLetterInfo()</a>, and <a class="el" href="a06523.html#l00154">NL3D::CTextureFont::rebuildLetter()</a>.
+<p>
+<div class="fragment"><pre>00174 {
+00175 NL_ALLOC_CONTEXT (FreeTyp);
+00176
+00177 FT_Error error;
+00178
+00179 error = FT_Set_Pixel_Sizes (_Face, size, size);
+00180 <span class="keywordflow">if</span> (error)
+00181 {
+00182 <a class="code" href="a04199.html#a3">nlerror</a> (<span class="stringliteral">"FT_Set_Pixel_Sizes() failed: %s"</span>, <a class="code" href="a02541.html#NL3D_1_1CFontGeneratord0">getFT2Error</a>(error));
+00183 }
+00184
+00185 <span class="comment">// retrieve glyph index from character code</span>
+00186 FT_UInt glyph_index = FT_Get_Char_Index (_Face, c);
+00187
+00188 <span class="comment">// load glyph image into the slot (erase previous one)</span>
+00189 error = FT_Load_Glyph (_Face, glyph_index, FT_LOAD_DEFAULT);
+00190 <span class="keywordflow">if</span> (error)
+00191 {
+00192 <a class="code" href="a04199.html#a3">nlerror</a> (<span class="stringliteral">"FT_Load_Glyph() failed: %s"</span>, <a class="code" href="a02541.html#NL3D_1_1CFontGeneratord0">getFT2Error</a>(error));
+00193 }
+00194
+00195 <span class="keywordflow">if</span> (<a class="code" href="a04223.html#a587">size</a> == 0)
+00196 {
+00197 <a class="code" href="a04223.html#a632">width</a> = 0;
+00198 <a class="code" href="a04223.html#a633">height</a> = 0;
+00199 pitch = 0;
+00200 left = 0;
+00201 top = 0;
+00202 advx = 0;
+00203 glyphIndex = glyph_index;
+00204 <span class="keywordflow">return</span> NULL;
+00205 }
+00206
+00207 <span class="comment">// convert to an anti-aliased bitmap</span>
+00208 error = FT_Render_Glyph (<a class="code" href="a02541.html#NL3D_1_1CFontGeneratorr0">_Face</a>-&gt;glyph, ft_render_mode_normal);
+00209 <span class="keywordflow">if</span> (error)
+00210 {
+00211 <a class="code" href="a04199.html#a3">nlerror</a> (<span class="stringliteral">"FT_Render_Glyph() failed: %s"</span>, <a class="code" href="a02541.html#NL3D_1_1CFontGeneratord0">getFT2Error</a>(error));
+00212 }
+00213
+00214 <a class="code" href="a04223.html#a632">width</a> = <a class="code" href="a02541.html#NL3D_1_1CFontGeneratorr0">_Face</a>-&gt;glyph-&gt;bitmap.width;
+00215 <a class="code" href="a04223.html#a633">height</a> = <a class="code" href="a02541.html#NL3D_1_1CFontGeneratorr0">_Face</a>-&gt;glyph-&gt;bitmap.rows;
+00216 pitch = <a class="code" href="a02541.html#NL3D_1_1CFontGeneratorr0">_Face</a>-&gt;glyph-&gt;bitmap.pitch;
+00217
+00218 left = <a class="code" href="a02541.html#NL3D_1_1CFontGeneratorr0">_Face</a>-&gt;glyph-&gt;bitmap_left;
+00219 top = <a class="code" href="a02541.html#NL3D_1_1CFontGeneratorr0">_Face</a>-&gt;glyph-&gt;bitmap_top;
+00220
+00221 advx = <a class="code" href="a02541.html#NL3D_1_1CFontGeneratorr0">_Face</a>-&gt;glyph-&gt;advance.x &gt;&gt; 6;
+00222
+00223 glyphIndex = glyph_index;
+00224
+00225 <span class="keywordflow">return</span> (<a class="code" href="a04558.html#a7">uint8</a> *) <a class="code" href="a02541.html#NL3D_1_1CFontGeneratorr0">_Face</a>-&gt;glyph-&gt;bitmap.buffer;
+00226 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NL3D_1_1CFontGeneratora2" doxytag="NL3D::CFontGenerator::getCharIndex" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a11">uint32</a> NL3D::CFontGenerator::getCharIndex </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a05167.html#a18">ucchar</a>&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>c</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05720.html#l00252">252</a> of file <a class="el" href="a05720.html">font_generator.cpp</a>.
+<p>
+References <a class="el" href="a05721.html#l00096">_Face</a>, <a class="el" href="a06590.html#l00236">ucchar</a>, and <a class="el" href="a05981.html#l00100">uint32</a>.
+<p>
+<div class="fragment"><pre>00253 {
+00254 NL_ALLOC_CONTEXT (FreeTyp);
+00255
+00256 <span class="keywordflow">return</span> FT_Get_Char_Index (_Face, c);
+00257 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NL3D_1_1CFontGeneratord0" doxytag="NL3D::CFontGenerator::getFT2Error" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> const char * NL3D::CFontGenerator::getFT2Error </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top">FT_Error&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>fte</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [private]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05720.html#l00073">73</a> of file <a class="el" href="a05720.html">font_generator.cpp</a>.
+<p>
+References <a class="el" href="a04297.html#a5">ft_errors</a>, <a class="el" href="a05586.html#l00161">NLMISC::smprintf()</a>, and <a class="el" href="a05981.html#l00100">uint32</a>.
+<p>
+Referenced by <a class="el" href="a05720.html#l00093">CFontGenerator()</a>, <a class="el" href="a05720.html#l00173">getBitmap()</a>, <a class="el" href="a05720.html#l00230">getKerning()</a>, and <a class="el" href="a05720.html#l00146">getSizes()</a>.
+<p>
+<div class="fragment"><pre>00074 {
+00075 NL_ALLOC_CONTEXT (FreeTyp);
+00076
+00077 <span class="keyword">static</span> <span class="keywordtype">char</span> ukn[1024];
+00078
+00079 <span class="keywordflow">for</span> (<a class="code" href="a04558.html#a11">uint32</a> i = 0; <a class="code" href="a04297.html#a5">ft_errors</a>[i].err_code != 0 || <a class="code" href="a04297.html#a5">ft_errors</a>[i].err_msg != 0; i++)
+00080 {
+00081 <span class="keywordflow">if</span> (<a class="code" href="a04297.html#a5">ft_errors</a>[i].err_code == fte)
+00082 <span class="keywordflow">return</span> <a class="code" href="a04297.html#a5">ft_errors</a>[i].err_msg;
+00083 }
+00084 <a class="code" href="a05378.html#a259">smprintf</a> (ukn, 1024, <span class="stringliteral">"Unknown freetype2 error, errcode: 0x%x"</span>, fte);
+00085 <span class="keywordflow">return</span> ukn;
+00086 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NL3D_1_1CFontGeneratora3" doxytag="NL3D::CFontGenerator::getKerning" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NL3D::CFontGenerator::getKerning </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a05167.html#a18">ucchar</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>left</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a05167.html#a18">ucchar</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>right</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a04558.html#a10">sint32</a> &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>kernx</em></td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05720.html#l00230">230</a> of file <a class="el" href="a05720.html">font_generator.cpp</a>.
+<p>
+References <a class="el" href="a05721.html#l00096">_Face</a>, <a class="el" href="a05720.html#l00073">getFT2Error()</a>, <a class="el" href="a05622.html#l00154">nlerror</a>, <a class="el" href="a05981.html#l00099">sint32</a>, and <a class="el" href="a06590.html#l00236">ucchar</a>.
+<p>
+<div class="fragment"><pre>00231 {
+00232 NL_ALLOC_CONTEXT (FreeTyp);
+00233
+00234 <span class="keywordflow">if</span> (!FT_HAS_KERNING(_Face))
+00235 {
+00236 kernx = 0;
+00237 }
+00238 <span class="keywordflow">else</span>
+00239 {
+00240 FT_Vector kerning;
+00241 FT_Error error = FT_Get_Kerning (_Face, left, right, ft_kerning_default, &amp;kerning);
+00242 <span class="keywordflow">if</span> (error)
+00243 {
+00244 <a class="code" href="a04199.html#a3">nlerror</a> (<span class="stringliteral">"FT_Get_Kerning() failed: %s"</span>, <a class="code" href="a02541.html#NL3D_1_1CFontGeneratord0">getFT2Error</a>(error));
+00245 }
+00246 kernx = kerning.x;
+00247 }
+00248 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NL3D_1_1CFontGeneratora4" doxytag="NL3D::CFontGenerator::getSizes" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NL3D::CFontGenerator::getSizes </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a05167.html#a18">ucchar</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>c</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a04558.html#a11">uint32</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>size</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a04558.html#a11">uint32</a> &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>width</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a04558.html#a11">uint32</a> &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>height</em></td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+returns the width and height of a character using a specific size and<p>
+<dl compact><dt><b>Warning:</b></dt><dd>this function is not very fast (but faster than <a class="el" href="a02541.html#NL3D_1_1CFontGeneratora1">getBitmap()</a>) because it has to load the char before.</dd></dl>
+
+<p>
+Definition at line <a class="el" href="a05720.html#l00146">146</a> of file <a class="el" href="a05720.html">font_generator.cpp</a>.
+<p>
+References <a class="el" href="a05721.html#l00096">_Face</a>, <a class="el" href="a05720.html#l00073">getFT2Error()</a>, <a class="el" href="a05646.html#l01013">height</a>, <a class="el" href="a05622.html#l00154">nlerror</a>, <a class="el" href="a05646.html#l00645">size</a>, <a class="el" href="a06590.html#l00236">ucchar</a>, <a class="el" href="a05981.html#l00100">uint32</a>, and <a class="el" href="a05646.html#l01013">width</a>.
+<p>
+<div class="fragment"><pre>00147 {
+00148 NL_ALLOC_CONTEXT (FreeTyp);
+00149
+00150 FT_Error error;
+00151
+00152 error = FT_Set_Pixel_Sizes (_Face, size, size);
+00153 <span class="keywordflow">if</span> (error)
+00154 {
+00155 <a class="code" href="a04199.html#a3">nlerror</a> (<span class="stringliteral">"FT_Set_Pixel_Sizes() failed: %s"</span>, <a class="code" href="a02541.html#NL3D_1_1CFontGeneratord0">getFT2Error</a>(error));
+00156 }
+00157
+00158 <span class="comment">// retrieve glyph index from character code</span>
+00159 FT_UInt glyph_index = FT_Get_Char_Index (_Face, c);
+00160
+00161 <span class="comment">// load glyph image into the slot (erase previous one)</span>
+00162 error = FT_Load_Glyph (_Face, glyph_index, FT_LOAD_DEFAULT);
+00163 <span class="keywordflow">if</span> (error)
+00164 {
+00165 <a class="code" href="a04199.html#a3">nlerror</a> (<span class="stringliteral">"FT_Load_Glyph() failed: %s"</span>, <a class="code" href="a02541.html#NL3D_1_1CFontGeneratord0">getFT2Error</a>(error));
+00166 }
+00167
+00168 <span class="comment">// convert 24.6 fixed point into integer</span>
+00169 <a class="code" href="a04223.html#a632">width</a> = <a class="code" href="a02541.html#NL3D_1_1CFontGeneratorr0">_Face</a>-&gt;glyph-&gt;metrics.width &gt;&gt; 6;
+00170 <a class="code" href="a04223.html#a633">height</a> = <a class="code" href="a02541.html#NL3D_1_1CFontGeneratorr0">_Face</a>-&gt;glyph-&gt;metrics.height &gt;&gt; 6;
+00171 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NL3D_1_1CFontGeneratora5" doxytag="NL3D::CFontGenerator::getUID" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a11">uint32</a> NL3D::CFontGenerator::getUID </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inline]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05721.html#l00082">82</a> of file <a class="el" href="a05721.html">font_generator.h</a>.
+<p>
+References <a class="el" href="a05721.html#l00087">_UID</a>, and <a class="el" href="a05981.html#l00100">uint32</a>.
+<p>
+Referenced by <a class="el" href="a06523.html#l00057">NL3D::CTextureFont::SLetterKey::getVal()</a>.
+<p>
+<div class="fragment"><pre>00082 { <span class="keywordflow">return</span> <a class="code" href="a02541.html#NL3D_1_1CFontGeneratorr2">_UID</a>; }
+</pre></div> </td>
+ </tr>
+</table>
+<hr><h2>Field Documentation</h2>
+<a class="anchor" name="NL3D_1_1CFontGeneratorr0" doxytag="NL3D::CFontGenerator::_Face" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> FT_Face <a class="el" href="a02541.html#NL3D_1_1CFontGeneratorr0">NL3D::CFontGenerator::_Face</a><code> [private]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05721.html#l00096">96</a> of file <a class="el" href="a05721.html">font_generator.h</a>.
+<p>
+Referenced by <a class="el" href="a05720.html#l00093">CFontGenerator()</a>, <a class="el" href="a05720.html#l00173">getBitmap()</a>, <a class="el" href="a05720.html#l00252">getCharIndex()</a>, <a class="el" href="a05720.html#l00230">getKerning()</a>, and <a class="el" href="a05720.html#l00146">getSizes()</a>. </td>
+ </tr>
+</table>
+<a class="anchor" name="NL3D_1_1CFontGeneratorr1" doxytag="NL3D::CFontGenerator::_FontFileName" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> std::string <a class="el" href="a02541.html#NL3D_1_1CFontGeneratorr1">NL3D::CFontGenerator::_FontFileName</a><code> [private]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05721.html#l00088">88</a> of file <a class="el" href="a05721.html">font_generator.h</a>.
+<p>
+Referenced by <a class="el" href="a05720.html#l00093">CFontGenerator()</a>. </td>
+ </tr>
+</table>
+<a class="anchor" name="NL3D_1_1CFontGeneratorv0" doxytag="NL3D::CFontGenerator::_FontGeneratorCounterUID" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a11">uint32</a> <a class="el" href="a02541.html#NL3D_1_1CFontGeneratorv0">NL3D::CFontGenerator::_FontGeneratorCounterUID</a> = 1<code> [static, private]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05720.html#l00071">71</a> of file <a class="el" href="a05720.html">font_generator.cpp</a>.
+<p>
+Referenced by <a class="el" href="a05720.html#l00093">CFontGenerator()</a>. </td>
+ </tr>
+</table>
+<a class="anchor" name="NL3D_1_1CFontGeneratorv1" doxytag="NL3D::CFontGenerator::_Library" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> FT_Library <a class="el" href="a02541.html#NL3D_1_1CFontGeneratorv1">NL3D::CFontGenerator::_Library</a><code> [static, private]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05720.html#l00069">69</a> of file <a class="el" href="a05720.html">font_generator.cpp</a>.
+<p>
+Referenced by <a class="el" href="a05720.html#l00093">CFontGenerator()</a>. </td>
+ </tr>
+</table>
+<a class="anchor" name="NL3D_1_1CFontGeneratorv2" doxytag="NL3D::CFontGenerator::_LibraryInit" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> bool <a class="el" href="a02541.html#NL3D_1_1CFontGeneratorv2">NL3D::CFontGenerator::_LibraryInit</a> = false<code> [static, private]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05720.html#l00070">70</a> of file <a class="el" href="a05720.html">font_generator.cpp</a>.
+<p>
+Referenced by <a class="el" href="a05720.html#l00093">CFontGenerator()</a>. </td>
+ </tr>
+</table>
+<a class="anchor" name="NL3D_1_1CFontGeneratorr2" doxytag="NL3D::CFontGenerator::_UID" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a04558.html#a11">uint32</a> <a class="el" href="a02541.html#NL3D_1_1CFontGeneratorr2">NL3D::CFontGenerator::_UID</a><code> [private]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05721.html#l00087">87</a> of file <a class="el" href="a05721.html">font_generator.h</a>.
+<p>
+Referenced by <a class="el" href="a05720.html#l00093">CFontGenerator()</a>, and <a class="el" href="a05721.html#l00082">getUID()</a>. </td>
+ </tr>
+</table>
+<hr>The documentation for this class was generated from the following files:<ul>
+<li><a class="el" href="a05721.html">font_generator.h</a><li><a class="el" href="a05720.html">font_generator.cpp</a></ul>
+<hr size="1"><address style="align: right;"><small>Generated on Tue Mar 16 06:46:57 2004 for NeL by
+<a href="http://www.doxygen.org/index.html">
+<img src="doxygen.png" alt="doxygen" align="middle" border=0 >
+</a>1.3.6 </small></address>
+</body>
+</html>