Dynamic coloring of 3D Mesh Model.

This example demonstrates how to visualize 3D mesh models with customized coloring using the setVertexValues() method and PalettedFill.

To apply color to your 3D model using PalettedFill, you'll need to set values for each vertex.

First, every vertex of the model is iterated, and a weight for every sensor is calculated for that vertex.

This weight essentially describes how close to the vertex every sensor is.

Then, the sensor values are changed in real-time, and the vertex values are re-interpolated every time they do to update the colors.

This can be achieved by calling the setVertexValues() method, which accepts a callback function as an argument. This callback function should take a vertex as a parameter and return an array of colored values based on your criteria.

distance to each vertices