Optical device for light field imaging, wherein the optical device comprises: - a light source configured to emit light along an optical path (160, 161), - a detector with a plurality of pixels, - a sample holder, which is arranged in the optical path (160, 161) downstream of the light source and upstream of the detector and which is configured to fix an object in the optical path (160, 161) of light, - a scanning optical unit (114, 114-1, 114-2, 115, 115-1, 115-2, 116, 122), which is arranged in the optical path (160, 161) downstream of the sample holder and upstream of the detector and which is configured, for a multiplicity of scanning positions, in each case selectively to direct light incident from different angular ranges from the object onto the detector, - a collimator optical unit, which is arranged in the optical path downstream of the scanning optical unit and upstream of the detector and which is configured, for the various scanning positions, in each case to image light from the different angular ranges onto different pixels of the detector, wherein the collimator optical unit is configured to image an exit pupil plane of the scanning optical unit (114, 114-1, 114-2, 115, 115-1, 115-2, 116, 122) onto a detector area of the detector, wherein a distance between the collimator optical unit and the detector corresponds to a focal length of the collimator optical unit, wherein the detector is configured to detect measurement data for each of the multiplicity of scanning positions, - a computing unit, which is coupled to the detector and which is configured, on the basis of a three-dimensional light field represented by the measurement data of the multiplicity of scanning positions to generate a spatially resolved imaging of the object that comprises at least two images from different object planes of the object. - a light source configured to emit light along an optical path (160, 161), - a detector with a plurality of pixels, - a sample holder, which is arranged in the optical path (160, 161) downstream of the light source and upstream of the detector and which is configured to fix an object in the optical path (160, 161) of light, - a scanning optical unit (114, 114-1, 114-2, 115, 115-1, 115-2, 116, 122), which is arranged in the optical path (160, 161) downstream of the sample holder and upstream of the detector and which is configured, for a multiplicity of scanning positions, in each case selectively to direct light incident from different angular ranges from the object onto the detector, - a collimator optical unit, which is arranged in the optical path downstream of the scanning optical unit and upstream of the detector and which is configured, for the various scanning positions, in each case to image light from the different angular ranges onto different pixels of the detector, wherein the collimator optical unit is configured to image an exit pupil plane of the scanning optical unit (114, 114-1, 114-2, 115, 115-1, 115-2, 116, 122) onto a detector area of the detector, wherein a distance between the collimator optical unit and the detector corresponds to a focal length of the collimator optical unit, wherein the detector is configured to detect measurement data for each of the multiplicity of scanning positions, - a computing unit, which is coupled to the detector and which is configured, on the basis of a three-dimensional light field represented by the measurement data of the multiplicity of scanning positions to generate a spatially resolved imaging of the object that comprises at least two images from different object planes of the object.