CircleEmitter
A circle that emits rays radiating out from its perimiter
-
Angle of the step between emitted rays
The value is clamped to a minimum of
0
Declaration
Swift
public var rayStep: Int { get set }
-
Visual style for the emitter’s rays
Declaration
Swift
public var style: RayTraceStyle
-
Instantiate a new emitter at the specified coordinates
Declaration
Swift
public init(x: Double, y: Double, radius: Double, rayStep: Int)
Parameters
x
Center X coordinate
y
Center Y coordinate
radius
Radius of the emitter
rayStep
Angle between emitted rays
-
Process the ray casting operations for this emitter.
This method calculates the paths of the emitter’s rays, but does not draw them. Any previous rays will be overwritten.
Declaration
Swift
public func run(objects: [RayTracable])
Parameters
objects
The objects with which the rays will interact
-
Draw the paths taken by the emitter’s rays.
This method does not perform any ray tracing.
Declaration
Swift
public func draw()