nmwsharp / polyscope

A C++ & Python viewer for 3D data like meshes and point clouds
https://polyscope.run
MIT License
1.76k stars 190 forks source link

Coloring individual elements of a quantity/mesh #270

Open avaxman opened 5 months ago

avaxman commented 5 months ago

I would like to be able to either color only specific elements of a quantity/mesh, or alternatively, to be able to override the colors, but be able to supply individual colors per element. Specifically, I would like to reproduce the behaviour in Tutorial 201 in Directional:

https://avaxman.github.io/Directional/tutorial/#201-principal-matching

Where only several vectors are colored.

byfron commented 4 months ago

Related to this. I'd also find very convenient to have colored point-clouds (as in different colors per point).

byfron commented 4 months ago

Actually nevermind. I was looking through the code to see if I could add point-cloud coloring myself and I found that the feature is already there. "point_cloud.add_color_quantity" admits an array of colors as input