Yea, Thich Quang Duc... He didn't even flinch. I think some other monk offered to be immolated, but he rejected.
I don't know how he did it, but in Buddhist meditation (and Hinduism too) there are the jhanas, states of absorption or concentration. They are very interesting to read, like the states of infinite space, infinite consciousness and such...
I only got into meditation because of taking LSD once, where I had a glimpse of these things but outside of the drug, I couldn't replicate it.
We may see this as a suicide, but Thich Nhat Han, former Zen Buddhist teacher said this was an action born out of compassion.
Otherwise I don't think he would be able to do it, if his mind wasn't inclined in the right direction. He did it for his community (I think the buddhist community was being oppressed, I don't remember the story well).
There are similar stories like the one the early life of Sri Ramana Maharashi, where people had to basically feed his body while ants were eating his skin, while he was just completely unaware of the body during meditation.
Because in some higher jhanas/absorption states, you lose awareness of your body. Supposedly as I never experienced that...
According to devotees of Sri Ramana, when he had cancer covering his entire arm, he lived as if it didn't even exist. Even had surgery to remove tumours without anesthesia, even the doctor bowed in respect.