VR-Forces 4.0.4 Class Documentation
include/shape/shapeInit.h
Go to the documentation of this file.
00001 /*******************************************************************************
00002 ** Copyright (c) 2004 MAK Technologies, Inc.
00003 ** All rights reserved.
00004 *******************************************************************************/
00005 /*******************************************************************************
00006 ** $RCSfile: shapeInit.h,v $ $Revision: 1.17 $ $State: Exp $
00007 *******************************************************************************/
00008 #ifndef shapeInit_H_
00009 #define shapeInit_H_
00010 
00011 // \file shapeInit.h
00012 // \brief Contains the DtShapeInitializer class declaration.
00013 
00014 #include "shape/shapeDefines.h"
00015 #include <vlutil/vlFilename.h>
00016 #include "gdb/terrainFileInitializer.h"
00017 #include "shape/shapeEntry.h"
00018 #include <vlutil/vlConfig.h>
00019 #include <list>
00020 
00021 
00022 // The DtShapeInitializer contains the data necessary to initialize the 
00023 // DtShapeReader shape file import class.  
00024 class DT_DLL_shape DtShapeInitializer : public DtTerrainFileInitializer
00025 {
00026 
00027 public:
00028    enum DtShapefileTerrainType 
00029    {
00030       SHAPETERRAIN_NOTYPE,
00031       SHAPETERRAIN_ZPOLY,
00032       SHAPETERRAIN_POLY,
00033       SHAPETERRAIN_POST
00034    };
00035 
00036    typedef std::list<DtShapeEntry> DtShapeFileContainer;
00037    typedef DtShapeFileContainer::iterator DtShapeFileIter;
00038    typedef DtShapeFileContainer::const_iterator DtShapeFileConstIter;
00039 
00040    // default constructor.
00041    DtShapeInitializer();
00042 
00043    // destructor
00044    virtual ~DtShapeInitializer();
00045 
00046    DtShapeInitializer(const DtShapeInitializer& original);
00047    DtShapeInitializer& operator=(const DtShapeInitializer& original);
00048 
00049    virtual DtString type() const;
00050 
00051    virtual const DtShapeFileContainer& terrainFileContainer() const;
00052    virtual DtShapeFileContainer& terrainFileContainer();
00053 
00054    // add a filename to the load list
00055    virtual void addTerrainFile(const DtFilename& filename, const DtString& dataString, float factorToMtrs);
00056    virtual void addTerrainFile(const DtFilename& filename, float elevationDelta, float factorToMtrs);
00057    virtual void addTerrainFile(const DtFilename& filename, float factorToMtrs);
00058 
00059    virtual void clearList();
00060 
00061    virtual void setIsSeaRectangleAdded(bool added);
00062    virtual bool isSeaRectangleAdded() const;
00063 
00064    virtual void setIsGroundRectangleAdded(bool added);
00065    virtual bool isGroundRectangleAdded() const;
00066 
00067    virtual void setTerrainType(const DtString &typ);
00068    virtual DtShapefileTerrainType terrainType() const;
00069    virtual DtString terrainTypeString() const;
00070 
00071    virtual void setMinimumDistance(double dist);
00072    virtual double minimumDistance() const;
00073 
00074    virtual void setThresholdForSeaLevel(double threshold);
00075    virtual double thresholdForSeaLevel() const;
00076 
00077    // returns the origin latitude;
00078    virtual const double& originLatitude() const;
00079    virtual void setOriginLatitude(const double& d);
00080 
00081    // returns the origin longitude
00082    virtual const double& originLongitude() const;
00083    virtual void setOriginLongitude(const double& d);
00084 
00085    // returns the low-color height
00086    virtual bool isOriginSpecified() const;
00087    virtual void setIsOriginSpecified(bool b);
00088 
00089 protected:
00090 
00091    DtShapefileTerrainType  myTerrainType;
00092    bool                    myIsSeaRectangleAdded;
00093    bool                    myIsGroundRectangleAdded;
00094    DtShapeFileContainer    myTerrainFileContainer;
00095 
00096    double                  myOriginLatitude;
00097    double                  myOriginLongitude;
00098    double                  myMinimumDistance;
00099    double                  myThresholdForSeaLevel;
00100 
00101    bool                    myIsOriginSpecified;
00102 };
00103 
00104 #endif

Document ID: Generated on Fri Jun 29 16:33:32 EDT 2012 from SVN revision 116588
Copyright © 2005-2012 VT MÄK Inc. All Rights Reserved (www.mak.com)