If you have a picture sent from the offender to somebody else who is caused distress then the offence has been committed and there is no defence
There needs to be intent to cause distress. As you yourself posted
1)A person commits an offence if—
(a)he intentionally exposes his genitals, and
(b)he intends that someone will see them and be caused alarm or distress.
Posting unwanted dick pics is still an, erm, dick thing to do, but I fear it would be hard to prove that distress was intended.