Built-in module imgfile

imgfile

The imgfile module allows python programs to access SGI imglib image files (also known as .rgb files). The module is far from complete, but is provided anyway since the functionality that there is is enough in some cases. Currently, colormap files are not supported.

The module defines the following variables and functions:


\begin{excdesc}{error}
This exception is raised on all errors, such as unsupported file type, etc.
\end{excdesc}


\begin{funcdesc}{getsizes}{file}
This function returns a tuple \code{(\var{x}, \...
...e RGB pixels and 1 byte greyscale pixels
are currently supported.
\end{funcdesc}


\begin{funcdesc}{read}{file}
This function reads and decodes the image on the sp...
...format is suitable to pass to \code{gl.lrectwrite},
for instance.
\end{funcdesc}


\begin{funcdesc}{readscaled}{file\, x\, y\, filter\, blur}
This function is iden...
...p the aspect ratio correct, so that is the users'
responsibility.
\end{funcdesc}


\begin{funcdesc}{ttob}{flag}
This function sets a global flag which defines whet...
...p to bottom(flag is one,
compatible with X). The default is zero.
\end{funcdesc}


\begin{funcdesc}{write}{file\, data\, x\, y\, z}
This function writes the RGB or...
...are used).
These are the formats returned by \code{gl.lrectread}.
\end{funcdesc}