Package pulse.util

Class ImageUtils


  • public class ImageUtils
    extends Object
    • Method Detail

      • loadIcon

        public static ImageIcon loadIcon​(String path,
                                         int iconSize)
      • dye

        public static BufferedImage dye​(BufferedImage image,
                                        Color color)
        Credit to Marco13 (https://stackoverflow.com/questions/21382966/colorize-a-picture-in-java)
      • dye

        public static ImageIcon dye​(ImageIcon icon,
                                    Color color)
        Credit to Werner Kvalem VesterĂ¥s (https://stackoverflow.com/questions/15053214/converting-an-imageicon-to-a-bufferedimage)
      • blend

        public static Color blend​(Color c1,
                                  Color c2,
                                  float ratio)
        Credit to bmauter (https://stackoverflow.com/questions/19398238/how-to-mix-two-int-colors-correctly)