There's often not. In the last couple of decades, there have been exhibitions on the Victorian Nude st Tate Britain, the Art of Seduction at the Barbican, there was one at the British Museum on something Japanese that was erotica paintings and dildos (can't remember the title), and any exhibition with Jeff Koons' work in. Also another Tate one on British cartoons which had a separate section you were only mean to go in if you were over 18.
Most of those exhibitions included at least an element of porn, and had quite deliberately crossed the art/erotica/porn line as a way of looking at that very question asked in the thread title.
The catalogue for the Victorian Nude had a close-up of an Alma-Tadema Greek woman holding an urn - there was a strip of most paper cover her nipples, because you can't show female nipples like that in public, however well-painted in oil on canvas...
Prior to photography, paintings and prints and so on were the only images available to people, so it did fulfill the role of porn, if you define it as a picture of a nude or semi-naked body with the purpose of arousing the viewer. And as soon as photography was available, it was used extensively for porn, not just family portraits and landscapes.
I would always say that Courbet''s l'Origine du Monde is art but a photo of exactly the same subject in a top-shelf magazine would be porn, and other than the medium, it's the same thing.
Basically, it's not a line which can be crossed; it's a Venn diagram with a massive intersection, and just where the boundaries for each set lies will be defined differently by different people.
I am also mildly disturbed about how extensive my knowledge of this subject is...