Add a maximum topography for external usage - #945
Conversation
Coverage Report for CI Build 30487714247Coverage increased (+0.008%) to 98.308%Details
Uncovered ChangesNo uncovered changes found. Coverage RegressionsNo coverage regressions found. Coverage Stats
💛 - Coveralls |
|
MFraters
left a comment
There was a problem hiding this comment.
Looks generally good, but I have a few comments. I would like t ask you to add tests for every plugin and also add a test to show that you actually picked the correct max topography.
Would you also be willing to add a minimum topography function, while you are add it?
| * feature. Features without topography return zero. | ||
| */ | ||
| virtual | ||
| double maximum_topography() const; |
There was a problem hiding this comment.
I think every plugin should implement this, because there is no sensible default implementation. So could you make it const = 0;?
There was a problem hiding this comment.
Done. now its double maximum_topography() const = 0;
|
|
||
| - Added Perlin noise models for composition and temperature across features, and gwb-dat coverage tests for Cartesian Perlin noise inputs. \[Tilman May; 2026-03-29; [#906](https://github.com/GeodynamicWorldBuilder/WorldBuilder/pull/906)\] | ||
|
|
||
| - Added a `maximum_topography()` API that returns a guaranteed upper bound for all configured topography models. \[Michael Pons; 2026-07-26\] |
There was a problem hiding this comment.
Can you add this pull request as a reference at the end?
| double | ||
| Interface::maximum_topography() const | ||
| { | ||
| return 0.0; | ||
| } | ||
|
|
There was a problem hiding this comment.
I don't think the interface should define a default version. I think every plugin should define a correct value.
Hi everyone,
this PR adds
World::maximum_topography(). It returns an upper bound for thetopography configured in World Builder. This allows applications such as
ASPECT to determine the required geometry size before creating the mesh.
I added tests for a model with uniform topography and for a model without
topography. The complete unit test suite passes.
Cheers,
Michael