lib/matplotlib/backends/backend_ps.py
def draw_image(self, gc, x, y, im):
        """
        Draw the Image instance into the current axes; x is the
        distance in pixels from the left hand side of the canvas and y
        is the distance from bottom

        bbox is a matplotlib.transforms.BBox instance for clipping, or
        None
        """

        im.flipud_out()

        if im.is_grayscale:
            h, w, bits = self._gray(im)
            imagecmd = "image"
        else:
            h, w, bits = self._rgb(im)
            imagecmd = "false 3 colorimage"
        hexlines = '\n'.join(self._hex_lines(bits))

        xscale, yscale = (
            w/self.image_magnification, h/self.image_magnification)

        figh = self.height*72
        #print 'values', origin, flipud, figh, h, y

        bbox = gc.get_clip_rectangle()
        clippath, clippath_trans = gc.get_clip_path()

        clip = []
        if bbox is not None:
            clipx,clipy,clipw,cliph = bbox.bounds
            clip.append('%s clipbox' % _nums_to_str(clipw, cliph, clipx, clipy))
        if clippath is not None:
            id = self._get_clip_path(clippath, clippath_trans)
            clip.append('%s' % id)
        clip = '\n'.join(clip)

        #y = figh-(y+h)
        ps = """gsave
%(clip)s
%(x)s %(y)s translate
%(xscale)s %(yscale)s scale
/DataString %(w)s string def
%(w)s %(h)s 8 [ %(w)s 0 0 -%(h)s 0 %(h)s ]
{
currentfile DataString readhexstring pop
} bind %(imagecmd)s
%(hexlines)s
grestore
""" % locals()
        self._pswriter.write(ps)

        # unflip
        im.flipud_out()

        Draw the Image instance into the current axes; x is the
        distance in pixels from the left hand side of the canvas and y
        is the distance from bottom

        bbox is a matplotlib.transforms.BBox instance for clipping, or
        None
        
Draw the Image instance into the current axes; x is the
distance in pixels from the left hand side of the canvas and y
is the distance from bottom

bbox is a matplotlib.transforms.BBox instance for clipping, or
None
Draw the Image instance into the current axes ; x is the distance in pixels from the left hand side of the canvas and y is the distance from bottom bbox is a matplotlib . transforms . BBox instance for clipping or None
def draw_image(self, gc, x, y, im):
        im.flipud_out()
        if im.is_grayscale:
            h, w, bits = self._gray(im)
            imagecmd = "image"
        else:
            h, w, bits = self._rgb(im)
            imagecmd = "false 3 colorimage"
        hexlines = '\n'.join(self._hex_lines(bits))
        xscale, yscale = (
            w/self.image_magnification, h/self.image_magnification)
        figh = self.height*72
        bbox = gc.get_clip_rectangle()
        clippath, clippath_trans = gc.get_clip_path()
        clip = []
        if bbox is not None:
            clipx,clipy,clipw,cliph = bbox.bounds
            clip.append('%s clipbox' % _nums_to_str(clipw, cliph, clipx, clipy))
        if clippath is not None:
            id = self._get_clip_path(clippath, clippath_trans)
            clip.append('%s' % id)
        clip = '\n'.join(clip)
        ps = """gsave
%(clip)s
%(x)s %(y)s translate
%(xscale)s %(yscale)s scale
/DataString %(w)s string def
%(w)s %(h)s 8 [ %(w)s 0 0 -%(h)s 0 %(h)s ]
{
currentfile DataString readhexstring pop
} bind %(imagecmd)s
%(hexlines)s
grestore
""" % locals()
        self._pswriter.write(ps)
        im.flipud_out()
def draw_image ( self , gc , x , y , im ) : im . flipud_out ( ) if im . is_grayscale : h , w , bits = self . _gray ( im ) imagecmd = "image" else : h , w , bits = self . _rgb ( im ) imagecmd = "false 3 colorimage" hexlines = '\n' . join ( self . _hex_lines ( bits ) ) xscale , yscale = ( w / self . image_magnification , h / self . image_magnification ) figh = self . height * 72 bbox = gc . get_clip_rectangle ( ) clippath , clippath_trans = gc . get_clip_path ( ) clip = [ ] if bbox is not None : clipx , clipy , clipw , cliph = bbox . bounds clip . append ( '%s clipbox' % _nums_to_str ( clipw , cliph , clipx , clipy ) ) if clippath is not None : id = self . _get_clip_path ( clippath , clippath_trans ) clip . append ( '%s' % id ) clip = '\n' . join ( clip ) ps = """gsave
%(clip)s
%(x)s %(y)s translate
%(xscale)s %(yscale)s scale
/DataString %(w)s string def
%(w)s %(h)s 8 [ %(w)s 0 0 -%(h)s 0 %(h)s ]
{
currentfile DataString readhexstring pop
} bind %(imagecmd)s
%(hexlines)s
grestore
""" % locals ( ) self . _pswriter . write ( ps ) im . flipud_out ( )
Draw the Image instance into the current axes; x is the
distance in pixels from the left hand side of the canvas and y
is the distance from bottom
Draw the Image instance into the current axes ; x is the distance in pixels from the left hand side of the canvas and y is the distance from bottom
"""
        Draw the Image instance into the current axes; x is the
        distance in pixels from the left hand side of the canvas and y
        is the distance from bottom

        bbox is a matplotlib.transforms.BBox instance for clipping, or
        None
        """ #print 'values', origin, flipud, figh, h, y #y = figh-(y+h) # unflip
self
gc
x
y
im