public static IntensityDetectorArray FromRadialSensors(IIntensityDetector[] sensors) { double count = sensors.Length; double angle = Math.PI * 2 / sensors.Length; OrientedIntensityDetector[] preparedSensors = new OrientedIntensityDetector[sensors.Length]; for (int i = 0; i < count; i++) { preparedSensors[i] = new OrientedIntensityDetector( sensors[i], Vector.FromPolarCoords(1, i * angle) ); } return new IntensityDetectorArray(preparedSensors); }
public OrientedIntensityDetector(IIntensityDetector detector, Vector orientation) { Detector = detector; Orientation = orientation; }