Closed rolanddenis closed 4 years ago
Another question: if we choose std::round
as the rounding mode when calculating the origin point (https://github.com/DGtal-team/DGtal/blob/master/src/DGtal/kernel/BasicPointFunctors.h#L459), shouldn't we do the same when calculating the embeddings in operator()
(https://github.com/DGtal-team/DGtal/blob/master/src/DGtal/kernel/BasicPointFunctors.h#L482) ? Maybe also store the origin point as a RealPoint
?
A temporary fix (but completely wrong) has been merged through https://github.com/DGtal-team/DGtal/pull/1345/commits/2abba3d6e18a0327c59dc7b14b3c295fa0e806f0 so that testBasicFunctors
passes.
Could this issue be closed?
perhaps not I will have a look to remake the test correctly and complete some add in the doc.
Point2DEmbedderIn3D
has two constructors:For this last constructor, the calculated 2D -> 3D embeddings will depend on the chosen basis but this choice is not documented. So, is the way this basis is actually chosen a kind of canonical way ?
In addition, the fix applied when the
pRefOrigin
point is equal toanOriginPoint
(see https://github.com/DGtal-team/DGtal/blob/master/src/DGtal/kernel/BasicPointFunctors.h#L432) may lead to a basis that is not orthogonal to the given normal (eg with an origin at(1, 0, 0)
and with the normal(sqrt(2)/2, sqrt(2)/2, 0)
).