Abstract : In this article we present a framework for modeling a building with a single Digital Elevation Model (DEM). The model is constructed in two stages. A first stage segments the DEM into planar surface patches to describe the building. Then, a polygonalisation stage generates the final polygonal model of the building by using constraints. We use robust estimation methods at different stages of our framework to develop an efficient and insensitive to noise system of modeling. The system that we propose is fully automatic and does not use any a priori information about the shape of the buildings. We present results with simple buildings and with a large area of a real city.