TopologyPreservingSimplifier.h

00001 /**********************************************************************
00002  * $Id: TopologyPreservingSimplifier.h 1820 2006-09-06 16:54:23Z mloskot $
00003  *
00004  * GEOS - Geometry Engine Open Source
00005  * http://geos.refractions.net
00006  *
00007  * Copyright (C) 2006 Refractions Research Inc.
00008  *
00009  * This is free software; you can redistribute and/or modify it under
00010  * the terms of the GNU Lesser General Licence as published
00011  * by the Free Software Foundation. 
00012  * See the COPYING file for more information.
00013  *
00014  **********************************************************************
00015  *
00016  * Last port: simplify/TopologyPreservingSimplifier.java rev. 1.4 (JTS-1.7)
00017  *
00018  **********************************************************************
00019  *
00020  * NOTES:
00021  *
00022  **********************************************************************/
00023 
00024 #ifndef _GEOS_SIMPLIFY_TOPOLOGYPRESERVINGSIMPLIFIER_H_
00025 #define _GEOS_SIMPLIFY_TOPOLOGYPRESERVINGSIMPLIFIER_H_ 
00026 
00027 #include <memory> // for auto_ptr
00028 #include <map> 
00029 
00030 // Forward declarations
00031 namespace geos {
00032         namespace simplify {
00033                 class TaggedLinesSimplifier;
00034         }
00035         namespace geom {
00036                 class Geometry;
00037         }
00038 }
00039 
00040 namespace geos {
00041 namespace simplify { // geos::simplify
00042 
00061 class TopologyPreservingSimplifier
00062 {
00063 
00064 public:
00065 
00066         static std::auto_ptr<geom::Geometry> simplify(
00067                         const geom::Geometry* geom,
00068                         double tolerance);
00069 
00070         TopologyPreservingSimplifier(const geom::Geometry* geom);
00071 
00082         void setDistanceTolerance(double tolerance);
00083 
00084         std::auto_ptr<geom::Geometry> getResultGeometry();
00085 
00086 private:
00087 
00088         const geom::Geometry* inputGeom;
00089 
00090         std::auto_ptr<TaggedLinesSimplifier> lineSimplifier;
00091 
00092 };
00093 
00094 
00095 
00096 } // namespace geos::simplify
00097 } // namespace geos
00098 
00099 #endif // _GEOS_SIMPLIFY_TOPOLOGYPRESERVINGSIMPLIFIER_H_ 
00100 
00101 /**********************************************************************
00102  * $Log$
00103  * Revision 1.3  2006/04/13 16:04:10  strk
00104  * Made TopologyPreservingSimplifier implementation successfully build
00105  *
00106  * Revision 1.2  2006/04/13 14:25:17  strk
00107  * TopologyPreservingSimplifier initial port
00108  *
00109  **********************************************************************/

Generated on Fri Mar 27 04:53:03 2009 for GEOS by  doxygen 1.5.4