def arcball_nearest_axis(point, axes):
 point = numpy.array(point, dtype=numpy.float64, copy=False)
 nearest = None
 mx = (-1.0)
 for axis in axes:
  t = numpy.dot(arcball_constrain_to_axis(point, axis), point)
  if (t > mx):
   nearest = axis
   mx = t
 return nearest

def arcball_nearest_axis ( point , axes ) : point = numpy . array ( point , dtype = numpy . float64 , copy = False ) nearest = None mx = ( - 1.0 ) for axis in axes : t = numpy . dot ( arcball_constrain_to_axis ( point , axis ) , point ) if ( t > mx ) : nearest = axis mx = t return nearest
return axis .