See a doctor. If you're in that much pain, then you would be best served by seeing a doctor or a dentist who specializes in tmd (temporomandibular disorders). In the mean time, try a very soft, non-chewing diet, apply moist heat to your jaw or face, and take a non steroidal anti-inflammatory over-the-counter medicine such as Ibuprofen or Naproxen (aleve).
Cannot open mouth. Several things can cause this: tmj, inflamed gums around wisdom teeth, bruxism, trauma and number of other things. You need to seek professional help, i suggest that you start with visiting your dentist for the initial evaluation. Your dentist may chose to referr you to oral surgeon , or TMJ specialist.