A method for performing optical image detection using a camera module comprising a Digital MicroMirror Device, DMD (DMD1), a first point Photo Detector (PD1), a second point Photo Detector (PD2), a first lens (L3) and a second lens (L2), the method comprising: mapping incident light onto an image plane of the DMD to form a light irradiance map; selecting N pixels on the DMD for time-frequency coding; associating each selected pixel with a unique Walsh code time sequence; time-frequency coding by the DMD the optical irradiance values of each selected pixel using a plurality of selected bits of its associated Walsh code time sequence; wherein when a pixel of said selected pixels is being encoded with a code sequence bit the + θ tilt state of a DMD micromirror associated with the pixel images light from the pixel onto the first point Photo Detector (PD1) by means of the first lens (L3) and the - θ tilt state of the DMD micromirror images encoded pixel light onto the second point Photo Detector (PD2) by means of the second lens (L2); detecting the time-frequency coded optical irradiance values of the selected pixels simultaneously at the first point Photo Detector and at the second point Photo Detector; and performing simultaneous signal processing on the time-frequency coded optical irradiance values detected by the first point Photo Detector and by the second point Photo Detector to determine the light intensity of each of the selected pixels and produce an image of the incident light; wherein the method further comprises: time-frequency coding by the DMD the optical irradiance values of each selected pixel using the first M bits of its associated N-bit full Walsh code time sequence so as to perform time compression higher speed imaging, where M is a number which satisfies 2 n , wherein n is an integer and M is smaller than N. mapping incident light onto an image plane of the DMD to form a light irradiance map; selecting N pixels on the DMD for time-frequency coding; associating each selected pixel with a unique Walsh code time sequence; time-frequency coding by the DMD the optical irradiance values of each selected pixel using a plurality of selected bits of its associated Walsh code time sequence; wherein when a pixel of said selected pixels is being encoded with a code sequence bit the + θ tilt state of a DMD micromirror associated with the pixel images light from the pixel onto the first point Photo Detector (PD1) by means of the first lens (L3) and the - θ tilt state of the DMD micromirror images encoded pixel light onto the second point Photo Detector (PD2) by means of the second lens (L2); detecting the time-frequency coded optical irradiance values of the selected pixels simultaneously at the first point Photo Detector and at the second point Photo Detector; and performing simultaneous signal processing on the time-frequency coded optical irradiance values detected by the first point Photo Detector and by the second point Photo Detector to determine the light intensity of each of the selected pixels and produce an image of the incident light; wherein the method further comprises: time-frequency coding by the DMD the optical irradiance values of each selected pixel using the first M bits of its associated N-bit full Walsh code time sequence so as to perform time compression higher speed imaging, where M is a number which satisfies 2 n , wherein n is an integer and M is smaller than N. <EOS>