change return type of RotationItem::rotation
In core, we have class IRotation
and children to describe various rotation operations, and class RotMatrix
(wrapping a class from libheinz) to describe the same in uniform way through a matrix, which in turn is parameterized by quaternions. Maybe we should merge these two descriptions in the future. For the moment, the least we can do, is to distinguish them clearly and cleanly.
In class RotationItem
, we have a function rotation
, which does not return an IRotation*
, but a RotMatrix
. It should be replaced by a function rotation
that returns an IRotation*
. With that, in ItemWithParticles::createRotation
we can use IRotation::clone
instead of passing to matrix description and back.
If the matrix is needed, it can be created indirectly by item->rotation()->rotMatrix()
. Therefore, there is no place in RotationItem
for a function that directly returns a RotMatrix
.