How Quattro Works?

So today I got stuck in the snow in my 2000 Audi A6 4.2L. It got me thinking how the quattro system truly works in my year car. Heres a sample pic : Using it as reference to my car.

http://i.imgur.com/5N9O2Qr.png

Ok the the wheels circled in Green where touching the ground when I got stuck. The Passenger front was on the ground along with the drivers rear.

The wheels circled in Red where not. The drivers front was just freely spinning when in gear a idle. The passenger rear was the same way but not as bad.

Now heres my question. When I hit the gas in Drive or Reverse the tires in red (that are not touching the ground) were spinning hardcore, but the tires in green that were touching the ground were not moving what so ever. Like NO POWER was being delivered to them. Why is that? In my eyes that seems ass backwards. Im sure I would have got out if the tires touching the group actually moved, but they didn’t. It just kept spinning the two that were not even having any contact with anything. In the end my brother in his Subaru had to pull me out. Embarrassing