Look around, do you know where you are? Maybe you are in your room, maybe you are in a cafe, in a car, or outdoors. You must be clearly convinced you are in 3D space filled with all sorts of 3D objects. This sense is fundamental to your reality. But how do you know all that?
All you see around is colorful 2D shapes. And yet, when you slightly move, these shapes start to deform and overlap. The closer you are the bigger the changes, the easier it is to spot them, the stronger is sense of spatial awareness. There further you are, the less objects change, the harder it is to judge their positions and shapes. At horizon everything becomes 2D. Then there are heuristics that make whole job a lot easier — gradients that mimic shadows, dark and bright colors, continuity of colors and shapes, rules of projections. Funny enough, they don't work all the time leading to abundance of illusions and creatures that exploit these illusions for survival. In the worst case, if you see a car far away — no parallax, small shapes, no gradients — there is no basis to believe it has 3D shape you believe it has. For all you know, you have seen cars before, which leads you to believe it has that particular kind of shape. Next time try it yourself to observe your thought process when guessing shape of object away, you would get just a recollection from memory. Maybe you wold even do some reasoning, if that thing really got your attention. If it is something unseen you would get absolutely no idea. This is basically Tesla Autopilot.
It is easy to think of evolutionary interpretation. Why do we need 3D? It allows more accurate predictions on how world changes. It would help dexterity at your tasks for food gathering, hunting, moving. Why we are so bad at 3D in distance? If we measure complexity of world by number of objects and number of their interactions — nodes and edges in world graph — then 3D world quickly outpaces 2D version with size. Besides, the most important things to you are probably nearby — food, danger, friends. If something is far, then it is pretty safe to get minimal understanding about it until you get closer to it — or it will get closer to you! — only then you may think how it fits into your 3D world. Simple queries for objects far away such as "which direction it moves?", "what it's size?", "is it a single thing?", "what kind of a thing?" all work just fine with fast and memory efficient 2D memory and reasoning. Why do we need heuristics then? Even for small sizes, 3D processing may requite a lot of effort. Meanwhile, due to short distances it has to be fast and reliable. Thus, it is a good idea to have a bunch fast loosely coupled heuristics. It is also interesting how other creatures developed their perception of space due to specifics of their environment. Worlds of bugs in dynamic micro-scale, large creatures in rain-forest, whales in wide oceans, and birds spending fair portion of their time looking to flat surface with all sorts of things — all must be very different from ours. Just as interesting is how subjective perception of 3D changes with echolocation or sense of electromagnetic fields — is it similar to ours, fake 3D on top of 2D imagery, or is it a totally new sense like temperature?
In the end, it is just mind-blowing that 3D world you live in is nothing but a 2D image and a sense. This sense is not even absolute, but rather a continuum from very strong nearby to weak far away. All heavy lifting is done behind the scenes by evolutionary algorithm encoded in neural cortex. It is working hard to provide you with most accurate and fast representation based on all sorts of clues and extra signals. You don't even notice it. When it fails, you don't realize it. But most of the time it works spectacularly. You wholeheartedly believe it and start live in a world of its output even if it does not directly exist anywhere. Truly marvelous tech right here.