Ignore:
Timestamp:
06/18/08 20:42:06 (16 years ago)
Author:
mattausch
Message:

implemented multiqueries, but still buggy version

File:
1 edited

Legend:

Unmodified
Added
Removed
  • GTP/trunk/App/Demos/Vis/CHC_revisited/OcclusionQuery.h

    r2772 r2773  
    1717{ 
    1818public: 
    19          
     19        /** constructor requesting an opengl occlusion query. 
     20        */ 
    2021        OcclusionQuery(); 
    2122 
     
    2627        unsigned int GetQueryResult() const; 
    2728         
    28         void BeginQuery(); 
     29        void BeginQuery() const; 
    2930         
    30         void EndQuery(); 
     31        void EndQuery() const; 
    3132         
    3233        unsigned int GetQueryId() const; 
     
    3435        */ 
    3536        inline BvhNode *GetFrontNode() const { return mNodes[0]; } 
    36         /** Reset the contents of this query. 
     37        inline const BvhNodeContainer &GetNodes() const { return mNodes; } 
     38 
     39        /** Reset the list of nodes associated with this query. 
    3740        */ 
    3841        inline void Reset() { mNodes.clear(); } 
     
    4043        */ 
    4144        inline void AddNode(BvhNode *node) { mNodes.push_back(node); } 
    42         /** Convenience method that sets up a single node query. 
     45        /** Returns the size of the multiquery. 
    4346        */ 
    44         inline void SetNode(BvhNode *node) { Reset(); AddNode(node); } 
     47        inline int GetSize() const { return (int)mNodes.size();} 
    4548 
    46          
    4749protected: 
    4850 
    49         OcclusionQuery(unsigned int id); 
    50          
    5151         
    5252        /////// 
    5353        //-- members 
    5454 
    55         //float mPFail; 
    5655        /// all nodes that are tested with the same query 
    5756        BvhNodeContainer mNodes;  
Note: See TracChangeset for help on using the changeset viewer.