@Silly rabbit: this is not true! iMacs support video out AND IN.
It is called "Target Display Mode":
It should work, because the iMac 2011 can Output a Display-Port signal (and even "import" a Thunderbolt Video signal!)
Ok, I'm sorry, you have an 2004 iMac, it won't work