From The MailBag: Licensing for Film and TV:
I'm making good on my promise to answer some leftover questions from the Monster Call.
I have a student at an university who wants to use a couple of our songs for her film. She will be giving us the credits on the film but no monetary exchange. What time of contract do I have her sign? Is it a mechanical license? The songs are copyrighted and the songwriter is a member of BMI and ASCAP.
Great question. When getting one of your songs into film or television, there are actually TWO licenses you'll need to sign. The first is a sync license, which is the agreement to pay the writers of the song (or whoever actually holds the copyright on the song). The second license is a master use license, which sets the compensation for the owner of the recording (usually the record company).
You can find some more jumping-off-point information here, and feel free to add links to other useful resources in the comments.