An apparatus and a method for obtaining, in vivo, a measurement of retinal response to an optical stimuli. Light sources provide optical stimuli to the retina in accordance with predetermined stimulation sequences, and images of the retina are obtained and correlated with the predetermined stimulation sequences so as to determine responses of the retina to the optical stimuli. In one particular embodiment, optical stimuli are provided according to m-sequences and correlated with corresponding optical coherence tomography images to determine a functional response of the retina.