Sophie

Sophie

distrib > Fedora > 16 > i386 > by-pkgid > 4bc66056a634db26a1f4d0845dc41ca6 > files > 5428

mrpt-doc-0.9.5-0.1.20110925svn2670.fc16.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>mrpt::utils::PLY_Importer Class Reference</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
<link href="tabs.css" rel="stylesheet" type="text/css">
</head><body>
<div align="left"><a href="http://www.mrpt.org/">Main MRPT website</a> &gt; <b>C++ reference</b> </div>
<div align="right">
<a href="index.html"><img border="0" src="mrpt_logo.png" alt="MRPT logo"></a>
</div>
<!-- Generated by Doxygen 1.7.5 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li><a href="namespaces.html"><span>Namespaces</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
          <div class="left">
            <form id="FSearchBox" action="search.php" method="get">
              <img id="MSearchSelect" src="search/mag.png" alt=""/>
              <input type="text" id="MSearchField" name="query" value="Search" size="20" accesskey="S" 
                     onfocus="searchBox.OnSearchFieldFocus(true)" 
                     onblur="searchBox.OnSearchFieldFocus(false)"/>
            </form>
          </div><div class="right"></div>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="classes.html"><span>Class&#160;Index</span></a></li>
      <li><a href="inherits.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
  <div id="nav-path" class="navpath">
    <ul>
      <li class="navelem"><a class="el" href="namespacemrpt.html">mrpt</a>      </li>
      <li class="navelem"><a class="el" href="namespacemrpt_1_1utils.html">utils</a>      </li>
      <li class="navelem"><a class="el" href="classmrpt_1_1utils_1_1_p_l_y___importer.html">PLY_Importer</a>      </li>
    </ul>
  </div>
</div>
<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pri-attribs">Private Attributes</a>  </div>
  <div class="headertitle">
<div class="title">mrpt::utils::PLY_Importer Class Reference<div class="ingroups"><a class="el" href="group__mrpt__base__grp.html">[mrpt-base]</a></div></div>  </div>
</div>
<div class="contents">
<!-- doxytag: class="mrpt::utils::PLY_Importer" --><hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
<div class="textblock"><p>A virtual base class that implements the capability of importing 3D point clouds and faces from a file in the Stanford PLY format. </p>
<dl class="see"><dt><b>See also:</b></dt><dd><a href="http://www.mrpt.org/Support_for_the_Stanford_3D_models_file_format_PLY">http://www.mrpt.org/Support_for_the_Stanford_3D_models_file_format_PLY</a> </dd>
<dd>
<a class="el" href="classmrpt_1_1utils_1_1_p_l_y___exporter.html" title="A virtual base class that implements the capability of exporting 3D point clouds and faces to a file ...">PLY_Exporter</a> </dd></dl>
</div>
<p><code>#include &lt;<a class="el" href="_p_l_y__import__export_8h_source.html">mrpt/utils/PLY_import_export.h</a>&gt;</code></p>
<div class="dynheader">
Inheritance diagram for mrpt::utils::PLY_Importer:</div>
<div class="dyncontent">
<div class="center"><img src="classmrpt_1_1utils_1_1_p_l_y___importer__inherit__graph.png" border="0" usemap="#mrpt_1_1utils_1_1_p_l_y___importer_inherit__map" alt="Inheritance graph"/></div>
<map name="mrpt_1_1utils_1_1_p_l_y___importer_inherit__map" id="mrpt_1_1utils_1_1_p_l_y___importer_inherit__map">
<area shape="rect" id="node3" href="classmrpt_1_1opengl_1_1_c_point_cloud.html" title="A cloud of points, all with the same color or each depending on its value along a particular coordina..." alt="" coords="248,5,424,32"/><area shape="rect" id="node5" href="classmrpt_1_1opengl_1_1_c_point_cloud_coloured.html" title="A cloud of points, each one with an individual colour (R,G,B)." alt="" coords="222,56,450,83"/><area shape="rect" id="node7" href="classmrpt_1_1slam_1_1_c_points_map.html" title="A cloud of points in 2D or 3D, which can be built from a sequence of laser scans or other sensors..." alt="" coords="254,107,418,133"/><area shape="rect" id="node9" href="classmrpt_1_1slam_1_1_c_coloured_points_map.html" title="A map of 2D/3D points with individual colours (RGB)." alt="" coords="500,56,716,83"/><area shape="rect" id="node11" href="classmrpt_1_1slam_1_1_c_simple_points_map.html" title="A cloud of points in 2D or 3D, which can be built from a sequence of laser scans." alt="" coords="506,107,710,133"/><area shape="rect" id="node13" href="classmrpt_1_1slam_1_1_c_weighted_points_map.html" title="A cloud of points in 2D or 3D, which can be built from a sequence of laser scans." alt="" coords="499,157,717,184"/></map>
<center><span class="legend">[<a href="graph_legend.html">legend</a>]</span></center></div>

<p><a href="classmrpt_1_1utils_1_1_p_l_y___importer-members.html">List of all members.</a></p>
<table class="memberdecls">
<tr><td colspan="2"><h2><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1utils_1_1_p_l_y___importer.html#a7c340b4858926edfcaa300e85b7e3758">loadFromPlyFile</a> (const <a class="el" href="classstd_1_1string.html">std::string</a> &amp;filename, <a class="el" href="classmrpt_1_1utils_1_1_c_string_list.html">CStringList</a> *file_comments=NULL, <a class="el" href="classmrpt_1_1utils_1_1_c_string_list.html">CStringList</a> *file_obj_info=NULL)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Loads from a PLY file.  <a href="#a7c340b4858926edfcaa300e85b7e3758"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classstd_1_1string.html">std::string</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1utils_1_1_p_l_y___importer.html#a1d9782483d4284c04cde1051b8543435">getLoadPLYErrorString</a> () const </td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Return a description of the error if <a class="el" href="classmrpt_1_1utils_1_1_p_l_y___importer.html#a7c340b4858926edfcaa300e85b7e3758" title="Loads from a PLY file.">loadFromPlyFile()</a> returned false, or an empty string if the file was loaded without problems.  <a href="#a1d9782483d4284c04cde1051b8543435"></a><br/></td></tr>
<tr><td colspan="2"><h2><a name="pro-methods"></a>
Protected Member Functions</h2></td></tr>
<tr><td colspan="2"><div class="groupHeader">PLY Import virtual methods to implement in base classes</div></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1utils_1_1_p_l_y___importer.html#a658b98fa22aabb2282de1c12e953db76">PLY_import_set_vertex_count</a> (const size_t N)=0</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">In a base class, reserve memory to prepare subsequent calls to PLY_import_set_vertex.  <a href="#a658b98fa22aabb2282de1c12e953db76"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1utils_1_1_p_l_y___importer.html#a7942d2b85c0ee7eb6ac0fc3846effc55">PLY_import_set_face_count</a> (const size_t N)=0</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">In a base class, reserve memory to prepare subsequent calls to PLY_import_set_face.  <a href="#a7942d2b85c0ee7eb6ac0fc3846effc55"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1utils_1_1_p_l_y___importer.html#ab4559cc2cf3cc8cd2eb06d03c28d5a10">PLY_import_set_vertex</a> (const size_t idx, const <a class="el" href="structmrpt_1_1math_1_1_t_point3_df.html">mrpt::math::TPoint3Df</a> &amp;pt, const <a class="el" href="structmrpt_1_1utils_1_1_t_colorf.html">mrpt::utils::TColorf</a> *pt_color=NULL)=0</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">In a base class, will be called after <a class="el" href="classmrpt_1_1utils_1_1_p_l_y___importer.html#a658b98fa22aabb2282de1c12e953db76" title="In a base class, reserve memory to prepare subsequent calls to PLY_import_set_vertex.">PLY_import_set_vertex_count()</a> once for each loaded point.  <a href="#ab4559cc2cf3cc8cd2eb06d03c28d5a10"></a><br/></td></tr>
<tr><td colspan="2"><h2><a name="pri-attribs"></a>
Private Attributes</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classstd_1_1string.html">std::string</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classmrpt_1_1utils_1_1_p_l_y___importer.html#ab0632c83ce2e50c65c774c08b5c14624">m_ply_import_last_error</a></td></tr>
</table>
<hr/><h2>Member Function Documentation</h2>
<a class="anchor" id="a1d9782483d4284c04cde1051b8543435"></a><!-- doxytag: member="mrpt::utils::PLY_Importer::getLoadPLYErrorString" ref="a1d9782483d4284c04cde1051b8543435" args="() const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classstd_1_1string.html">std::string</a> mrpt::utils::PLY_Importer::getLoadPLYErrorString </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const<code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Return a description of the error if <a class="el" href="classmrpt_1_1utils_1_1_p_l_y___importer.html#a7c340b4858926edfcaa300e85b7e3758" title="Loads from a PLY file.">loadFromPlyFile()</a> returned false, or an empty string if the file was loaded without problems. </p>

<p>Definition at line <a class="el" href="_p_l_y__import__export_8h_source.html#l00060">60</a> of file <a class="el" href="_p_l_y__import__export_8h_source.html">PLY_import_export.h</a>.</p>

</div>
</div>
<a class="anchor" id="a7c340b4858926edfcaa300e85b7e3758"></a><!-- doxytag: member="mrpt::utils::PLY_Importer::loadFromPlyFile" ref="a7c340b4858926edfcaa300e85b7e3758" args="(const std::string &amp;filename, CStringList *file_comments=NULL, CStringList *file_obj_info=NULL)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool mrpt::utils::PLY_Importer::loadFromPlyFile </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classstd_1_1string.html">std::string</a> &amp;&#160;</td>
          <td class="paramname"><em>filename</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classmrpt_1_1utils_1_1_c_string_list.html">CStringList</a> *&#160;</td>
          <td class="paramname"><em>file_comments</em> = <code>NULL</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="classmrpt_1_1utils_1_1_c_string_list.html">CStringList</a> *&#160;</td>
          <td class="paramname"><em>file_obj_info</em> = <code>NULL</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Loads from a PLY file. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">filename</td><td>The filename to open. It can be either in binary or text format. </td></tr>
    <tr><td class="paramdir">[out]</td><td class="paramname">file_comments</td><td>If provided (!=NULL) the list of comment strings stored in the file will be returned. </td></tr>
    <tr><td class="paramdir">[out]</td><td class="paramname">file_obj_info</td><td>If provided (!=NULL) the list of "object info" strings stored in the file will be returned. </td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>false on any error in the file format or reading it. To obtain more details on the error you can call <a class="el" href="classmrpt_1_1utils_1_1_p_l_y___importer.html#a1d9782483d4284c04cde1051b8543435" title="Return a description of the error if loadFromPlyFile() returned false, or an empty string if the file...">getLoadPLYErrorString()</a> </dd></dl>

</div>
</div>
<a class="anchor" id="a7942d2b85c0ee7eb6ac0fc3846effc55"></a><!-- doxytag: member="mrpt::utils::PLY_Importer::PLY_import_set_face_count" ref="a7942d2b85c0ee7eb6ac0fc3846effc55" args="(const size_t N)=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual void mrpt::utils::PLY_Importer::PLY_import_set_face_count </td>
          <td>(</td>
          <td class="paramtype">const size_t&#160;</td>
          <td class="paramname"><em>N</em></td><td>)</td>
          <td><code> [protected, pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>In a base class, reserve memory to prepare subsequent calls to PLY_import_set_face. </p>

<p>Implemented in <a class="el" href="classmrpt_1_1slam_1_1_c_points_map.html#ad9ea76652470ebba193d23234d93dd56">mrpt::slam::CPointsMap</a>, <a class="el" href="classmrpt_1_1opengl_1_1_c_point_cloud_coloured.html#a58c08dcdd2bfb622afd54764e5b11817">mrpt::opengl::CPointCloudColoured</a>, and <a class="el" href="classmrpt_1_1opengl_1_1_c_point_cloud.html#a5261a38a4fc503a4f88b53e072bdd8d6">mrpt::opengl::CPointCloud</a>.</p>

</div>
</div>
<a class="anchor" id="ab4559cc2cf3cc8cd2eb06d03c28d5a10"></a><!-- doxytag: member="mrpt::utils::PLY_Importer::PLY_import_set_vertex" ref="ab4559cc2cf3cc8cd2eb06d03c28d5a10" args="(const size_t idx, const mrpt::math::TPoint3Df &amp;pt, const mrpt::utils::TColorf *pt_color=NULL)=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual void mrpt::utils::PLY_Importer::PLY_import_set_vertex </td>
          <td>(</td>
          <td class="paramtype">const size_t&#160;</td>
          <td class="paramname"><em>idx</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="structmrpt_1_1math_1_1_t_point3_df.html">mrpt::math::TPoint3Df</a> &amp;&#160;</td>
          <td class="paramname"><em>pt</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="structmrpt_1_1utils_1_1_t_colorf.html">mrpt::utils::TColorf</a> *&#160;</td>
          <td class="paramname"><em>pt_color</em> = <code>NULL</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td><code> [protected, pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>In a base class, will be called after <a class="el" href="classmrpt_1_1utils_1_1_p_l_y___importer.html#a658b98fa22aabb2282de1c12e953db76" title="In a base class, reserve memory to prepare subsequent calls to PLY_import_set_vertex.">PLY_import_set_vertex_count()</a> once for each loaded point. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">pt_color</td><td>Will be NULL if the loaded file does not provide color info. </td></tr>
  </table>
  </dd>
</dl>

<p>Implemented in <a class="el" href="classmrpt_1_1slam_1_1_c_points_map.html#a18e74e4a0750de0cb4e74685d2f73d45">mrpt::slam::CPointsMap</a>, <a class="el" href="classmrpt_1_1slam_1_1_c_coloured_points_map.html#a029c1dfb753c2373217cb075fb072a50">mrpt::slam::CColouredPointsMap</a>, <a class="el" href="classmrpt_1_1opengl_1_1_c_point_cloud_coloured.html#a3c41d068b26383035e6b3ec753bb570a">mrpt::opengl::CPointCloudColoured</a>, and <a class="el" href="classmrpt_1_1opengl_1_1_c_point_cloud.html#a5cc6fd436af604658de92a5c2d33b319">mrpt::opengl::CPointCloud</a>.</p>

</div>
</div>
<a class="anchor" id="a658b98fa22aabb2282de1c12e953db76"></a><!-- doxytag: member="mrpt::utils::PLY_Importer::PLY_import_set_vertex_count" ref="a658b98fa22aabb2282de1c12e953db76" args="(const size_t N)=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual void mrpt::utils::PLY_Importer::PLY_import_set_vertex_count </td>
          <td>(</td>
          <td class="paramtype">const size_t&#160;</td>
          <td class="paramname"><em>N</em></td><td>)</td>
          <td><code> [protected, pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>In a base class, reserve memory to prepare subsequent calls to PLY_import_set_vertex. </p>

<p>Implemented in <a class="el" href="classmrpt_1_1slam_1_1_c_coloured_points_map.html#a8f1a4fc3c5668e5336794e420aefd902">mrpt::slam::CColouredPointsMap</a>, <a class="el" href="classmrpt_1_1opengl_1_1_c_point_cloud_coloured.html#a0b699e92902f9fb3acdc2a23727c2866">mrpt::opengl::CPointCloudColoured</a>, <a class="el" href="classmrpt_1_1slam_1_1_c_simple_points_map.html#a452c8c346268a64723b364ba4e66aeca">mrpt::slam::CSimplePointsMap</a>, <a class="el" href="classmrpt_1_1slam_1_1_c_weighted_points_map.html#ad3391e8acbbe850e063babe28c59593e">mrpt::slam::CWeightedPointsMap</a>, and <a class="el" href="classmrpt_1_1opengl_1_1_c_point_cloud.html#a077218b5a2af944b554239d733dbf92c">mrpt::opengl::CPointCloud</a>.</p>

</div>
</div>
<hr/><h2>Member Data Documentation</h2>
<a class="anchor" id="ab0632c83ce2e50c65c774c08b5c14624"></a><!-- doxytag: member="mrpt::utils::PLY_Importer::m_ply_import_last_error" ref="ab0632c83ce2e50c65c774c08b5c14624" args="" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classstd_1_1string.html">std::string</a> <a class="el" href="classmrpt_1_1utils_1_1_p_l_y___importer.html#ab0632c83ce2e50c65c774c08b5c14624">mrpt::utils::PLY_Importer::m_ply_import_last_error</a><code> [private]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Definition at line <a class="el" href="_p_l_y__import__export_8h_source.html#l00080">80</a> of file <a class="el" href="_p_l_y__import__export_8h_source.html">PLY_import_export.h</a>.</p>

</div>
</div>
</div>
<br><hr><br> <table border="0" width="100%"> <tr> <td> Page generated by <a href="http://www.doxygen.org" target="_blank">Doxygen 1.7.5</a> for MRPT 0.9.5 SVN: at Sun Sep 25 17:20:18 UTC 2011</td><td></td> <td width="100"> </td> <td width="150">  </td></tr> </table>  </body></html>