4
$\begingroup$

I have around 5500 .ply files, which amount to about 7 GB of point cloud data; each file is one frame of animation.

Is there any feasible way of importing this into blender for processing? I am aware of tools like Stop-motion-OBJ and Sverchok nodes; however, due to the large number of files, blender simply can't handle it.

The only solution I've found is setting up a scene with camera and lights, and then importing and rendering each frame separately with a script, similar to the procedure detailed here. However, since I only have the point cloud data, I'd have to add spheres around each point to be able to render them. This amounts to creating a new .ply file with vertices corresponding to a sphere centered around each point. I've already managed to automate this process; however, according to my calculations, the last frame alone would have a size of 10 GB after appending the spheres.

$\endgroup$
4
  • 2
    $\begingroup$ Welcome to Blender Stack Exchange. My gut feeling is you would need to have an object that uses Particles or Dupliverts to generate the "spheres" you mentioned, and swap out the mesh data on each frame using a Python script. Sorry I can't offer more more specific details on how to do this. $\endgroup$
    – Mentalist
    Jun 17 '19 at 3:37
  • $\begingroup$ Maybe create a single triangle instead a sphere and use script to make it Billboard effect? Or you may want to go in OpenGL for directly render those point cloud $\endgroup$
    – HikariTW
    Jun 17 '19 at 7:37
  • $\begingroup$ Expanding on Mentalists suggestion: When you import a ply the data looks like a lot of vertices (points) but no lines or faces. When using dupliverts the object gets duplicated on each of these vertices (this takes care of creating spheres). This process takes very little memory because the same mesh data is just linked each time. Thus the script basically needs to (1. import next ply 2. parent object to imported ply 3. enable dupliverts 4. render 5. delete ply ). Animating a vertex through all plys will need some serious processing. $\endgroup$ Jun 17 '19 at 8:08
  • $\begingroup$ This isn't ideal, but could you split the sequence of .ply files into multiple chunks, and create multiple blend files, each with their own subset of the sequence? $\endgroup$
    – Justin
    Jul 25 '19 at 22:33
0
$\begingroup$
  • Import one file as a single mesh. You won't have any edges or faces, but the next bit should work.
  • Add one sphere to your scene. Make it low resolution because there are going to be a lot of them.
  • Parent the sphere to the point cloud mesh.
  • Go to the Object properties of the mesh, and set instancing to vertices.

Setting instancing

Instancing should save memory, and you can render this as a single frame.

It should even be straightforward to write a shell script to iterate through the process and a Python script for the import, instancing and render.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.