Skip to content
Snippets Groups Projects
Commit e22bda30 authored by Paul McCarthy's avatar Paul McCarthy :mountain_bicyclist:
Browse files

BF: Use volume extrapolation getters rather than fields, as the fields won't

have been initialised on ShadowVolume instances, whereas the getters will
delegate to the owning volume
parent 5ac780b1
No related branches found
No related tags found
1 merge request!43BF: Use `volume` extrapolation getters rather than fields, as the fields may not have been initialised on `ShadowVolume` instances, whereas the getters will delegate to the owning volume
......@@ -207,26 +207,26 @@ int readGeneralVolume(volume<T>& target, const std::string& filename,
public:
extrapolation method(const volume<T>& vol) const {
if (_use_default_method) return vol.p_extrapmethod;
if (_use_default_method) return vol.getextrapolationmethod();
else return _method;
}
T padvalue(const volume<T>& vol) const {
if (_use_default_padvalue) return vol.padvalue;
if (_use_default_padvalue) return vol.getpadvalue();
else return _padvalue;
}
T& extrapval() const {
return _extrapval;
}
bool xvalid(const volume<T>& vol) const {
if (_use_default_validity) return std::get<0>(vol.ep_valid);
if (_use_default_validity) return vol.getextrapolationvalidity()[0];
else return _xvalid;
}
bool yvalid(const volume<T>& vol) const {
if (_use_default_validity) return std::get<1>(vol.ep_valid);
if (_use_default_validity) return vol.getextrapolationvalidity()[1];
else return _yvalid;
}
bool zvalid(const volume<T>& vol) const {
if (_use_default_validity) return std::get<2>(vol.ep_valid);
if (_use_default_validity) return vol.getextrapolationvalidity()[2];
else return _zvalid;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment