Complete restructuring of on-the-fly axial ray tracking