Rev 1676 |
Blame |
Compare with Previous |
Last modification |
View Log
| RSS feed
%----------------------------------------------------------------------------
\chapter{The Snapshot Library}
%----------------------------------------------------------------------------
The library allow applications to save up to 16 screen snapshot to file. Before
the grabbing is necessary to allocate the memory for a snapshot slot and files
can be created only at the end of execution when the system return in real mode.
\vspace{7mm}
\begin{intest}
SNAPSHOT\_GETSLOT \index{snapshot\_getslot()}
\end{intest}
\begin{description}
\item [\textbf{void {*}snapshot\_getslot(int nbuff, int wx, int wy, int byesperpixel); }]
\item [\textbf{Description:}] This function allocate the memory for a snapshot of given
dimensions. The \texttt{nbuff} parameter indicate which slot must be allocated.
\texttt{wx} and \texttt{wy} are width and height of the screen resolution while
\texttt{bytesperpixel} is the depth of the screen.
\end{description}
\begin{intest}
SNAPSHOT\_FREESLOT\index{snapshot\_freeslot()}
\end{intest}
\begin{description}
\item [\textbf{void snapshot\_freeslot(int nbuff) }]
\item [\textbf{Description:}] This function free the memory reserved for the slot
indicated by the \texttt{nbuff} parameter.
\end{description}
\begin{intest}
SNAPSHOT\_GRAB\index{snapshot\_grab()}
\end{intest}
\begin{description}
\item [\textbf{void snapshot\_grab(int nbuff) }]
\item [\textbf{Description:}] This function get a snap of the video memory and copy it
inside the slot specified by the \texttt{nbuff} parameter.
\end{description}
\begin{intest}
SNAPSHOT\_SAVEPGM\index{snapshot\_savepgm()}
\end{intest}
\begin{description}
\item [\textbf{int snapshot\_savepgm(int nbuff, char {*}fname) }]
\item [\textbf{Description:}] This function save the screen snapshot saved inside the
nbuff slot to a PGM greyscale file. The filename passed to the function using
the fname parameter.
\end{description}
\begin{intest}
SNAPSHOT\_SAVEPPM\index{snapshot\_saveppm()}
\end{intest}
\begin{description}
\item [\textbf{int snapshot\_saveppm(int nbuff, char {*}fname) }]
\item [\textbf{Description:}] This function save the screen snapshot saved inside the
nbuff slot to a PPM color file. The filename passed to the function using the
fname parameter.
\end{description}