If you undress someone in your head that’s private but you don’t have the right paint, photograph or generate and share it in public
The problem comes with dissemination and intent.
Paint a nude and share it on your art website, ok - post it on the school’s chat group and send it to the models friends and family after you breakup ? Not ok
I'm not familiar with that social precedent being set.
Plenty of nude paints/statues/etc were made posthumously, and tons of them are now permanent monuments in public museums.
Few gave permission, but we as a society seem to think that's okay given our widespread dissemination of the art.
also the motivation matters : these works weren't made for reasons of malice, generally speaking.
This will open up all sorts of debates about speech, etc. But that's another topic of discussion for me.