Module img

Source
Available on crate feature image only.
Expand description

Image Utilities

Functionsยง

apply_opacity
Applies opacity to an image.
convert_bgr_to_bgra
Converts a BGR image to BGRA format.
convert_bgr_to_rgb
Converts a BGR image to RGB format.
convert_bgra_to_bgr
Converts a BGRA image to BGR format.
convert_bgra_to_rgba
Converts a BGRA image to RGBA format.
convert_rgb_to_bgr
Converts an RGB image to BGR format.
convert_rgb_to_rgba
Converts an RGB image to RGBA format.
convert_rgba_to_bgra
Converts an RGBA image to BGRA format.
decode_img
Decodes an image from the specified file path and returns its data.
draw_on_canvas
Draws an image on a canvas with specified offsets.
draw_on_img_with_opacity
Draws an image on another image with specified opacity.
encode_img
Encodes an image to the specified format and writes it to a file.
flip_image
Flips an image vertically.
load_jpgmozjpeg
load_png
Loads a PNG image from the given reader and returns its data.
reverse_alpha_values
Reverses the alpha values of an image.