package org.iri_research.renkan.utils;

import java.awt.Color;
import java.util.Random;

public class ColorGenerator {

    public static Color randomColor() {

        Random rand = new Random();

        float r = rand.nextFloat() * 0.5f + 0.5f;
        float g = rand.nextFloat() * 0.5f + 0.5f;
        float b = rand.nextFloat() * 0.5f + 0.5f;

        return new Color(r, g, b);
    }

    public static String randomColorHex() {
        Color resColor = ColorGenerator.randomColor();
        return Integer.toHexString(resColor.getRGB());
    }

}
