Implementations of various common functions and functions for image processing.