Ellipsoid.compute_intersect

giant.ray_tracer.shapes.ellipsoid:

Ellipsoid.compute_intersect(self, ray)

This method computes the intersect between a single ray and the ellipsoid, returning an INTERSECT_DTYPE numpy array with the intersect location, surface normal at the intersect, and surface albedo at the intersect.

This method calls the intersect() method first, and then computes the local normal vector and albedo at the intersection point, returning the results in the proper structured array format.

While this method can handle multiple rays, it is better to reserve this for single ray checks for consistency with Surface objects.

Parameters:

ray (Rays) – The ray to perform the intersect check with

Returns:

A numpy array with INTERSECT_DTYPE as the data type.

Return type:

np.ndarray