Changeset 1291 for GTP/trunk/Lib/Vis/Preprocessing/src/VspTree.h
- Timestamp:
- 08/28/06 18:42:33 (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
GTP/trunk/Lib/Vis/Preprocessing/src/VspTree.h
r1289 r1291 548 548 int CastLineSegment(const Vector3 &origin, 549 549 const Vector3 &termination, 550 ViewCellContainer &viewcells); 550 ViewCellContainer &viewcells, 551 const bool useMailboxing = true); 551 552 552 553 … … 618 619 void GetViewCells(const VssRay &ray, ViewCellContainer &viewCells); 619 620 620 621 /** Returns view cells tree. 622 */ 621 623 ViewCellsTree *GetViewCellsTree() const { return mViewCellsTree; } 622 624 625 /** Sets the view cells tree. 626 */ 623 627 void SetViewCellsTree(ViewCellsTree *vt) { mViewCellsTree = vt; } 624 628 … … 763 767 int EvalPvsSize(const RayInfoContainer &rays) const; 764 768 765 /** Computes pvs increase with respect to the previous pvs for heuristics.766 */767 int GetPvsIncr(Intersectable *object, const KdPvsMap &activeNodes);768 769 /** Returns absolute pvs contribution of this object.770 */771 int GetPvsContribution(Intersectable *object) const;772 773 769 /** Computes best cost for axis aligned planes. 774 770 */ … … 778 774 float &position); 779 775 776 777 778 ////////////////////////////////////////// 779 // Helper function for computing heuristics 780 780 781 /** Evaluates the contribution to left and right pvs at a visibility event ve. 781 782 @param ve the visibility event … … 783 784 @param rightPvs updates the right pvs 784 785 */ 785 void EvalHeuristicsContribution( 786 const SortableEntry &ve, 787 int &pvsLeft, 788 int &pvsRight) const; 789 790 /** Evaluates contribution of the ray to the left and right pvs. 786 void EvalHeuristics(const SortableEntry &ve, int &pvsLeft, int &pvsRight) const; 787 788 /** Evaluates contribution of min event to pvs 791 789 */ 792 790 int EvalMinEventContribution( 793 791 const VssRay &ray, const bool isTermination) const; 794 792 793 /** Evaluates contribution of max event to pvs 794 */ 795 795 int EvalMaxEventContribution( 796 796 const VssRay &ray, const bool isTermination) const; 797 797 798 /** Evaluates contribution of kd leaf when encountering a min event 799 */ 798 800 int EvalMinEventContribution(KdLeaf *leaf) const; 801 /** Evaluates contribution of kd leaf when encountering a max event 802 */ 799 803 int EvalMaxEventContribution(KdLeaf *leaf) const; 800 804 801 805 /** Prepares objects for the heuristics. 802 @returns pvs size of the ray container806 @returns pvs size as seen by the rays. 803 807 */ 804 808 int PrepareHeuristics(const RayInfoContainer &rays); 809 810 /** Prepare a single ray for heuristics. 811 */ 805 812 int PrepareHeuristics(const VssRay &ray, const bool isTermination); 813 /** Prepare a single kd leaf for heuristics. 814 */ 806 815 int PrepareHeuristics(KdLeaf *leaf); 816 817 ///////////////////////////////////////////////////////////////////////////// 818 807 819 808 820 /** Subdivides the rays into front and back rays according to the split plane. … … 831 843 832 844 */ 833 void UpdateObjPvsContri( 845 void UpdateContributionsToPvs( 846 const VssRay &ray, 847 const bool isTermination, 848 const int cf, 849 float &frontPvs, 850 float &backPvs, 851 float &totalPvs) const; 852 853 /** Evaluates the contribution for objects. 854 */ 855 void UpdateContributionsToPvs( 834 856 Intersectable *obj, 835 857 const int cf, … … 838 860 float &totalPvs) const; 839 861 840 void UpdateBvhLeafPvsContri( 862 /** Evaluates the contribution for bounding volume leaves. 863 */ 864 void UpdateContributionsToPvs( 841 865 BvhLeaf *leaf, 842 866 const int cf, … … 845 869 float &totalPvs) const; 846 870 847 848 /** See UpdateObjPvsContri.849 */850 void UpdateKdLeafPvsContri(KdLeaf *leaf,871 /** Evaluates the contribution for kd leaves. 872 */ 873 void UpdateContributionsToPvs( 874 KdLeaf *leaf, 851 875 const int cf, 852 876 float &frontPvs, … … 854 878 float &totalPvs) const; 855 879 856 /** Collects pvs from rays.857 */858 void CollectPvs(const RayInfoContainer &rays,859 ObjectContainer &objects) const;860 861 880 /** Returns true if tree can be terminated. 862 881 */ … … 916 935 RayInfoContainer &rays); 917 936 918 /** Add pvs contribution of this ray. 919 */ 920 int EvalPvsContribution(const VssRay &ray, const bool isTermination) const; 937 /** Evaluates pvs contribution of this ray. 938 */ 939 int EvalContributionToPvs(const VssRay &ray, const bool isTermination) const; 940 941 /** Evaluates pvs contribution of a kd node. 942 */ 943 int EvalContributionToPvs(KdLeaf *leaf) const; 944 921 945 922 946 protected:
Note: See TracChangeset
for help on using the changeset viewer.