Well it depends on the situation. You never should go up to a dog that you do not know. If your working some place with dogs always be alert and do not go up to one unless asked to. Dont smile because all animals, except humans show their teeth as a sign of agression, when people smile and show their teeth dogs may get the wrong impression. Always let a dog sniff your hand or ask the owner if you can pet it. Treats always win dogs over, but never put your face down to a dog.
First notice how the dog is reacting to your presents. Is he growling or is he sniffing the air and seems interested. If hes growling don't threaten the situation by walking towards the dog, or eye contact. If its ears are down and tail between the legs, hes scared and unsure. If his ears are straight up and his tail higher than his body, hes confident and could be trouble, especially if there is growling involved. If the dog seemed generally interested but mabe afraid, I would squat down, talk in a happy tone, put both front hands on the ground, make eye contact, but break it often, bring one hand up once and a while (like you had a sore paw)and yawn obnoxiously, mabe turn your back a bit. (be always aware of the other dogs movements) Wait for the dog to make the decision to come to you. Happy tones are unthreatening by breaking the eye contact your not challenging him. A paw lifted sends a signal of "This is a tense situation, I'm not a threat" Can we relax I'm nervous. The Yawn is also a tension releiver saying lets relax, I'm a bit nervous. Turning your back a bit shows your trust. Smiling is fine, most dogs do relize that we are not threatening them, humans do it alot when they pet dogs. Try some of these on your own dog........Set the stage your dog is laying across the room and you get eye contact now do the yawn, some dogs jump up and run over...Of course some dogs do nothing.