PunctualLight constructor

PunctualLight({
  1. required LightType type,
  2. Vector3? position,
  3. Vector3? direction,
  4. (double, double, double) color = (1.0, 1.0, 1.0),
  5. double intensity = 10.0,
  6. double? range,
  7. double innerConeAngle = 0.0,
  8. double outerConeAngle = 0.7853981633974483,
})

A light of type at position.

Implementation

PunctualLight({
  required this.type,
  Vector3? position,
  Vector3? direction,
  this.color = const (1.0, 1.0, 1.0),
  this.intensity = 10.0,
  this.range,
  this.innerConeAngle = 0.0,
  this.outerConeAngle = 0.7853981633974483,
}) : position = position ?? Vector3.zero(),
     direction = direction ?? Vector3(0, 1, 0);