MeshLib
 
Loading...
Searching...
No Matches
MR::BasinVolumeCalculator Class Reference

#include <MRBasinVolume.h>

Public Member Functions

MRMESH_API bool addTerrainTri (Triangle3f t, float level)
 
double getVolume () const
 call it after all addTerrainTri to get the volume
 

Detailed Description

the class to compute the volume of water some basin can accumulate, considering that water upper surface has constant z-level

Member Function Documentation

◆ addTerrainTri()

MRMESH_API bool MR::BasinVolumeCalculator::addTerrainTri ( Triangle3f t,
float level )

pass every triangle of the basin here, and the water level;

Returns
true if the triangle is at least partially below the water level and influences on the volume

◆ getVolume()

double MR::BasinVolumeCalculator::getVolume ( ) const
inlinenodiscard

call it after all addTerrainTri to get the volume


The documentation for this class was generated from the following file: