needs to be extendend to include symmetry
modified versions from 3Drotations code (available on GitHub) by Marc De Graef