From: Eric F. <ef...@ha...> - 2007-07-11 20:46:37
|
Mike, The attached file masked_interior.py illustrates masking failure in a very simple case; you can see masking working in the plot on the left, where a contour intersects the masked region, but when that contour level is removed the masked region is getting filled in. The file contourf_demo.py is slightly modified from the one in the mpl examples directory, and shows a failure of masking in a more complicated setting. The masked region at the lower-left corner is correct, but the masked region in the middle of the plot is getting filled with gray instead of being left blank. In cntr.c there is a function, print_Csite, that may be helpful for debugging the simplest case, where the array size is not too large. Note that the code path for filled contours is quite different, and more complicated, than for line contours--and in fact, even neglecting branch cuts, the two code paths don't always yield the same contours. cntr.c is somewhat unusual among contour algorithms in that it works with rectangles without subdividing them into triangles. Eric |