Hi Luigi,
Please have a look here:
https://www.amazon.com/clouddrive/share/WkbJKTjVBIgLj9H7d2sNg9zep5kBjBJqsHd25njmPyi
I used a 3D Spherical Gradient. The Start and Radius of this Gradient are taken from the Sphere. The Radius is doubled to allow the Sphere’s surface to have the color at 50% on the gradient. (Cycle is off!)
This 50% allows to have the cube in one or more colors) and the Sphere in another color.
Yes, that is limited to spheres or perhaps a cylinder. Other setups are quite more difficult or impossible.
======
Another approach can be done with a copy of a model and create a Normal Move with the model. Then build the different colors as a model.
The Volume Mesher Voxel Range Threshold might help here, or even the Volume Dilate Erode on the elements to get the sizes changed. It depends to a certain degree what you like to have.
Example
https://www.amazon.com/clouddrive/share/xLobsRtYvNXFP7I0S1gIedeyLzA0gndjxOD9OUvTyHH
Let me know if there is anything else; I’m happy to look into it.
Cheers