Not sure if this is the inspiration for it, but I remember hearing a tale about a girl who was accused of witch craft or sorcery or devilry or some such. It was in a society that believed beauty was bestowed by the gods, and on her trial, the argument that won her the case was her disrobing and declaring that she could not possibly be guilty because the gods gave her this body.
At least, that's how I remember it. I couldn't find anything on this painting or the story online.