Ignore:
Timestamp:
08/12/05 01:17:56 (19 years ago)
Author:
mattausch
Message:

added some bsp stuff

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/VUT/GtpVisibilityPreprocessor/src/ViewCell.h

    r224 r235  
    33 
    44#include "Intersectable.h" 
     5#include "Containers.h" 
    56 
    67class Mesh; 
     
    1920                the viewcell. 
    2021        */ 
    21         ViewCell(Mesh *mesh): mMesh(mesh), mPvs(NULL) {} 
     22        ViewCell(Mesh *mesh); 
    2223 
    2324        /** Returns pointer to the mesh which represents the shape of the viewcell. 
    2425        */ 
    25         Mesh *GetMesh() {return mMesh;} 
     26        Mesh *GetMesh(); 
    2627 
    2728        /** Returns pointer to PVS.  
    2829                @returns PVS, i.e., the visible BSP tree nodes. 
    2930        */ 
    30         BspPvs *GetPVS() {return mPvs;} 
     31        BspPvs *GetPVS(); 
    3132 
    32         AxisAlignedBox3 GetBox()  {return mMesh->mBox;} 
     33        AxisAlignedBox3 GetBox(); 
    3334   
    34         int CastRay(Ray &ray) {return 0;} 
     35        int CastRay(Ray &ray); 
    3536   
    36         bool IsConvex() {return mMesh->mIsConvex;} 
    37         bool IsWatertight() {return mMesh->mIsWatertight;} 
    38         float IntersectionComplexity() {return mMesh->mFaces.size();} 
     37        bool IsConvex(); 
     38        bool IsWatertight(); 
     39        float IntersectionComplexity(); 
    3940 
    40         int Type() const { return VIEWCELL; } 
     41        int Type() const; 
    4142 
    42         void GetRandomSurfacePoint(Vector3 &point, Vector3 &normal) {point = Vector3(0,0,0);}; 
     43        void GetRandomSurfacePoint(Vector3 &point, Vector3 &normal); 
    4344 
     45        /** Derives viewcells from object container. 
     46                @param objects the intersectables the viewcells are derived from 
     47                @param viewCells the viewcells are returned in this container 
     48                @param if >0, indicates the maximim number of viewcells that will be created 
     49        */ 
     50        static void DeriveViewCells(const ObjectContainer &objects,  
     51                                                                ViewCellContainer &viewCells,  
     52                                                                const int max); 
    4453protected: 
    4554 
     55        /// the mesh defining the geometry of this viewcell 
    4656        Mesh *mMesh; 
    4757        /// the PVS (i.e., the visible bsp tree nodes) 
Note: See TracChangeset for help on using the changeset viewer.