I had a DVD in my iMac that would not mount, and would not eject. After Googling around and trying various methods, I ended up calling Apple Support, and got this tip that I had not run across in my searches:
Boot the iMac while holding down the Option key to get to the boot menu, where the start up drives are displayed. Press and hold down the Eject key on the keyboard, and the stuck disc should eject.
This tip worked great for me; I hope it's helpful to others.
[robg adds: The topic of stuck media has been quite popular here in the past. In an effort to turn today's tip into a one-stop reference for all the potential solutions, here are the methods covered in past hints:
Mac OS X Hints
http://hints.macworld.com/article.php?story=20100207111453283