Lights¶
PointLight¶
- class pydy.viz.light.PointLight(*args, **kwargs)[source]¶
Creates a PointLight for the visualization The PointLight is inherited from VisualizationFrame,
It can also be attached to dynamics objects, hence we can get a moving Light. All the transformation matrix generation methods are applicable to a PointLight. Like VisualizationFrame, It can also be initialized using: 1)Rigidbody 2)ReferenceFrame, Point 3)ReferenceFrame, Particle Either one of these must be supplied during initialization
Unlike VisualizationFrame, It doesnt require a Shape argument.
- property color¶
Color of Light.
- generate_scene_dict()[source]¶
This method generates information for a static visualization in the initial conditions, in the form of dictionary. This contains light parameters followed by an init_orientation Key.
Before calling this method, all the transformation matrix generation methods should be called, or it will give an error. Returns ======= A dict with following Keys:
name: name for the camera
color: Color of the light
init_orientation: Initial orientation of the light object
- generate_simulation_dict()[source]¶
Generates the simulation information for this Light object. It maps the simulation data information to the scene information via a unique id.
Before calling this method, all the transformation matrix generation methods should be called, or it will give an error.
- Returns
- A dictionary containing list of 4x4 matrices mapped to
- the unique id as the key.