Skip to content

Read the data type for #vertices/face from PLY header#15

Open
cy94 wants to merge 1 commit intoniessner:masterfrom
cy94:read_vertices_per_face
Open

Read the data type for #vertices/face from PLY header#15
cy94 wants to merge 1 commit intoniessner:masterfrom
cy94:read_vertices_per_face

Conversation

@cy94
Copy link
Copy Markdown

@cy94 cy94 commented Jun 13, 2022

  • The loadFromPLY function assumes the PLY header line about faces to be property list uchar int vertex_indices.
  • However, the uchar field could be replaced by int, for example in the output of Poisson Reconstruction's Surface Trimmer.
  • Hence, read this line of the header and store the number of bytes in verticesPerFace in the PlyHeader
  • Then use it to correctly read the faces in the PLY file.
  • Example data to test this code: test.zip
    • Earlier behaviour: throws a vector index out of bound exception
    • Now: file is read successfully
  • Additionally remove some commented code

@cy94 cy94 changed the title Read the data type for #vertices/face from PLY header, remove commented Read the data type for #vertices/face from PLY header Jun 13, 2022
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

Successfully merging this pull request may close these issues.

1 participant