fix mathutil warnings

This commit is contained in:
David Rose 2007-06-12 03:03:55 +00:00
parent f1e5ae4ca3
commit e34ee0d81b
3 changed files with 26 additions and 0 deletions

View File

@ -203,3 +203,23 @@ contains_box(const BoundingBox *box) const {
return result;
}
////////////////////////////////////////////////////////////////////
// Function: BoundingPlane::contains_line
// Access: Public, Virtual
// Description:
////////////////////////////////////////////////////////////////////
int BoundingPlane::
contains_line(const BoundingLine *line) const {
return IF_possible;
}
////////////////////////////////////////////////////////////////////
// Function: BoundingPlane::contains_plane
// Access: Public, Virtual
// Description:
////////////////////////////////////////////////////////////////////
int BoundingPlane::
contains_plane(const BoundingPlane *plane) const {
return IF_possible;
}

View File

@ -60,6 +60,8 @@ protected:
virtual int contains_sphere(const BoundingSphere *sphere) const;
virtual int contains_box(const BoundingBox *box) const;
virtual int contains_line(const BoundingLine *line) const;
virtual int contains_plane(const BoundingPlane *plane) const;
private:
Planef _plane;

View File

@ -448,6 +448,10 @@ around_finite(const BoundingVolume **first,
for (++p; p != last; ++p) {
nassertr(!(*p)->is_infinite(), false);
if (!(*p)->is_empty()) {
if (!(*p)->is_of_type(FiniteBoundingVolume::get_class_type())) {
set_infinite();
return true;
}
const FiniteBoundingVolume *vol = DCAST(FiniteBoundingVolume, *p);
LPoint3f min1 = vol->get_min();
LPoint3f max1 = vol->get_max();