I'm trying to create aesthetically pleasing 3D plots in Python with specular shading, and thus far have tried using both Matplotlib with 3D axes and surface plots from Mayavi, e.g., from the Mayavi surf examples web page:
The results look good, and in Mayavi there does seem to be reasonable control of the lighting, although I can't seem to achieve a "shiny" appearance.
In Matlab, this can be achieved by using 'Phong' lighting:
Therefore, my question is: how can I achieve this Phong-style shiny shading in a Python-based 3D plot?
Yes, you can do this in Mayavi. In the Mayavi window, click on the little Mayavi icon in the upper left-hand corner to show the advanced menu. Click on the surface in the scene that corresponds to your surface, then click on the "Actor" tab in the menu on the right, scroll down to the box labeled "Property", and click on "More options". You can set the shading to phong shading in the "Interpolation" box.
As @ben mentioned, you can use Mayavi and then interactively change the lighting. A good idea is to click in the record script button, then you can use those lines of code in your scripts (That's how I did for the Mayavi part here).
Another option is to use Matplotlib. Based on the shading example, I managed to generate a surface with lighting.
See the code below.
This gives as results: