VR-Forces Development_Version Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
basicTerrainIntersector.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2008 MAK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 /*******************************************************************************
6 ** $RCSfile: basicTerrainIntersector.h,v $ $Revision: 1.4 $ $State: Exp $
7 *******************************************************************************/
8 
11 
12 #ifndef basicTerrainIntersector_h
13 #define basicTerrainIntersector_h
14 
15 #include "gdb/terrainIntersector.h"
17 
19 
20 // An intersector for DtTerrainDatabase class.
21 // This intersector doesn't use any special intersection optimization, and
22 // does not allocate any additional memory. It is useful when reduced memory
23 // footprint is more important than intersection speed.
25 {
26 private:
27  // Not implemented.
29  // Not implemented.
31  // Not implemented.
33 
34 public:
36  const DtTerrainIntersectorDescriptor* descriptor);
37  virtual ~DtBasicTerrainIntersector();
38 
39  virtual bool init();
40  virtual bool reinitialize();
41 
42  // \return The total number of bytes of memory used by this intersector
43  // and any of its internal indexing into the terrain.
44  virtual unsigned int memoryUsage() const;
45 
46  virtual bool chordIntersect(const DtChord& chord,
49 
50  virtual bool allIntersectsAlongChord(const DtChord& chord,
53 
54  virtual bool sphereIntersect(const DtSphere& sphere, DtSphereIntersectionRecord& record,
56 
57  virtual int terrainIntersectorType() const;
58 
59  virtual bool load(FILE*) { return true; };
60  virtual bool save(FILE*) { return true; };
61 
62  // \return A descriptor for setting this intersector to the DtTerrainDatabase.
63  static DtBasicTerrainIntersectorDescriptor* createDescriptor();
64 };
65 
66 // Descriptor for the DtBasicTerrainIntersector class.
68 {
69 public:
73 
75 
76  virtual int terrainIntersectorType() const;
77 
78  virtual DtTerrainIntersectorDescriptor* clone() const;
79 
80  virtual void descriptorInformation(DtString& name, DtString& properties) const;
81 };
82 
83 #endif

Document ID: Generated on Tue Mar 8 22:13:38 EST 2016 from SVN revision 162938
Copyright © 2005-2015 VT MÄK. All Rights Reserved (www.mak.com)