libigl / libigl-example-project

A blank project example showing how to use libigl and cmake.
Mozilla Public License 2.0
142 stars 121 forks source link

IOError #14

Closed Bachery closed 6 years ago

Bachery commented 6 years ago

The example runs successfully. But when I replace the code with tutorial 101:

#include <igl/readOFF.h>
#include <igl/writeOBJ.h>
#include <iostream>

Eigen::MatrixXd V;
Eigen::MatrixXi F;

int main(int argc, char *argv[])
{
  // Load a mesh in OFF format
  igl::readOFF("cube.off", V, F);

  // Print the vertices and faces matrices
  std::cout << "Vertices: " << std::endl << V << std::endl;
  std::cout << "Faces:    " << std::endl << F << std::endl;

  // Save the mesh in OBJ format
  igl::writeOBJ("cube.obj",V,F);
}

an IOError occurs while running: IOError: cube.off could not be opened...