module utils

The utils module exports some utility functions for drawing graphics.

Functions

frame_rect(surface, color, rect, thick = 1)
Draws a border with thickness thick just inside the specified rectangle.

blit_tinted(surface, image, pos, tint, src_rect = None)
Draws the image onto the surface at position pos with a colour tint applied. The components of the tint are added to the colour of each pixel, with the result clamped to 255. If the image has an alpha channel, it is preserved.

NOTE: This function requires Numeric.
---