def MakePalette(tr, tg, tb):
    """
    Creates a palette to be applied on an image based on input colour.

    :param `tr`: the red intensity of the input colour;
    :param `tg`: the green intensity of the input colour;
    :param `tb`: the blue intensity of the input colour.
    """
    l = []
    for i in range(255):
        l.extend([tr * i // 255, tg * i // 255, tb * i // 255])
    return l
