source: GTP/trunk/Lib/Vis/Preprocessing/src/ObjectPvs.h @ 2116

Revision 2116, 827 bytes checked in by mattausch, 17 years ago (diff)

implemented hashpvs

Line 
1#ifndef __OBJECTPVS_H
2#define __OBJECTPVS_H
3
4#include "common.h"
5#include "PvsDefinitions.h"
6
7using namespace std;
8
9namespace GtpVisibilityPreprocessor {
10
11class KdNode;
12class BspNode;
13class Ray;
14class Intersectable;
15class ViewCell;
16
17
18class ObjectPvs: public DefaultPvs
19{
20public:
21        /** Counts object int the pvs. Different to method "GetSize", not
22                only the raw container size is returned,
23                but the individual contributions of the entries are summed up.
24        */
25        float EvalPvsCost() const;
26
27        friend ostream &operator<<(ostream &s, const ObjectPvs &p)
28        {
29                ObjectPvsIterator pit = p.GetIterator();
30
31                while (pit.HasMoreEntries())
32                {               
33                        const ObjectPvsEntry &entry = pit.Next();
34                        Intersectable *obj = entry.mObject;
35
36                        cout << obj << " ";
37                }
38               
39                return s;
40        }
41};
42
43
44
45}
46
47#endif
48
Note: See TracBrowser for help on using the repository browser.