/[escript]/branches/refine/buckley/src/OctTree.h
ViewVC logotype

Contents of /branches/refine/buckley/src/OctTree.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 3680 - (show annotations)
Fri Nov 18 04:48:53 2011 UTC (7 years, 10 months ago) by jfenwick
File MIME type: text/plain
File size: 901 byte(s)
It has memory errors during a getX.

1
2
3 #include "OctCell.h"
4
5 namespace buckley
6 {
7
8
9
10
11 class OctTree
12 {
13 public:
14 OctTree(double x, double y, double z); // specifies the dimensions of bounding box
15 ~OctTree();
16 void allSplit(unsigned int d);
17 void allCollapse(unsigned int d);
18 void collapsePoint(double x, double y, double z, unsigned int d) ;
19 void splitPoint(double x, double y, double z, unsigned desdepth);
20 void walkLeaves(const_cellfn c, void* v) const;
21 void walkLeaves(cellfn c, void* v);
22 void walkWithKids(const_cellfn2 c, void* v);
23 void assignIDs() const;
24 unsigned leafCountByWalk() const; // inefficient, don't use too much
25 unsigned leafCount() const;
26
27 const OctCell** process() const; // tree mutations are complete for now
28
29 void debug();
30 private:
31
32 double side[3];
33 OctCell p;
34 bool modified;
35 mutable size_t leafcount;
36 friend class OctCell;
37 };
38
39
40 }

  ViewVC Help
Powered by ViewVC 1.1.26