Improved compatibility for Matrix3D

This PR is to improve the cross platform compatibilty between the Flash Matrix3D class and the HTML5 and native backends. This also required the introdcution of Orientation3D.

Associated test are also included.