A hearing has begun into the case of a US teenager who allegedly killed his classmate because he was gay.

Larry King, 15, who self-identified as gay and wore feminine clothing, was shot in the head on February 12th 2008 during a lesson, allegedly by Brendan McInerney, his classmate at E.O. Green Junior High School in Oxnard, California.

Police at the pre-trial hearing said McInerney confessed to shooting King twice in the back of the head moments after the killing and repeatedly apologised for what he had done.

He was stopped by police officers as he walked away from the school talking on a mobile phone.

McInerney, who was 14 at the time, is being tried as an adult and has been charged with murder and a hate crime.

Classmates have said that King had a crush on McInerney and was known to dress in women’s clothes.

Yesterday, defence attorney Scott Wippert suggested that King had provoked violence by flirting with McInerney and wearing makeup.

McInerney allegedly told other students he was going to kill or injure King for humiliating him but they did not report the threats as they did not believe him.

Police found an unlocked stash of weapons at McInerney’s home that belonged to his grandfather.

They also found a DVD on how to shoot and drawings of swastikas in his room.

McInerney could be sentenced to 50 years in jail if convicted.The case continues.