Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4110027

drawImage() doesn't honor clipping rect (JDK 1.1 only, Solaris only)

XMLWordPrintable

    • sparc
    • solaris_2.5.1

      Using drawImage(Image, int, int, int, int, ImageObserver) to render an image will ignore the current clipping rect if the image has transparency and it is drawn at a scaled size.

      A test program is attached that illustrates this behaviour.

      The workaround appears to be to compute the intersection of the image and the clipping rect and use drawImage(Image, int, int, int, int, int, int, int, int, ImageObserver) to render only that region of the image that is within the clipping rect... however, this is non-trivial and a royal pain to implement each time you need to render.

            lbunnisunw Lara Bunni (Inactive)
            duke J. Duke
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: