Bhartruhari was so much immersed in romance and sex, that he wrote 100 stanzas on 'the art of romance and sex', now famously called 'Shrungara Shataka'. All the stanzas are on sensuality and sexual pleasure.
https://www.google.com/search?q=Shrungara+Shataka
Author
https://www.google.com/search?q=Bhartruhari
Bhartruhari realized the fleeting nature of the pleasure from worldly objects, he wrote a poem about the incident which changed him in his Niti Shataka. (100 stanzas on Moral conduct)
"(She) whom on I contemplate, is not passionate for me, she loves another;
that whom she loves, loves another;
One whom he loves, loves another.
Refuse (disdain to) that woman, that man, Cupid, me."
Deep Vairagya (dispassion) arose in him, he gave up the desire for his wife, realizing his mistake he brought his brother back and crowned him, renouncing the world he lived rest of his life as an ascetic. Bhartruhari wrote Niti-Shataka and Vairagya Shataka during his later years.
https://www.google.com/search?q=Niti-Shataka
https://www.google.com/search?q=Vairagya+Satakam