I am using the “Concavity” component from Bision plug-in to color a mesh. The color gradient seems to be a default one, with no option to change it…
Does anyone know if and how this gradient can be changed? Would it be possible to do so after having the output colors? Like remapping the values to a gradient that I want? Or maybe the logic to analyze mesh concavity and convexity is not so complex and can be done without the plug-in?
I think if the option is to create a method to measure concavity from scratch instead of remapping the colors, this can be the starting point. Specially the last reply by @DanielPiker
I don’t know what is meant with “concavity” in a mesh. If you can explain what it is and how to calculate it, it would be probably much easier to calculate it with a custom script and apply whatever gradient you want once you have the values.
Edit: you have the values! Just use “remap numbers” and use a color gradient + “deconstruct mesh” and “construct mesh” with colors…
I think this does the same thing. (well, not exactly the same thing, as I’m not sure how the values are being calculated in that plugin), but the sorting/coloring results are the same. If the minimum principal curvature value of the individual “face surface”, is positive it’s a concave surface, if it’s negative its convex.
Here’s one way to get a rough measure of how convex/concave a mesh is-
get the vector from each vertex to the average of its neighbours (an approximate mean curvature normal)
then project it onto the regular normal.
If you need something more accurate you could perhaps use the cotan weighted Laplacian instead of the simple average. concavity.gh (76.2 KB)