Well, In sailing you need to know from what direction the wind is coming from. So you use the things around you to help, e.g. the trees what way are they being blown, if you are near water which way...
They use an anemometer to see how fast the wind is blowing and they use windsocks to check as well, when the wind blows, the force of the wind will guide the sock and thats how the direction is...