mirror of
https://github.com/lucaspalomodevelop/meshlab.git
synced 2026-03-19 19:14:42 +00:00
up-to-date method Save.
This commit is contained in:
parent
276b1fa7c5
commit
205e1f04e5
@ -47,6 +47,9 @@ namespace vcg
|
||||
|
||||
static bool Save(SaveMeshType &m, const char * filename , bool binary =true, const char *objectname=0)
|
||||
{
|
||||
if(m.vert.size() == 0)return false;
|
||||
if(m.face.size() == 0)return false;
|
||||
|
||||
if(binary)
|
||||
{
|
||||
return false;
|
||||
@ -56,7 +59,7 @@ namespace vcg
|
||||
std::ofstream stream(filename);
|
||||
|
||||
if (stream.fail())
|
||||
return false;
|
||||
return false;
|
||||
|
||||
stream << "#GENERATED BY EXPORT_OBJ" << std::endl;
|
||||
|
||||
@ -64,9 +67,7 @@ namespace vcg
|
||||
stream << std::endl << "#VERTEXS" << std::endl;
|
||||
VertexIterator vi;
|
||||
for(vi=m.vert.begin(); vi!=m.vert.end(); ++vi)
|
||||
{
|
||||
stream << "v " << (*vi).P()[0] << " " << (*vi).P()[1] << " " << (*vi).P()[2] << std::endl;
|
||||
}
|
||||
|
||||
//facce
|
||||
stream << std::endl << "#FACES" << std::endl;
|
||||
@ -84,7 +85,6 @@ namespace vcg
|
||||
}
|
||||
|
||||
stream.close();
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user