In a video I'm watching (requires register), it has this setup.
[FEN "r3k2r/pp1qn1pp/2p2p2/8/3P4/5N2/PP2QPPP/2R1R1K1 b kq - 0 1"] [startflipped ""]
The instructor says:
The king cannot escape, he cannot castle kingside or queenside, because of the white's pressure on e7 [...]. Black wants to escape this pressure by castling by hand.
I don't understand why can't black castle. It won't castle from, through, or into check. Why is it?