public static @NotNull BufferedImage createImage(@Nullable GraphicsConfiguration gc, int width, int height, int type) {
    if (JreHiDpiUtil.isJreHiDPI(gc)) {
      return new HiDPIImage(gc, width, height, type);
    }
    else {
      //noinspection UndesirableClassUsage
      return new BufferedImage(width, height, type);
    }
  }
public static @NotNull BufferedImage createImage(@Nullable GraphicsConfiguration gc, int width, int height, int type)