Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

saveOBJFile(... PolygonMesh ...) writes faces without spaces #393

Closed
sidch opened this issue Dec 3, 2013 · 4 comments
Closed

saveOBJFile(... PolygonMesh ...) writes faces without spaces #393

sidch opened this issue Dec 3, 2013 · 4 comments

Comments

@sidch
Copy link

sidch commented Dec 3, 2013

The function

int saveOBJFile (const std::string &file_name, const pcl::PolygonMesh &mesh, unsigned precision=5)

in file io/src/obj_io.cpp writes the indices of each face without separating spaces when the face vertices have associated normals. The bug is in line 369:

fs << mesh.polygons[i].vertices[j] + 1 << "//" << mesh.polygons[i].vertices[j] + 1;

The fix is easy: output an extra " " after mesh.polygons[i].vertices[j] + 1.

@jspricke
Copy link
Member

jspricke commented Dec 4, 2013

HI @sidch, thanks for the bug report. As you found the fix already, can you send a pull request with it? That would make it easier for us to integrate it and give you the credits as well ;). If you need help with sending pull requests, don't hesitated to ask.

@nizar-sallem
Copy link
Contributor

@jspricke will fix this

nizar-sallem added a commit to nizar-sallem/pcl that referenced this issue Dec 11, 2013
@nizar-sallem
Copy link
Contributor

@jspricke @rbrusu PR has been merged, should be closed, thanks.

@rbrusu rbrusu closed this as completed Dec 16, 2013
@sidch
Copy link
Author

sidch commented Dec 23, 2013

Sorry for responding late to this, and thanks for the fix! I'll send a pull request next time :).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants