This line: > avg_z = np.array([ps[:, 2].mean() for ps in polys]) means that coloring the surface is only possibly with the z coordinate. It would be very useful to allow an arbitrary function of ps here.