1

i have a point cloud (an array of vertexes- x,y,z), we can show the point cloud using - with three.js / webgl.

we would use this device:
https://www.sparkfun.com/products/14032
https://www.youtube.com/watch?v=gCpCGkwwy8I

so what we need to do we can do except the point cloud volume estimation.

do you have any pointers how to do this, hopefully, with examples? (i would start from a point cloud and go to the volume estimation)

i am not good in maths, so please, i can use API-s, but not raw/complex maths calculating.

Patrik Laszlo
  • 4,906
  • 8
  • 24
  • 36

2 Answers2

2

My simple method assumes linear interpolation.

Imagine a globe, and that the sensor is at the centre of the Earth's core. Every point in the point cloud then corresponds to the altitude on the surface. When we connect 3 nearest points together, they then form a triangle-ish plot of land. Project the 3 corners back to the sensor and we'll get a very tall triangle-based pyramid aka tetrahedron.

We could then use the formula for the volume of a tetrahedron (1/3 base * height) to get that volume. Sum up all the tetrahedrons and we should get volume of the point cloud.

Perhaps the tricky part is in getting the list of triangles on the surface. We can leverage techniques from computer graphics to convert point clouds to triangular mesh, as answered in this other SO question here.

Leighton Ritchie
  • 501
  • 4
  • 15
  • it is nice of you to helping, i am waiting for more specifics as this answer is too broad, i hope to find a good solution maybe with examples including the volume estimation. :/ – Patrik Laszlo Apr 12 '19 at 05:27
  • it's not a simple problem to tackle, SO might not be ideal for what you're looking for – Leighton Ritchie Apr 12 '19 at 06:05
  • yeah, i am feeling, there is no solution like, there are multiple API-s for face detect, but there is no point cloud volume estimation API, for sure... – Patrik Laszlo Apr 12 '19 at 06:34
2

In order to compute the volume of a point cloud, you need a 3D mesh representation of the point cloud.

Since you added c++ to the question's tag, have you considered using PCL?

PCL offers algorithms for surface reconstruction like here.

After you have the 3D mesh of the point cloud, you can compute the volume of the mesh like this: How to calculate the volume of a 3D mesh object the surface of which is made up triangles

Hope this helps you a bit!

serkan.tuerker
  • 1,681
  • 10
  • 20
  • 1
    thanks you so much, i am waiting for the manager to provide my robot to create a point cloud, then i come back to this , thank you so much for you help! it helps a lot! – Patrik Laszlo Apr 16 '19 at 06:43
  • Hi @kanstar, could you pls help me with the following question about greedy triangulation?https://stackoverflow.com/questions/69782526/pcl-greedy-triangulation-point-traits-h-and-concatenate-h-errors – Mohamed Hedeya Oct 31 '21 at 05:48