documentation indexreference manualfunction index

im.Recolor

Function: im.Recolor (im, rmul=255, gmul=255, bmul=255, amul=255, force_alpha=False, **properties):

This adjusts the colors of the supplied image, im. It takes four arguments, rmul, gmul, bmul and amul, corresponding to the red, green, blue and alpha channels, with each being an integer between 0 and 255. Each channel has its value mapped so that 0 is 0, 255 is the argument supplied for that channel, and other values are linearly mapped in-between.

Example

init:
    image cyan green2 = im.Recolor("cyan.png", 255, 255, 0, 255)



documentation indexreference manualfunction index