Transfer color from mesh to point cloud in pymeshlab

553 views Asked by At

I'm trying to convert a 3D model to a colored point cloud. I'm using Motecarlo sampling and then Texture to vertex color. The problem is that I also need color information from the material. I'm using .obj models from the ShapeNet dataset.

mesh = pml.MeshSet()
mesh.load_new_mesh(f'{model_path}/models/model_normalized.obj')
mesh.generate_sampling_montecarlo(samplenum=16384)
mesh.transfer_texture_to_color_per_vertex(sourcemesh=0, targetmesh=1)

Does anyone know if there's a filter that can do what I need?

1

There are 1 answers

0
Nick Fox-Gieg On

I encountered this bug also--if you update to current pymeshlab, the texture to vertex color filter works correctly.