Save ply with normals

Is there a simple way to save a PLY with X,Y,Z AND NORMALS?

My goal is to grab an image and save the one image with X,Y,Z and normals. Currently I am having to re-create the normals in my application and its very time consuming.


It’s not currently possible to directly generate a PLY file with both the X Y Z and the normals in a single image.

However, you can retrieve the X,Y,Z data and the normals in two separates images, using the retrievemeasure method.

You can chose what type of data to extract by changing the value of the enum “sl::MEASURE” :

  • sl::MEASURE::XYZ for the 3D position and sl::MEASURE::NORMALS for the normals.

Benjamin Vallon