Prevent assertion when calculating bounds for geom without vertices

This commit is contained in:
rdb 2017-05-13 21:40:22 +02:00
parent a1a99c49c0
commit e15cfd74e8
1 changed files with 3 additions and 3 deletions

View File

@ -1257,15 +1257,15 @@ compute_internal_bounds(Geom::CData *cdata, Thread *current_thread) const {
InternalName::get_vertex(),
cdata, current_thread);
nassertv(!pmin.is_nan());
nassertv(!pmax.is_nan());
BoundingVolume::BoundsType btype = cdata->_bounds_type;
if (btype == BoundingVolume::BT_default) {
btype = bounds_type;
}
if (found_any) {
nassertv(!pmin.is_nan());
nassertv(!pmax.is_nan());
// Then we put the bounding volume around both of those points.
PN_stdfloat avg_box_area;
switch (btype) {