added 4x4 matrix rotation function