Class JDKWorkarounds

Object
JDKWorkarounds

public final class JDKWorkarounds extends Object
  • Method Details

    • setRect

      public static void setRect(WritableRaster dstRaster, Raster srcRaster)
    • setRect

      public static void setRect(WritableRaster dstRaster, Raster srcRaster, int dx, int dy)
    • areCompatibleDataModels

      public static boolean areCompatibleDataModels(SampleModel sm, ColorModel cm)
      Workaround for JDK 1.3 bug 4326636 (bpb 30 March 2000).

      Check whether the given SampleModel and ColorModel are compatible.

      This is required because in JDK 1.3 the ComponentColorModel implementation of isCompatibleSampleModel() only checks whether the SampleModel is a ComponentSampleModel with the same transferType as the ColorModel. No check of the number of components or bit depth is effected.

      Throws:
      IllegalArgumentException - if either parameter is null.