I would be very happy to have this functionality. I think this would
also make the 3D plots in the examples that matplot provides look a
good deal nicer.
Let me know if you have any updates on this.
On Mon, Oct 3, 2011 at 21:18, Benjamin Root <ben.root@...1304...> wrote:
On Fri, Sep 30, 2011 at 11:33 AM, Holger Brandsmeier > <holger.brandsmeier@...3803...> wrote:
On Fri, Sep 30, 2011 at 17:06, Benjamin Root <ben.root@...1304...> wrote:
> What values for rstride and cstride are you using? By default,
> plot_surface() will sample every 10th point of the data array (for
> performance reasons). Also, color interpoltion can be turned on by
> shade to True.
I beleive I start to understand the underlying logic. If no color map
is set and shading and antialiazing is set, then indeed the surface
is nicely and smoothly displayed. When I provide a color map, then I
seem to be able to assign one color for the whole polygon. I also find
something like that in the code.
In my case I want the z-coordinate to determine the color. I want to
use a colormap like jet and no transparency. If I don't use the
colormap argument, then I get shading, however everything is blue with
shading depending on a lightsource.I don't really need a lightsource,
but I would like non-constant colors per polygon.
Yes, you have the logic correct (and probably better explained than I could
have done). This actually was an issue raised a couple of months ago in a
bit of a different context, but the solution wasn't entirely clear at that
point. However, looking at the code again (remember, I didn't write it
originally, and it had next to no comments), I think I see a fairly simple
solution. If I allow for the user to specify a light source of None, then I
could feed the data through a different function to "shade" the surface. I
will look into doing that, but it won't make it into the v1.1.0 release
(slated for tomorrow).
Holger Brandsmeier, SAM, ETH Zürich