blob: d8561de99981bb385a12540ab90255d30dd06f96 [file] [log] [blame]
<!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>FTGL: FTGlyph class Reference</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.3.6 -->
<div class="qindex"><a class="qindex" href="index.html">Main&nbsp;Page</a> | <a class="qindex" href="hierarchy.html">Class&nbsp;Hierarchy</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="functions.html">Data&nbsp;Fields</a> | <a class="qindex" href="globals.html">Globals</a></div>
<h1>FTGlyph Class Reference</h1><code>#include &lt;<a class="el" href="FTGlyph_8h-source.html">FTGlyph.h</a>&gt;</code>
<p>
<p>Inheritance diagram for FTGlyph:
<p><center><img src="classFTGlyph.png" usemap="#FTGlyph_map" border="0" alt=""></center>
<map name="FTGlyph_map">
<area href="classFTBitmapGlyph.html" alt="FTBitmapGlyph" shape="rect" coords="0,56,102,80">
<area href="classFTExtrdGlyph.html" alt="FTExtrdGlyph" shape="rect" coords="112,56,214,80">
<area href="classFTOutlineGlyph.html" alt="FTOutlineGlyph" shape="rect" coords="224,56,326,80">
<area href="classFTPixmapGlyph.html" alt="FTPixmapGlyph" shape="rect" coords="336,56,438,80">
<area href="classFTPolyGlyph.html" alt="FTPolyGlyph" shape="rect" coords="448,56,550,80">
<area href="classFTTextureGlyph.html" alt="FTTextureGlyph" shape="rect" coords="560,56,662,80">
</map>
<hr><a name="_details"></a><h2>Detailed Description</h2>
FTGlyph is the base class for FTGL glyphs.
<p>
It provides the interface between Freetype glyphs and their openGL renderable counterparts. This is an abstract class and derived classes must implement the <code>render</code> function.<p>
<dl compact><dt><b>See also:</b></dt><dd><a class="el" href="classFTGlyphContainer.html">FTGlyphContainer</a> <p>
<a class="el" href="classFTBBox.html">FTBBox</a> <p>
<a class="el" href="classFTPoint.html">FTPoint</a> </dd></dl>
<p>
<p>
Definition at line <a class="el" href="FTGlyph_8h-source.html#l00025">25</a> of file <a class="el" href="FTGlyph_8h-source.html">FTGlyph.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="classFTGlyph.html#a0">FTGlyph</a> (FT_GlyphSlot glyph, bool <a class="el" href="classFTGlyph.html#p2">useDisplayList</a>=true)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Constructor. <a href="#a0"></a><br><br></td></tr>
<tr><td class="memItemLeft" nowrap align=right valign=top>virtual&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classFTGlyph.html#a1">~FTGlyph</a> ()</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Destructor. <a href="#a1"></a><br><br></td></tr>
<tr><td class="memItemLeft" nowrap align=right valign=top>virtual const <a class="el" href="classFTPoint.html">FTPoint</a> &amp;&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classFTGlyph.html#a2">Render</a> (const <a class="el" href="classFTPoint.html">FTPoint</a> &amp;pen)=0</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Renders this glyph at the current pen position. <a href="#a2"></a><br><br></td></tr>
<tr><td class="memItemLeft" nowrap align=right valign=top>const <a class="el" href="classFTPoint.html">FTPoint</a> &amp;&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classFTGlyph.html#a3">Advance</a> () const </td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the advance width for this glyph. <a href="#a3"></a><br><br></td></tr>
<tr><td class="memItemLeft" nowrap align=right valign=top>const <a class="el" href="classFTBBox.html">FTBBox</a> &amp;&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classFTGlyph.html#a4">BBox</a> () const </td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the bounding box for this glyph. <a href="#a4"></a><br><br></td></tr>
<tr><td class="memItemLeft" nowrap align=right valign=top>FT_Error&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classFTGlyph.html#a5">Error</a> () const </td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Queries for errors. <a href="#a5"></a><br><br></td></tr>
<tr><td colspan=2><br><h2>Protected Attributes</h2></td></tr>
<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="classFTPoint.html">FTPoint</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classFTGlyph.html#p0">advance</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">The advance distance for this glyph. <a href="#p0"></a><br><br></td></tr>
<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="classFTBBox.html">FTBBox</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classFTGlyph.html#p1">bBox</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">The bounding box of this glyph. <a href="#p1"></a><br><br></td></tr>
<tr><td class="memItemLeft" nowrap align=right valign=top>bool&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classFTGlyph.html#p2">useDisplayList</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Flag to enable or disable the use of Display Lists inside FTGL <code>true</code> turns ON display lists. <a href="#p2"></a><br><br></td></tr>
<tr><td class="memItemLeft" nowrap align=right valign=top>FT_Error&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classFTGlyph.html#p3">err</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Current error code. <a href="#p3"></a><br><br></td></tr>
</table>
<hr><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" name="a0" doxytag="FTGlyph::FTGlyph" ></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"> FTGlyph::FTGlyph </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">FT_GlyphSlot&nbsp;</td>
<td class="mdname" nowrap> <em>glyph</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td></td>
<td class="md" nowrap>bool&nbsp;</td>
<td class="mdname" nowrap> <em>useDisplayList</em> = true</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.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign=top><em>glyph</em>&nbsp;</td><td>The Freetype glyph to be processed </td></tr>
<tr><td valign=top><em>useDisplayList</em>&nbsp;</td><td>Enable or disable the use of Display Lists for this glyph <code>true</code> turns ON display lists. <code>false</code> turns OFF display lists. </td></tr>
</table>
</dl>
<p>
Definition at line <a class="el" href="FTGlyph_8cpp-source.html#l00004">4</a> of file <a class="el" href="FTGlyph_8cpp-source.html">FTGlyph.cpp</a>.
<p>
References <a class="el" href="FTGlyph_8h-source.html#l00076">advance</a>, and <a class="el" href="FTGlyph_8h-source.html#l00081">bBox</a>. </td>
</tr>
</table>
<a class="anchor" name="a1" doxytag="FTGlyph::~FTGlyph" ></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"> FTGlyph::~<a class="el" href="classFTGlyph.html">FTGlyph</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>
Destructor.
<p>
<p>
Definition at line <a class="el" href="FTGlyph_8cpp-source.html#l00016">16</a> of file <a class="el" href="FTGlyph_8cpp-source.html">FTGlyph.cpp</a>. </td>
</tr>
</table>
<hr><h2>Member Function Documentation</h2>
<a class="anchor" name="a3" doxytag="FTGlyph::Advance" ></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 <a class="el" href="classFTPoint.html">FTPoint</a>&amp; FTGlyph::Advance </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> const<code> [inline]</code></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Return the advance width for this glyph.
<p>
<dl compact><dt><b>Returns:</b></dt><dd>advance width. </dd></dl>
<p>
Definition at line <a class="el" href="FTGlyph_8h-source.html#l00056">56</a> of file <a class="el" href="FTGlyph_8h-source.html">FTGlyph.h</a>. </td>
</tr>
</table>
<a class="anchor" name="a4" doxytag="FTGlyph::BBox" ></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 <a class="el" href="classFTBBox.html">FTBBox</a>&amp; FTGlyph::BBox </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> const<code> [inline]</code></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Return the bounding box for this glyph.
<p>
<dl compact><dt><b>Returns:</b></dt><dd>bounding box. </dd></dl>
<p>
Definition at line <a class="el" href="FTGlyph_8h-source.html#l00063">63</a> of file <a class="el" href="FTGlyph_8h-source.html">FTGlyph.h</a>. </td>
</tr>
</table>
<a class="anchor" name="a5" doxytag="FTGlyph::Error" ></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_Error FTGlyph::Error </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> const<code> [inline]</code></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Queries for errors.
<p>
<dl compact><dt><b>Returns:</b></dt><dd>The current error code. </dd></dl>
<p>
Definition at line <a class="el" href="FTGlyph_8h-source.html#l00070">70</a> of file <a class="el" href="FTGlyph_8h-source.html">FTGlyph.h</a>. </td>
</tr>
</table>
<a class="anchor" name="a2" doxytag="FTGlyph::Render" ></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"> virtual const <a class="el" href="classFTPoint.html">FTPoint</a>&amp; FTGlyph::Render </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">const <a class="el" href="classFTPoint.html">FTPoint</a> &amp;&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>pen</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap><code> [pure virtual]</code></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Renders this glyph at the current pen position.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign=top><em>pen</em>&nbsp;</td><td>The current pen position. </td></tr>
</table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>The advance distance for this glyph. </dd></dl>
<p>
Implemented in <a class="el" href="classFTBitmapGlyph.html#a2">FTBitmapGlyph</a>, <a class="el" href="classFTExtrdGlyph.html#a2">FTExtrdGlyph</a>, <a class="el" href="classFTOutlineGlyph.html#a2">FTOutlineGlyph</a>, <a class="el" href="classFTPixmapGlyph.html#a2">FTPixmapGlyph</a>, <a class="el" href="classFTPolyGlyph.html#a2">FTPolyGlyph</a>, and <a class="el" href="classFTTextureGlyph.html#a2">FTTextureGlyph</a>. </td>
</tr>
</table>
<hr><h2>Field Documentation</h2>
<a class="anchor" name="p0" doxytag="FTGlyph::advance" ></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="classFTPoint.html">FTPoint</a> <a class="el" href="classFTGlyph.html#p0">FTGlyph::advance</a><code> [protected]</code>
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
The advance distance for this glyph.
<p>
<p>
Definition at line <a class="el" href="FTGlyph_8h-source.html#l00076">76</a> of file <a class="el" href="FTGlyph_8h-source.html">FTGlyph.h</a>.
<p>
Referenced by <a class="el" href="FTGlyph_8cpp-source.html#l00004">FTGlyph()</a>. </td>
</tr>
</table>
<a class="anchor" name="p1" doxytag="FTGlyph::bBox" ></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="classFTBBox.html">FTBBox</a> <a class="el" href="classFTGlyph.html#p1">FTGlyph::bBox</a><code> [protected]</code>
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
The bounding box of this glyph.
<p>
<p>
Definition at line <a class="el" href="FTGlyph_8h-source.html#l00081">81</a> of file <a class="el" href="FTGlyph_8h-source.html">FTGlyph.h</a>.
<p>
Referenced by <a class="el" href="FTGlyph_8cpp-source.html#l00004">FTGlyph()</a>. </td>
</tr>
</table>
<a class="anchor" name="p3" doxytag="FTGlyph::err" ></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_Error <a class="el" href="classFTGlyph.html#p3">FTGlyph::err</a><code> [protected]</code>
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Current error code.
<p>
Zero means no error.
<p>
Definition at line <a class="el" href="FTGlyph_8h-source.html#l00093">93</a> of file <a class="el" href="FTGlyph_8h-source.html">FTGlyph.h</a>. </td>
</tr>
</table>
<a class="anchor" name="p2" doxytag="FTGlyph::useDisplayList" ></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="classFTGlyph.html#p2">FTGlyph::useDisplayList</a><code> [protected]</code>
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Flag to enable or disable the use of Display Lists inside FTGL <code>true</code> turns ON display lists.
<p>
<code>false</code> turns OFF display lists.
<p>
Definition at line <a class="el" href="FTGlyph_8h-source.html#l00088">88</a> of file <a class="el" href="FTGlyph_8h-source.html">FTGlyph.h</a>. </td>
</tr>
</table>
<hr>The documentation for this class was generated from the following files:<ul>
<li><a class="el" href="FTGlyph_8h-source.html">FTGlyph.h</a><li><a class="el" href="FTGlyph_8cpp-source.html">FTGlyph.cpp</a></ul>
<hr size="1"><address style="align: right;"><small>Generated on Sun Dec 5 22:24:07 2004 for FTGL 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>