Mercutio shoots his gun into the air to get Romeo's attention.
Throughout the beginning acts of the play, Mercutio gets increasingly frustrated with Romeo's seclusion and secrecy. The lengthy close ups of Mercutio's face as Romeo walks away from him and his friends to go meet with the nurse help the viewer to see his frustration. We also see this when Romeo jumps out of the car when the boys are leaving the Capulet party.