-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature/gridedit 785 refactor mesh refinement #263
base: master
Are you sure you want to change the base?
Changes from all commits
b914cbc
71b9389
d334d86
06d4802
fb263c7
4069e8b
3aa50de
9dd8619
bb64424
50e51e6
fe20718
c20a260
a7c7a54
77cea5c
4549499
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -36,6 +36,9 @@ namespace meshkernel::averaging | |
public: | ||
virtual ~AveragingStrategy() = default; | ||
|
||
/// @brief Reset the state of the averaging strategy, ready for the next calculation. | ||
virtual void Reset(const Point& interpolationPoint) = 0; | ||
|
||
/// @brief Adds the specified sample point. | ||
/// @param[in] samplePoint The sample point to add to this strategy. | ||
/// @param[in] sampleValue The value associated with the sample point. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Never liked the how samplePoint is a dummy arg in most derived classes. Only There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The only way I can see to resolve this is going back to the orginal, allocating a new object for each interpolation point. |
||
|
@@ -44,5 +47,14 @@ namespace meshkernel::averaging | |
/// @brief Calculates the average value based on the values added. | ||
/// @return The calculated average | ||
[[nodiscard]] virtual double Calculate() const = 0; | ||
|
||
/// @brief Calculates the average value based on the sample values. | ||
/// @param[in] interpolationPoint The point for which the average should be calculated. | ||
/// @param[in] samplePoints The sample points to used by this strategy. | ||
/// @param[in] sampleValues The sample values associated with each sample point. | ||
/// @return The calculated average | ||
virtual double Calculate (const Point& interpolationPoint, | ||
const std::vector<Point>& samplePoints, | ||
const std::vector<double>& sampleValues) const = 0; | ||
}; | ||
} // namespace meshkernel::averaging |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add param interpolationPoint to doxy