|
From: Robert C. <cim...@nt...> - 2009-05-25 08:04:58
|
Ondrej Certik wrote: > On Fri, May 22, 2009 at 3:37 PM, Ondrej Certik <on...@ce...> wrote: >> Thanks a lot John. I tried that and it does what I want. I just need >> to convert and probably average my 3 different values at the 3 >> vertices of the triangle and color the triangle with that color. When >> I get it working, I'll send you a picture. :) > > Ok, I made a progress, it seems it's working. Script and picture > attached. You can compare to the mayavi plot above, it's almost > identical now. It took my some time playing with different parameters > of mpl to get here and I think it looks quite good. Still one can see > the artefacts though as John predicted, due to mpl not interpolating > the triangles. Nice! Just to prod you a bit: If you want to get rid of the hard mayavi dependence of femhub for 3D plots too, you could hack a (perspective/whatever) projection of 3D surface to 2D, remove invisible faces (normal points backwards) and plot the rest by the painter's algorithm (far faces first). r. |