Main Page | Namespace List | Class Hierarchy | Class List | Directories | File List | Class Members | File Members | Related Pages

vpboundingbox.h

Go to the documentation of this file.
00001 
00002 
00003 
00004 
00005 // ChangeLog is at the implementation file
00006 
00007 #ifndef __VPBOUNDINGBOX_H
00008 #define __VPBOUNDINGBOX_H
00009 
00010 #include "vppoint4d.h"
00011 #include <iostream>
00012 
00017 class VPBoundingBox {
00019     // FixMe: Perhaps this will cause trouble on an application with no console...
00020     friend std::ostream& operator<<(std::ostream& output, const VPBoundingBox& box);
00021     public:
00023         VPBoundingBox();
00024         VPBoundingBox(double minX, double minY, double minZ,
00025                       double maxX, double maxY, double maxZ);
00026         VPBoundingBox(const VPBoundingBox& box);
00027 
00028         VPBoundingBox& operator=(const VPBoundingBox& box);
00029         void ProcessCenter();
00030 
00031         double GetGreaterX() const;
00032         double GetGreaterY() const;
00033         double GetGreaterZ() const;
00034 
00036         double GetGreaterEdge() const;
00037 
00038         void SetGreaterX(double v);
00039         void SetGreaterY(double v);
00040         void SetGreaterZ(double v);
00041 
00042         double GetSmallerX() const;
00043         double GetSmallerY() const;
00044         double GetSmallerZ() const;
00045 
00046         void SetSmallerX(double v);
00047         void SetSmallerY(double v);
00048         void SetSmallerZ(double v);
00049 
00050         void SetBoundingBox(double minX, double minY, double minZ,
00051                             double maxX, double maxY, double maxZ);
00052 
00053         const VPPoint4D& GetCenter() const;
00054 
00056         void ConditionalUpdate(double x, double y, double z);
00058         void ConditionalUpdate(const VPPoint4D& point);
00059 
00061         void MergeWith(const VPBoundingBox& box);
00062     private:
00063         double greaterX, greaterY, greaterZ;
00064         double smallerX, smallerY, smallerZ;
00065         VPPoint4D center;
00066 };
00067 
00068 #endif  // __VPBOUNDINGBOX_H

Generated on Tue Sep 6 10:00:03 2005 for VPAT by  doxygen 1.4.4