Morphological Modeling of Terrains and Volume Data