The biggest advantage of structured light is the highest depth accuracy, which can theoretically reach the micron level, and the ToF sensor can reach the millimeter level, which is sufficient even for face payment. The high accuracy of structured light also requires complex calibration, while the ToF sensor does not need.
In terms of resolution, both stereo vision and ToF sensor can have full resolution, and structured light depends on the pattern of light source projection. The biggest disadvantage of structured light is that it cannot cope with dynamic environments, that is, outdoor environments. The rapid changes in the light environment make structured light easily disturbed. secondly, the material cost is high, and the response speed is slow, which requires more computing resources. Again is the size. In theory, structured light can reduce the size, but the effective distance will also be greatly reduced, and the face must be close to the screen, which is obviously not practical. Finally, under low illumination, such as in a completely dark environment, the performance of structured light depends on the light source, but the ToF sensor does not, and its performance is better than that of structured light.