Sophie

Sophie

distrib > Fedora > 15 > i386 > by-pkgid > 5389723cfaa070fa83dde30f5cb260be > files > 196

compat-guichan05-devel-0.5.0-11.fc15.i686.rpm

<!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>Guichan: gcn::SDLImage Class Reference</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
<link href="tabs.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.4.7 -->
<div class="tabs">
  <ul>
    <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
    <li><a href="namespaces.html"><span>Namespaces</span></a></li>
    <li id="current"><a href="annotated.html"><span>Classes</span></a></li>
    <li><a href="files.html"><span>Files</span></a></li>
  </ul></div>
<div class="tabs">
  <ul>
    <li><a href="annotated.html"><span>Class&nbsp;List</span></a></li>
    <li><a href="hierarchy.html"><span>Class&nbsp;Hierarchy</span></a></li>
    <li><a href="functions.html"><span>Class&nbsp;Members</span></a></li>
  </ul></div>
<div class="nav">
<a class="el" href="namespacegcn.html">gcn</a>::<a class="el" href="classgcn_1_1SDLImage.html">SDLImage</a></div>
<h1>gcn::SDLImage Class Reference</h1><!-- doxytag: class="gcn::SDLImage" --><!-- doxytag: inherits="gcn::Image" --><code>#include &lt;<a class="el" href="sdlimage_8hpp-source.html">sdlimage.hpp</a>&gt;</code>
<p>
<p>Inheritance diagram for gcn::SDLImage:
<p><center><img src="classgcn_1_1SDLImage.png" usemap="#gcn::SDLImage_map" border="0" alt=""></center>
<map name="gcn::SDLImage_map">
<area href="classgcn_1_1Image.html" alt="gcn::Image" shape="rect" coords="0,0,96,24">
</map>
<a href="classgcn_1_1SDLImage-members.html">List of all members.</a><hr><a name="_details"></a><h2>Detailed Description</h2>
SDL implementation of <a class="el" href="classgcn_1_1Image.html">Image</a>. 
<p>

<p>
Definition at line <a class="el" href="sdlimage_8hpp-source.html#l00073">73</a> of file <a class="el" href="sdlimage_8hpp-source.html">sdlimage.hpp</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="classgcn_1_1SDLImage.html#47271c3b3b77dc33af535a294ffbbaf5">SDLImage</a> (SDL_Surface *surface, bool autoFree)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Constructor.  <a href="#47271c3b3b77dc33af535a294ffbbaf5"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="ac706c9b974d455c78234019c8810bec"></a><!-- doxytag: member="gcn::SDLImage::~SDLImage" ref="ac706c9b974d455c78234019c8810bec" args="()" -->
virtual&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgcn_1_1SDLImage.html#ac706c9b974d455c78234019c8810bec">~SDLImage</a> ()</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Destructor. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual SDL_Surface *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgcn_1_1SDLImage.html#6de7994d61fbab88647d8554a17ff708">getSurface</a> () const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Gets the SDL surface for the image.  <a href="#6de7994d61fbab88647d8554a17ff708"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="3bc4ad47bfe36987a48226a676f9f576"></a><!-- doxytag: member="gcn::SDLImage::free" ref="3bc4ad47bfe36987a48226a676f9f576" args="()" -->
virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgcn_1_1SDLImage.html#3bc4ad47bfe36987a48226a676f9f576">free</a> ()</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Frees an image. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgcn_1_1SDLImage.html#edda43f210a3e661685636684977eb1e">getWidth</a> () const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Gets the width of the <a class="el" href="classgcn_1_1Image.html">Image</a>.  <a href="#edda43f210a3e661685636684977eb1e"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgcn_1_1SDLImage.html#92002975749328bf9c46c6a647b949d9">getHeight</a> () const </td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Gets the height of the <a class="el" href="classgcn_1_1Image.html">Image</a>.  <a href="#92002975749328bf9c46c6a647b949d9"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classgcn_1_1Color.html">Color</a>&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgcn_1_1SDLImage.html#f6f2df0d39d68b7c0547943f368f3726">getPixel</a> (int x, int y)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Gets the color of a pixel at coordinate (x, y) in the image.  <a href="#f6f2df0d39d68b7c0547943f368f3726"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgcn_1_1SDLImage.html#707af6ce207dff83174dd91dfd4b4148">putPixel</a> (int x, int y, const <a class="el" href="classgcn_1_1Color.html">Color</a> &amp;color)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Puts a pixel with a certain color at coordinate (x, y).  <a href="#707af6ce207dff83174dd91dfd4b4148"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgcn_1_1SDLImage.html#d9b2c696a7c58af497c3830ad9d76861">convertToDisplayFormat</a> ()</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Converts the image, if possible, to display format.  <a href="#d9b2c696a7c58af497c3830ad9d76861"></a><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="anchor" name="4bf5919ded9c1b71495746f54a6a54ff"></a><!-- doxytag: member="gcn::SDLImage::mSurface" ref="4bf5919ded9c1b71495746f54a6a54ff" args="" -->
SDL_Surface *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgcn_1_1SDLImage.html#4bf5919ded9c1b71495746f54a6a54ff">mSurface</a></td></tr>

<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="4cbb771d212e3f72773ef2e6fae20565"></a><!-- doxytag: member="gcn::SDLImage::mAutoFree" ref="4cbb771d212e3f72773ef2e6fae20565" args="" -->
bool&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgcn_1_1SDLImage.html#4cbb771d212e3f72773ef2e6fae20565">mAutoFree</a></td></tr>

</table>
<hr><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" name="47271c3b3b77dc33af535a294ffbbaf5"></a><!-- doxytag: member="gcn::SDLImage::SDLImage" ref="47271c3b3b77dc33af535a294ffbbaf5" args="(SDL_Surface *surface, bool autoFree)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">gcn::SDLImage::SDLImage           </td>
          <td>(</td>
          <td class="paramtype">SDL_Surface *&nbsp;</td>
          <td class="paramname"> <em>surface</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&nbsp;</td>
          <td class="paramname"> <em>autoFree</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Constructor. 
<p>
Load an image from an SDL surface.<p>
NOTE: The functions getPixel and putPixel are only guaranteed to work before an image has been converted to display format.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>surface</em>&nbsp;</td><td>the surface from which to load. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>autoFree</em>&nbsp;</td><td>true if the surface should automatically be deleted. </td></tr>
  </table>
</dl>

<p>
Definition at line <a class="el" href="sdlimage_8cpp-source.html#l00068">68</a> of file <a class="el" href="sdlimage_8cpp-source.html">sdlimage.cpp</a>.
<p>
References <a class="el" href="sdlimage_8hpp-source.html#l00116">mAutoFree</a>, and <a class="el" href="sdlimage_8hpp-source.html#l00115">mSurface</a>.
</div>
</div><p>
<hr><h2>Member Function Documentation</h2>
<a class="anchor" name="d9b2c696a7c58af497c3830ad9d76861"></a><!-- doxytag: member="gcn::SDLImage::convertToDisplayFormat" ref="d9b2c696a7c58af497c3830ad9d76861" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void gcn::SDLImage::convertToDisplayFormat           </td>
          <td>(</td>
          <td class="paramname">          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"><code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Converts the image, if possible, to display format. 
<p>
IMPORTANT: Only guaranteed to work before the image has been converted to display format. 
<p>
Implements <a class="el" href="classgcn_1_1Image.html#3e59862b9a8fdb2bd3cffd9ba39969af">gcn::Image</a>.
<p>
Definition at line <a class="el" href="sdlimage_8cpp-source.html#l00127">127</a> of file <a class="el" href="sdlimage_8cpp-source.html">sdlimage.cpp</a>.
<p>
References <a class="el" href="sdlimage_8hpp-source.html#l00115">mSurface</a>.
</div>
</div><p>
<a class="anchor" name="92002975749328bf9c46c6a647b949d9"></a><!-- doxytag: member="gcn::SDLImage::getHeight" ref="92002975749328bf9c46c6a647b949d9" args="() const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int gcn::SDLImage::getHeight           </td>
          <td>(</td>
          <td class="paramname">          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"> const<code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Gets the height of the <a class="el" href="classgcn_1_1Image.html">Image</a>. 
<p>
<dl compact><dt><b>Returns:</b></dt><dd>the image height </dd></dl>

<p>
Implements <a class="el" href="classgcn_1_1Image.html#09df6a36dc5a76a75a0dd5720f40ee0d">gcn::Image</a>.
<p>
Definition at line <a class="el" href="sdlimage_8cpp-source.html#l00097">97</a> of file <a class="el" href="sdlimage_8cpp-source.html">sdlimage.cpp</a>.
<p>
References <a class="el" href="sdlimage_8hpp-source.html#l00115">mSurface</a>.
</div>
</div><p>
<a class="anchor" name="f6f2df0d39d68b7c0547943f368f3726"></a><!-- doxytag: member="gcn::SDLImage::getPixel" ref="f6f2df0d39d68b7c0547943f368f3726" args="(int x, int y)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classgcn_1_1Color.html">Color</a> gcn::SDLImage::getPixel           </td>
          <td>(</td>
          <td class="paramtype">int&nbsp;</td>
          <td class="paramname"> <em>x</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&nbsp;</td>
          <td class="paramname"> <em>y</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"><code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Gets the color of a pixel at coordinate (x, y) in the image. 
<p>
IMPORTANT: Only guaranteed to work before the image has been converted to display format.<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>x</em>&nbsp;</td><td>the x coordinate. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>y</em>&nbsp;</td><td>the y coordinate. </td></tr>
  </table>
</dl>
<dl compact><dt><b>Returns:</b></dt><dd>the color of the pixel. </dd></dl>

<p>
Implements <a class="el" href="classgcn_1_1Image.html#38e79120cc9f81bb36727e2859e04a09">gcn::Image</a>.
<p>
Definition at line <a class="el" href="sdlimage_8cpp-source.html#l00107">107</a> of file <a class="el" href="sdlimage_8cpp-source.html">sdlimage.cpp</a>.
<p>
References <a class="el" href="sdlimage_8hpp-source.html#l00115">mSurface</a>, and <a class="el" href="sdlpixel_8hpp-source.html#l00074">gcn::SDLgetPixel()</a>.
</div>
</div><p>
<a class="anchor" name="6de7994d61fbab88647d8554a17ff708"></a><!-- doxytag: member="gcn::SDLImage::getSurface" ref="6de7994d61fbab88647d8554a17ff708" args="() const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">SDL_Surface * gcn::SDLImage::getSurface           </td>
          <td>(</td>
          <td class="paramname">          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"> const<code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Gets the SDL surface for the image. 
<p>
<dl compact><dt><b>Returns:</b></dt><dd>the SDL surface for the image. </dd></dl>

<p>
Definition at line <a class="el" href="sdlimage_8cpp-source.html#l00082">82</a> of file <a class="el" href="sdlimage_8cpp-source.html">sdlimage.cpp</a>.
<p>
References <a class="el" href="sdlimage_8hpp-source.html#l00115">mSurface</a>.
<p>
Referenced by <a class="el" href="sdlgraphics_8cpp-source.html#l00143">gcn::SDLGraphics::drawImage()</a>.
</div>
</div><p>
<a class="anchor" name="edda43f210a3e661685636684977eb1e"></a><!-- doxytag: member="gcn::SDLImage::getWidth" ref="edda43f210a3e661685636684977eb1e" args="() const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int gcn::SDLImage::getWidth           </td>
          <td>(</td>
          <td class="paramname">          </td>
          <td>&nbsp;)&nbsp;</td>
          <td width="100%"> const<code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Gets the width of the <a class="el" href="classgcn_1_1Image.html">Image</a>. 
<p>
<dl compact><dt><b>Returns:</b></dt><dd>the image width </dd></dl>

<p>
Implements <a class="el" href="classgcn_1_1Image.html#a367cc8121c1f01a541e615b0a27497c">gcn::Image</a>.
<p>
Definition at line <a class="el" href="sdlimage_8cpp-source.html#l00087">87</a> of file <a class="el" href="sdlimage_8cpp-source.html">sdlimage.cpp</a>.
<p>
References <a class="el" href="sdlimage_8hpp-source.html#l00115">mSurface</a>.
</div>
</div><p>
<a class="anchor" name="707af6ce207dff83174dd91dfd4b4148"></a><!-- doxytag: member="gcn::SDLImage::putPixel" ref="707af6ce207dff83174dd91dfd4b4148" args="(int x, int y, const Color &amp;color)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void gcn::SDLImage::putPixel           </td>
          <td>(</td>
          <td class="paramtype">int&nbsp;</td>
          <td class="paramname"> <em>x</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&nbsp;</td>
          <td class="paramname"> <em>y</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="classgcn_1_1Color.html">Color</a> &amp;&nbsp;</td>
          <td class="paramname"> <em>color</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td width="100%"><code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Puts a pixel with a certain color at coordinate (x, y). 
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>x</em>&nbsp;</td><td>the x coordinate. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>y</em>&nbsp;</td><td>the y coordinate. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>color</em>&nbsp;</td><td>the color of the pixel to put. </td></tr>
  </table>
</dl>

<p>
Implements <a class="el" href="classgcn_1_1Image.html#4a023341cacd32ca4448ceec4b79be4a">gcn::Image</a>.
<p>
Definition at line <a class="el" href="sdlimage_8cpp-source.html#l00117">117</a> of file <a class="el" href="sdlimage_8cpp-source.html">sdlimage.cpp</a>.
<p>
References <a class="el" href="sdlimage_8hpp-source.html#l00115">mSurface</a>, and <a class="el" href="sdlpixel_8hpp-source.html#l00126">gcn::SDLputPixel()</a>.
</div>
</div><p>
<hr>The documentation for this class was generated from the following files:<ul>
<li><a class="el" href="sdlimage_8hpp-source.html">sdlimage.hpp</a><li><a class="el" href="sdlimage_8cpp-source.html">sdlimage.cpp</a></ul>
<hr size="1"><address style="align: right;"><small>Generated on Sat Jul 29 19:38:49 2006 for Guichan by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.4.7 </small></address>
</body>
</html>