Prostitution is illegal, unless someone’s filming it!
When homosexual acts were legally considered "unnatural" and illegal, same sex porn was not outright illegal or "obscene".
Yet when the age of consent is under 18 (16, 17) or bestiality is legal (and it is/was legal in a number of states) you could engage in the acts, you just couldn't film/photograph them.
None of the distinctions make sense.