In FieldConvert modules interppoints and interpptstopts, and in the HistoryPoints filter, the points can be generated using line, plane or box, such as
However, the number of points
npts must be greater than 1 because the grid size is computed using
delta = (zmax - zmin) / (npts3 - 1) in the code. As a result, the box cannot reduced to a plane or a line automatically by setting 'npts' as 1. This causes inconvenience since defining a box is apparently easier than defining a plane.
This problem can be fixed by changing the way of computing the grid size. One feasible solution is setting
delta = (zmax - zmin) / max(1, npts3 - 1). If
npts is less than 1, the loop
for(int i=0; i<npts; ++i) will only get executed with
Please add any other information that could be useful for reviewers. close #321
Functions and classes, or changes to them, are documented.
User guide/documentation is updated.
Changelog is updated.
Suitable tests added for new functionality.
Contributed code is correctly formatted. (See the contributing guidelines).
License added to any new files.
No extraneous files have been added (e.g. compiler output or test data files).