File: //opt/alt/python27/lib64/python2.7/site-packages/matplotlib/tri/tricontour.pyc
�
0&XLc @ s d d l m Z d d l m Z d d l j Z d d l Z d e f d � � YZ d � Z e j
e _ d � Z e j
e _ d S( i����( t
ContourSet( t
TriangulationNt
TriContourSetc B s8 e Z d Z d � Z d � Z d � Z d � Z d Z RS( s�
Create and store a set of contour lines or filled regions for
a triangular grid.
User-callable method: clabel
Useful attributes:
ax:
the axes object in which the contours are drawn
collections:
a silent_list of LineCollections or PolyCollections
levels:
contour levels
layers:
same as levels for line contours; half-way between
levels for filled contours. See _process_colors method.
c O s t j | | | | � d S( sR
Draw triangular grid contour lines or filled regions,
depending on whether keyword arg 'filled' is False
(default) or True.
The first argument of the initializer must be an axes
object. The remaining arguments and keyword arguments
are described in TriContourSet.tricontour_doc.
N( R t __init__( t selft axt argst kwargs( ( sL /opt/alt/python27/lib64/python2.7/site-packages/matplotlib/tri/tricontour.pyR s
c
O s� t | d t � rE | d j } | j d k r� | d j | _ q� n� | j | | � \ } } t j | j � | � } | j j
� } | j j � } | j j
� } | j j � } | j
j | | f | | f g � | j
j � | | _ d S( s*
Process args and kwargs.
i N( t
isinstanceR t cppContourGeneratort levelst Nonet
_contour_argst _trit TriContourGeneratort get_cpp_triangulationt xt mint maxt yR t update_datalimt autoscale_view(
R R R t Ct trit zt x0t x1t y0t y1( ( sL /opt/alt/python27/lib64/python2.7/site-packages/matplotlib/tri/tricontour.pyt
_process_args% s
"
c
C s� g } | j r� | j � \ } } g } x� t | | � D]G \ } } | j j | | � \ } } | j | g � | j | g � q7 Wn9 d } x0 | j D]% } | j j | � } | j | � q� W| | f S( sV
Create and return allsegs and allkinds by calling underlying C code.
N( t filledt _get_lowers_and_upperst zipR t create_filled_contourt appendR R
t create_contour(
R t allsegst lowerst upperst allkindst lowert uppert segst kindst level( ( sL /opt/alt/python27/lib64/python2.7/site-packages/matplotlib/tri/tricontour.pyt _get_allsegs_and_allkinds9 s c C s� | j r d } n d } t j | | � \ } } } t j | d � } | j | j j k rj t d � � n | j � | _ | j
� | _ | j r� | j d k r� t d | � � n | j
| | d � | | f S( Nt contourft contouri s<