package imagelib
Install
Dune Dependency
Authors
Maintainers
Sources
sha256=8af15b79cb0ad8809734531179a85f2f70d434f5f2b4ca9653bc37207b27d8f3
sha512=edce1f21ccc9fafa9242cf602bbd13fafd768fd9d614420cb462df2389a51063df6041bd4d1f84a46a5937a5ecf108c9925794d0ce453f1d5f8482ae6f3bfbb0
doc/imagelib.unix/ImageLib_unix/index.html
Module ImageLib_unix
Source
This module provides an easy-to-use interface for imagelib. In most cases, you'd want to use these functions rather than those in imagelib.
writefile fn img
writes the image img
to the file fn
. This function guesses the desired format using the extension. Raises Corrupted_image
if it encounters a problem. If the file extension is unknown to imagelib, this will first write out a png and then convert that to the desired format using the "convert" command from imagemagick.
size fn
reads the image from the file fn
. It returns the pixel dimensions of the image as the tuple width, heigth
.
openfile fn
reads the image from the file fn
. This function guesses the file format using the extension. Raises Corrupted_image
if it encounters a problem. If the file extension is unknown to imagelib, this will attempt to convert to png using imagemagick and then read in the png file.