VR-Forces 4.0.4 Class Documentation
include/terrainInterface/ellipsoidTerrainImplementation.h
Go to the documentation of this file.
00001 /*******************************************************************************
00002 ** Copyright (c) 2009 MAK Technologies, Inc.
00003 ** All rights reserved.
00004 *******************************************************************************/
00005 
00008 
00010 
00011 #ifndef ellipsoidTerrainImplementation_h
00012 #define ellipsoidTerrainImplementation_h
00013 
00014 #include "terrainInterface/terrainInterfaceDefines.h"
00015 #include "terrainInterface/terrainImplementation.h"
00016 #include "terrainInterface/terrainCapabilities.h"
00017 
00018 class DtCoordinateSystem;
00019 class DtVectorNetwork;
00020 namespace makArchives
00021 {
00022    class DtGenericTerrainRecord;
00023 }
00024 
00028 class DT_DLL_terrainInterface DtEllipsoidTerrainImplementation : 
00029    public DtTerrainImplementation
00030 {
00031 public:
00032    DtEllipsoidTerrainImplementation(DtConsoleCommandManager* cmdMgr);
00033    virtual ~DtEllipsoidTerrainImplementation();
00034 
00035    static DtTerrainImplementation* create(DtConsoleCommandManager* cmdMgr);
00036 
00037    virtual bool loadTerrain(const makArchives::DtGenericTerrainRecord& record,
00038       const TerrainSettings& settings = TerrainSettings());
00039 
00040    virtual const Coordinate_System* coordinateSystem() const;
00041 
00044    virtual bool chordIntersect(const DtChord& chord,
00045       DtChordIntersectionRecord& record,
00046       DtIntersectionRecord::DtIntersectionType irtFlag = 
00047       DtIntersectionRecord::INT_ALL_DATA,
00048       bool* dataAvailable = 0, bool overrideBlockingAssert = false) const;
00049 
00052    virtual bool allIntersectsAlongChord(const DtChord& chord,
00053       DtChordIntersectRecordList& intList,
00054       DtIntersectionRecord::DtIntersectionType irtFlag = 
00055       DtIntersectionRecord::INT_ALL_DATA,
00056       bool* dataAvailable = 0, bool overrideBlockingAssert = false) const;
00057 
00060    virtual bool sphereIntersect(const DtSphere& sphere, DtSphereIntersectionRecord& record,
00061       DtIntersectionRecord::DtIntersectionType irtFlag = 
00062       DtIntersectionRecord::INT_ALL_DATA,
00063       bool* dataAvailable = 0, bool overrideBlockingAssert = false) const;
00064 
00065    virtual const DtVectorNetwork* vectorNetwork() const;
00066 
00071    virtual bool intersectVectorNetwork(const DtChord& chord,
00072       DtVectorNetworkRecord* vectorRecord, 
00073       DtVectorNetworkIntersectionRecord* vectorIntersectionRecord) const;
00074 
00075    virtual const DtTerrainCapabilities* terrainCapabilities() const;
00076 
00077    virtual void processTrianglesInArea(DtTriangleCallbackFcn func, DtTriangleCallbackFinalizeFcn finalize, const DtTerrainProcessPolygonsBox& box, void* usr);
00078 
00079 protected:
00080    void fillHitRecord(DtChordIntersectionRecord& rec, const DtChord& chord, const DtPoint& chordNormal,
00081       double intersectTime, DtIntersectionRecord::DtIntersectionType irtFlag) const;
00082 
00083    bool chordEllipsoidIntersect(const DtChord& chord, DtChordIntersectionRecord& hit1, 
00084       DtChordIntersectionRecord& hit2, DtIntersectionRecord::DtIntersectionType irtFlag) const;
00085 
00086 protected:
00087    Coordinate_System* myCoordinateSystem;
00088    DtVectorNetwork * myVectorNetwork;
00089    DtTerrainCapabilities myCapabilities;
00090 };
00091 
00092 #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)