Mercurial > hg > minc-tools
changeset 629:d4ffea599efb
*** empty log message ***
author | david <david> |
---|---|
date | Thu, 13 Oct 1994 12:36:56 +0000 |
parents | 49ce564889f7 |
children | e8d929fbf0cb |
files | volume_io/Documentation/volume_io.tex |
diffstat | 1 files changed, 50 insertions(+), 49 deletions(-) [+] |
line wrap: on
line diff
--- a/volume_io/Documentation/volume_io.tex +++ b/volume_io/Documentation/volume_io.tex @@ -112,10 +112,11 @@ \end{verbatim}} \newcommand{\definemacro}[2]{ +\begin{flushleft} \begin{tabular}{p{2cm}p{10cm}} \multicolumn{2}{l}{{\bf\tt #1}} \\ & #2 \\ -\end{tabular}} +\end{tabular}\end{flushleft}} Some macros useful for general programming include: @@ -218,9 +219,9 @@ argument lists can be scanned in command line order as follows: {\bf\begin{verbatim} - public void initialize_argument_processing( - int argc, - char *argv[] ) +public void initialize_argument_processing( + int argc, + char *argv[] ) \end{verbatim}} \desc{called once to let the argument processor know what the command line @@ -229,15 +230,15 @@ arguments.} {\bf\begin{verbatim} - public BOOLEAN get_int_argument( - int default_value, - int *value ) - public BOOLEAN get_real_argument( - Real default_value, - Real *value ) - public BOOLEAN get_string_argument( - char default_value[], - char *value[] ) +public BOOLEAN get_int_argument( + int default_value, + int *value ) +public BOOLEAN get_real_argument( + Real default_value, + Real *value ) +public BOOLEAN get_string_argument( + char default_value[], + char *value[] ) \end{verbatim}} \desc{checks if an argument exists and is of the desired type. If so, @@ -246,8 +247,8 @@ to the \name{value} and the current argument is not advanced.} {\bf\begin{verbatim} - public BOOLEAN get_prefix_argument( - char prefix[] ) +public BOOLEAN get_prefix_argument( + char prefix[] ) \end{verbatim}} \desc{checks if the next argument starts with the given prefix and if so, @@ -347,56 +348,56 @@ properties: {\bf\begin{verbatim} - public void rgb_to_hsl( - Real r, - Real g, - Real b, - Real *h, - Real *s, - Real *l ) - public void hsl_to_rgb( - Real h, - Real sl, - Real l, - Real *r, - Real *g, - Real *b ) - public void convert_colour_to_hsl( - Colour rgb, - Colour *hsl ) - public void convert_colour_to_rgb( - Colour hsl, - Colour *rgb ) +public void rgb_to_hsl( + Real r, + Real g, + Real b, + Real *h, + Real *s, + Real *l ) +public void hsl_to_rgb( + Real h, + Real sl, + Real l, + Real *r, + Real *g, + Real *b ) +public void convert_colour_to_hsl( + Colour rgb, + Colour *hsl ) +public void convert_colour_to_rgb( + Colour hsl, + Colour *rgb ) \end{verbatim}} \desc{Converts between red-green-blue and hue-saturation-light space.} {\bf\begin{verbatim} - public BOOLEAN equal_colours( - Colour col1, - Colour col2 ) +public BOOLEAN equal_colours( + Colour col1, + Colour col2 ) \end{verbatim}} \desc{returns \name{TRUE} if the two colours are equal.} {\bf\begin{verbatim} - public int get_colour_distance( - int r, - int g, - int b, - Colour c2 ) +public int get_colour_distance( + int r, + int g, + int b, + Colour c2 ) \end{verbatim}} \desc{finds the squared Euclidean distance between the first colour, specified by its components, and the second colour, \name{c2}.} {\bf\begin{verbatim} - public int find_closest_colour( - int r, - int g, - int b, - int n_colours, - Colour colours[] ) +public int find_closest_colour( + int r, + int g, + int b, + int n_colours, + Colour colours[] ) \end{verbatim}} \desc{Given the three components of a target colour, and a list of