next up previous contents index
Next: flstb_boundary Up: Reference Previous: cml_draw   Contents   Index


$ \bigcirc$Name

cml_reconstruct Reconstruct a color image from cmorpho_lines of cmimage

$ \bigcirc$Command Synopsis

cml_reconstruct [-i] m_image image_out

-i : use the maxvalue of the cmorpho_lines (default minvalue)

m_image : input cmimage

image_out : reconstructed cfimage

$ \bigcirc$Function Summary

Cfimage cml_reconstruct (v_flag , m_image )

char *v_flag ;

Cmimage m_image ;

$ \bigcirc$Description

This module reconstructs a cfimage image_out using the cmorpho_lines contain in the input m_image. It works as the module ml_reconstruct, but if the later assumes gray level images only, cml_reconstruct can be applied on 3-planes color images.

Please read before the description of ml_reconstruct to get the reconstruction process for gray level images, as well as the description of cml_decompose to get the total order $ \preceq$ in IR3 used in the case of 3-planes color images. This extension to multi-valued images is exposed in [CF00].

The module cml_reconstruct allows to reconstruct an image in the HSI color model from the color topographic map given by the cmorpho_lines. Use the module cfchgchannel to convert this HSI image to a RGB one.

The following example computes in a bitmap image mapbaboon the color topographic map of the baboon image shown at the bottom of the color plate in [CF00] :

# Get the baboon image in the HSI model
cfchgchannels -c 1 ccimage baboon.hsi

# Quantify the HSI plane to reduce data
# without affecting too much visual quality
cfquant baboon.hsi qbaboon.hsi 17 4 8

# Compute the color topographic map by means
# of the cmorpho_lines. Does not retain small 
# level lines (length lower than 20 points),
# which are negligible.
cml_decompose -l 20 qbaboon.hsi baboon.cml

# Reconstruct a HSI image from the remaining
# level lines. Very similar to a grain filter.
cml_reconstruct baboon.cml rbaboon.hsi

# Get the image in RGB color model
cfchgchannels -c 1 -i rbaboon.hsi rbaboon.rgb

# Get the color topographic map geometry with
# the reconstructed image in background
cml_draw -a rbaboon.rgb baboon.cml mapbaboon

$ \bigcirc$Version 2.6

Last Modification date : Thu Apr 15 08:22:05 2004

$ \bigcirc$Author

Jacques Froment, Georges Koepfler

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