Seamless way of using image filters with multi-resolution images

XMLWordPrintable

    • Type: Enhancement
    • Resolution: Unresolved
    • Priority: P4
    • tbd
    • Affects Version/s: 9
    • Component/s: client-libs
    • 2d

      See the discussion: http://mail.openjdk.java.net/pipermail/2d-dev/2016-March/006453.html

      The request is to use image filters with multi-resolution images to produce resulted multi-resolution images.

      For example it would be good if code below works without changes for multi-resolution images:
      ---------------
       124 static Image generateLightenedImage(final Image image, final int percent) {
       125 final GrayFilter filter = new GrayFilter(true, percent);
       126 final ImageProducer prod = new FilteredImageSource(image.getSource(), filter);
       127 return Toolkit.getDefaultToolkit().createImage(prod);
       128 }
      ---------------

      Note 1:
      MediaTracker is able to load resolution variants if they are provided from a set (like multiResoltuinImage.getResolutionVariants() method and not from method multiResoltuinImage.getResolutionVariant(width, height))

      Note2:
      The scheme multi-resolution image -> multi-resolution image producer + image filter -> multi-resolution image
      should also provide information about resolution-variant scaling to the filter.

      For example using CropImageFilter with given rectangle [x, y, width, height] in such case will result that from each resolution variant will be cut an constructed an image with the same size which is not what is expected.

            Assignee:
            Philip Race
            Reporter:
            Alexandr Scherbatiy
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated: