next up previous contents index
Next: frank Up: Reference Previous: fnoise   Contents   Index

fquant

$ \bigcirc$Name


fquant Uniform quantization of a fimage




$ \bigcirc$Command Synopsis


fquant [-l] [-m minimum] [-M maximum] A Q M .



-l : Set left value of the interval instead of middle value

-m minimum : force the minimum (don't compute it)

-M maximum : force the maximum (don't compute it)

A : Input fimage

Q : Output quantized fimage

M : Number of quantized levels

. (screen output) : Width step of the uniform quantization used




$ \bigcirc$Function Summary


float fquant (A , Q , M , left , min , max )

Fimage A , Q ;

int M ;

char *left ;

float *min , *max ;




$ \bigcirc$Description


This module uniformly quantifies a fimage A on M gray levels, using the following scheme :

Let be a the minimum value of A and b the maximum value. Then we set

$\displaystyle \left.\vphantom{ \begin{array}{l}
\delta = \frac{b-a}{M} \\
\; ...
...
Q(x,y) = a + r\delta \mbox{ (with option {\tt -l})}\\
\end{array} }\right.$$\displaystyle \begin{array}{l}
\delta = \frac{b-a}{M} \\
\; \mbox{and} \\
\...
...ox{or} \\
Q(x,y) = a + r\delta \mbox{ (with option {\tt -l})}\\
\end{array}$

The last inequality being not strict when r = M - 1.

The module returns the value of $ \delta$.




$ \bigcirc$See Also


cfquant.


$ \bigcirc$Version 1.2


Last Modification date : Thu Nov 29 20:23:56 2001


$ \bigcirc$Author


Jacques Froment






next up previous contents index
Next: frank Up: Reference Previous: fnoise   Contents   Index
mw 2004-05-05