Skip to content

Commit

Permalink
AltitudeFilter: check for empty geom after script
Browse files Browse the repository at this point in the history
  • Loading branch information
gwaldron committed Mar 4, 2019
1 parent 40587e4 commit f2406a3
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/osgEarthFeatures/AltitudeFilter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,8 @@ AltitudeFilter::pushAndDontClamp( FeatureList& features, FilterContext& cx )
StringExpression temp( _altitude->script().get() );
feature->eval( temp, &cx );
}
if (feature->getGeometry() == 0L)
continue;

double minHAT = DBL_MAX;
double maxHAT = -DBL_MAX;
Expand Down Expand Up @@ -192,6 +194,8 @@ AltitudeFilter::pushAndClamp( FeatureList& features, FilterContext& cx )
StringExpression temp( _altitude->script().get() );
feature->eval( temp, &cx );
}
if (feature->getGeometry() == 0L)
continue;

double maxTerrainZ = -DBL_MAX;
double minTerrainZ = DBL_MAX;
Expand Down

0 comments on commit f2406a3

Please sign in to comment.