Leonardo da Vinci's art provokes rapture. His paintings from his time in Milan, currently on show at the National Gallery, are sublime. The exhibition closes next week, so if you have not yet seen it, despite the crowds, queue for a ticket. If you don't, you will miss a truly exquisite and cathartic experience. The exhibition leaves you in no doubt of his absolute genius. How could a mere mortal produce works of such beauty?
But this is not the only dilemma we are left with. There are other more mundane questions. For someone of such extraordinary ability, why so few paintings? More troubling, what on earth was Leonardo doing working out of Milan, a powerful state but hardly a powerhouse of the artistic cutting edge? He was a Tuscan. His home was Florence, the undisputed centre of artistic innovation and cultural ideas in Europe. But despite this at the beginning of the 1480s, he left Florence for culturally conservative Milan. There, under the patronage of its ruler, he produced the stunning works which are the story of the National Gallery's exhibition, but the viewer cannot help but ask what more would have been produced had he remained in the hothouse of Florence.
It is known that Leonardo was gay. His emotional and sexual motivation was driven by a desire for male beauty. What we would call homosexuality was a criminal offence in Florence. Conviction could carry the death penalty. What is less well known is that Leonardo was arrested not once, but twice for sodomy. At the time his brilliance was just being recognised. As it happens the prosecutions failed, permitting Leonardo to re-emerge as Europe's greatest artist. Nevertheless, the consequences of his arrest on him and his body of work should not be underestimated.
The scandal unfolded as follows. In the early morning of 9 April 1476 an anonymous informer dropped into the tamburo, a letter box on the wall of the Palazzo della Signoria in Florence, a paper accusing five men of sodomy. Like some Renaissance vice ring, the writer fingered a 17-year-old apprentice called Jacopo Saltarelli, who "consents to please those persons who request such wickedness of him". Dozens of men are hinted at, but the paper names only four: a goldsmith, a tailor, a young man from one of Florence's most powerful families, Leonardo Tornabuoni, and one Leonardo da Vinci. Leonardo would have been 24 years old, still living, according to this scrap of paper, in the workshop of his master Andrea del Verrocchio.
Newspapers, if they'd existed, would have had a field day that morning. Leonardo may have been the son of a respected city notary, but the young Tornabuoni was the real celebrity: a close relative of Florence's de facto rulers, the Medici, he would have been a prime target for political embarrassment. This scandal was too good, and the Medici's enemies might have been expected to make much of it. They might even have been behind the anonymous accusation. The fact that the young and brilliant da Vinci was implicated only gave credence to the story: Jacopo Saltarelli, an attractive youth and goldsmith's apprentice, no doubt acted as a model for artists, posing naked for a gifted painter's pen.
It isn't difficult to imagine what would have been going through these young men's minds. Taken from their beds and summoned under guard to interrogation, it would have been a shifty affair: no one really wanted to know; shame-faced downcast mumbled denials aside, the city's magistrates, Medici hand-picked men, hoped to hush it all up before morning. Finally the five were released on condition that no further charges appeared. But the accusation would have been known by the time Leonardo returned to his master's workshop that day. Many of his sketches show the ugly side of public shame, grotesque men and women whispering, sneering. All he could do now was hope it would blow over.
Then two months later, on 7 June, another anonymous paper repeated the accusation. This had been a condition of the Saltarelli Five's release, it could have led to a more intrusive investigation - thumb screws, dislocated shoulders, Leonardo's father watching from his office in the Chief Magistrate's palace - but as the accuser had not come forward to identify him or herself, the magistrates dismissed the case on this technicality. It was more a matter of not proven rather than acquittal.
Leonardo was deeply troubled by all of this. Thirty years later he would write in his notebook of his fellow Florentines,"when I made God a child you put me in prison, now I have made him grown up you will do worse," - cryptic jottings, but suggestive of some lingering resentment towards the people of his home town. After the Saltarelli affair he disappeared. We then hear of him in Florence again in 1478, now an independent painter of prestigious commissions. However much the charges were behind him officially, he couldn't or wouldn't finish these. Instead he left Florence abruptly and travelled to Milan.
We're told he came north not as a painter at all, but as a musician, and maybe he was looking for a new, more secure life away from the turmoilof Medici Florence. Did memories of the shame of that night in 1476 drive him away? Did he re-invent himself in Milan rather than remain that defendant in a celebrated case of sodomy?
In many ways Leonardo was one of the first high-profile victims of anti-gay laws. Thanks to the shenanigans of the Medici, his genius was saved, but we might have been left with very little from him at all. He could have been a footnote in art history, a young artist who had shown huge talent but was broken and shamed by arbitrary criminal laws, executed even. How close we were to losing him. Leonardo, the convicted sex offender, would not have painted the Mona Lisa.
Kevin Childs is a member of the British Museum/Courtauld Graphic Arts Group