[pdal-commits] [PDAL/PDAL] 91206b: Enable clamping in colorinterp filter
Andrew Bell
noreply at github.com
Tue Apr 28 07:09:38 PDT 2020
Branch: refs/heads/issue-2729
Home: https://github.com/PDAL/PDAL
Commit: 91206b895521b83a7c061326a679b4e247f5ed4f
https://github.com/PDAL/PDAL/commit/91206b895521b83a7c061326a679b4e247f5ed4f
Author: Matt Csencsits <matt.csencsits at minevisionsystems.com>
Date: 2020-01-31 (Fri, 31 Jan 2020)
Changed paths:
M filters/ColorinterpFilter.cpp
M filters/ColorinterpFilter.hpp
M test/unit/filters/ColorinterpFilterTest.cpp
Log Message:
-----------
Enable clamping in colorinterp filter
Fixes #2729.
Previously values outside a determined range would be left with
default values, potentially providing unexpected results. This
commit adds a `clamp` parameter to a user can explicitly control
whether values outside the given range will be colored.
There apparently an explicit design decision to not include
values equal to the maximum in the coloring. When clamping, this
design then resulted in values that were greated than the max to
still be left uncolored. Since nothing in the available user
documentation explicitly states that the valid range is exclusive
of the maximum value it has been changed to be inclusive.
This required modifying two unit tests which were testing for
maximum values to be excluded from the coloring.
An other approach could have beent to clamp to a value slightly
less than m_max (e.g. m_max - DBL_EPSILON). But this would still
leave a discrepancy between the documentation and the implementation.
Commit: 7bde55ad76706a331e678dc8abecc58a4cdafbbe
https://github.com/PDAL/PDAL/commit/7bde55ad76706a331e678dc8abecc58a4cdafbbe
Author: Matt Csencsits <matt.csencsits at minevisionsystems.com>
Date: 2020-04-27 (Mon, 27 Apr 2020)
Changed paths:
M filters/ColorinterpFilter.cpp
Log Message:
-----------
Address comments from PR PDAL/PDAL#3046
* Removed single line `if` statements
* Simplified clamping `position` to use `std::min`
Commit: 074211c7f1ca5a7c70a2540d1926321daa35ecaf
https://github.com/PDAL/PDAL/commit/074211c7f1ca5a7c70a2540d1926321daa35ecaf
Author: Andrew Bell <andrew.bell.ia at gmail.com>
Date: 2020-04-28 (Tue, 28 Apr 2020)
Changed paths:
M filters/ColorinterpFilter.cpp
M filters/ColorinterpFilter.hpp
M test/unit/filters/ColorinterpFilterTest.cpp
Log Message:
-----------
Merge branch 'issue-2729' of https://github.com/MattCsencsits/PDAL
Commit: 4fdb14b13830e2ef10913ff6181a247ac476cd49
https://github.com/PDAL/PDAL/commit/4fdb14b13830e2ef10913ff6181a247ac476cd49
Author: Andrew Bell <andrew.bell.ia at gmail.com>
Date: 2020-04-28 (Tue, 28 Apr 2020)
Changed paths:
M filters/ColorinterpFilter.cpp
Log Message:
-----------
Guard std::min.
Compare: https://github.com/PDAL/PDAL/compare/91206b895521%5E...4fdb14b13830
More information about the pdal-commits
mailing list