Point

giant.ray_tracer.shapes.point:

class giant.ray_tracer.shapes.point.Point(location)[source]

Represents a single, unrenderable point.

The point is just a shell around a size 3 numpy array to keep track of the location (but not orientation) of something in a scene that you don’t actually want to render when doing ray tracing. Therefore, this is most frequently used to represent the location of the sun in the scene. Technically you can also use this if you are only doing unresolved relative navigation; however, this is not recommended since no knowledge of the size of the object is available.

To use this class simply provide the initial location as a length 3 array like object. It can then be rotated/translated like other objects in a scene (though again note that it won’t be rendered, and its orientation is not tracked, only the position). If you are looking for something that will track both position and orientation, and can be rendered then we recommend checking out the Ellipsoid class instead.

Parameters:

location (Sequence | ndarray) – The starting location in the current frame for the point as a size 3 array like object.

location: ndarray

The location of the point as a length 3 double array.

Summary of Methods

rotate

This rotates the point into a new frame in place.

translate

This translates the location of the point.