Ńň 8”tJc@sJddklZddklZddklZdefd„ƒYZdS(i˙˙˙˙(t frombuffer(t RendererAgg(tprocess_figure_for_rasterizingtMixedModeRenderercBsDeZdZddd„ZdiƒZd„Zd„Zd„Z RS(s& A helper class to implement a renderer that switches between vector and raster drawing. An example may be a PDF writer, where most things are drawn with PDF vector commands, but some very complex objects, such as quad meshes, are rasterised and then output as images. cCsy|djo t}n||_||_||_||_||_d|_d|_||_ ||_ |i |ƒdS(s figure: The figure instance. width: The width of the canvas in logical units height: The height of the canvas in logical units dpi: The dpi of the canvas vector_renderer: An instance of a subclass of RendererBase that will be used for the vector drawing. raster_renderer_class: The renderer class to use for the raster drawing. If not provided, this will use the Agg backend (which is currently the only viable option anyway.) iN( tNoneRt_raster_renderer_classt_widtht_heighttdpit_vector_renderert_raster_renderert _rasterizingtfiguret_bbox_inches_restoret_set_current_renderer(tselfR twidththeightRtvector_renderertraster_renderer_classtbbox_inches_restore((sG/usr/lib64/python2.6/site-packages/matplotlib/backends/backend_mixed.pyt__init__ s           sI close_group draw_image draw_markers draw_path draw_path_collection draw_quad_mesh draw_tex draw_text finalize flipy get_canvas_width_height get_image_magnification get_texmanager get_text_width_height_descent new_gc open_group option_image_nocomposite points_to_pixels strip_math cCsf||_x>|iD]3}t||ƒot||t||ƒƒqqW|i|_|i|_dS(N(t _renderert_methodsthasattrtsetattrtgetattrtstart_rasterizingtstop_rasterizing(Rtrenderertmethod((sG/usr/lib64/python2.6/site-packages/matplotlib/backends/backend_mixed.pyR>s  ! cCsŤ|ii|iƒ|io(t|i|iddƒ}||_n|idjoC|i|i|i|i|i|iƒ|_ |i |i ƒn|id7_dS(s Enter "raster" mode. All subsequent drawing commands (until stop_rasterizing is called) will be drawn with the raster backend. If start_rasterizing is called multiple times before stop_rasterizing is called, this method has no effect. tmodetpngiiN( R tset_dpiRR RR RRRR R(Rtr((sG/usr/lib64/python2.6/site-packages/matplotlib/backends/backend_mixed.pyRHs      )c Csh|id8_|idjo|i|iƒ|i|i|i|i}}|iiƒ\}}|\}}}}|djoˆ|djo{t|||t ƒ} t | _ | i ƒ|i itt|ƒ|idƒtt|ƒ|||idƒ| dƒnd|_t |_n|iidƒ|io(t|i|iddƒ} | |_ndS(s9 Exit "raster" mode. All of the drawing that was done since the last start_rasterizing command will be copied to the vector backend by calling draw_image. If stop_rasterizing is called multiple times before start_rasterizing is called, this method has no effect. iigR@iHRtpdfN(R RR RRRR ttostring_rgba_minimizedRtTruetFalset is_grayscalet flipud_outRt draw_imagetinttfloatRR R!R R( RRRtbuffertboundstltbtwthtimageR"((sG/usr/lib64/python2.6/site-packages/matplotlib/backends/backend_mixed.pyRds* !  #"      N( t__name__t __module__t__doc__RRtsplitRRRR(((sG/usr/lib64/python2.6/site-packages/matplotlib/backends/backend_mixed.pyRs .  N(tmatplotlib._imageRtmatplotlib.backends.backend_aggRtmatplotlib.tight_bboxRtobjectR(((sG/usr/lib64/python2.6/site-packages/matplotlib/backends/backend_mixed.pyts