fix documentation to reflect new tutorial_shared_path configured var

This commit is contained in:
Daniel Crispell
2015-10-09 23:03:24 -04:00
parent a0eed05e8b
commit 99f4ece13a
2 changed files with 10 additions and 8 deletions
+6 -4
View File
@@ -273,7 +273,7 @@ By default, the .h files include the corresponding cpp files, making the library
<p>Reading a mesh from a file requires a single libigl function call:</p>
<pre><code class="cpp">igl::readOFF(&quot;../shared/cube.off&quot;, V, F);
<pre><code class="cpp">igl::readOFF(tutorial_shared_path + &quot;/cube.off&quot;, V, F);
</code></pre>
<p>The function reads the mesh cube.off and it fills the provided <code>V</code> and <code>F</code> matrices.
@@ -298,13 +298,15 @@ render it.</p>
<pre><code class="cpp">#include &lt;igl/readOFF.h&gt;
#include &lt;igl/viewer/Viewer.h&gt;
#include &quot;tutorial_shared_path.h&quot;
Eigen::MatrixXd V;
Eigen::MatrixXi F;
int main(int argc, char *argv[])
{
// Load a mesh in OFF format
igl::readOFF(&quot;../shared/bunny.off&quot;, V, F);
igl::readOFF(tutorial_shared_path + &quot;/bunny.off&quot;, V, F);
// Plot the mesh
igl::Viewer viewer;
@@ -2593,7 +2595,7 @@ viewer.</figcaption>
&#8220;Workspaces&#8221;. This C++ snippet saves a mesh and it&#8217;s sparse Laplacian matrix to
a file:</p>
<pre><code class="cpp">igl::readOFF(&quot;../shared/fertility.off&quot;, V, F);
<pre><code class="cpp">igl::readOFF(tutorial_shared_path + &quot;/fertility.off&quot;, V, F);
igl::cotmatrix(V,F,L);
igl::MatlabWorkspace mw;
mw.save(V,&quot;V&quot;);
@@ -2617,7 +2619,7 @@ instance upon execution.</p>
Libigl has wrapped up a particularly useful formatting which makes it simple to
copy standard output from a C++ program into a Matlab IDE. The code:</p>
<pre><code class="cpp">igl::readOFF(&quot;../shared/2triangles.off&quot;, V, F);
<pre><code class="cpp">igl::readOFF(tutorial_shared_path + &quot;/2triangles.off&quot;, V, F);
igl::cotmatrix(V,F,L);
std::cout&lt;&lt;igl::matlab_format(V,&quot;V&quot;)&lt;&lt;std::endl;
std::cout&lt;&lt;igl::matlab_format((F.array()+1).eval(),&quot;F&quot;)&lt;&lt;std::endl;