1. Apparatus, comprising: a spatial light modulator (SLM) having a plurality of pixels, each pixel being configurable to direct or not to direct light toward a photodetector array; an optical mask adapted to subject to spatial modulation the light directed by the SLM toward the photodetector array; and the photodetector array adapted to measure an interference pattern produced by the spatially modulated light.