text: Image caption Defence lawyers argued that Ravi had not acted out of malice or hatred toward gay people
  
  A US student who used a webcam to secretly film his room-mate in a gay encounter has been found guilty of hate crime and invasion of privacy.
  
  Former Rutgers University undergraduate Dharun Ravi, 20, shook his head as the verdict was returned at a court in the state of New Jersey.
  
  His room-mate, Tyler Clementi, jumped to his death from a bridge in 2010.
  
  The case attracted national attention, including comment from President Obama, and prompted anti-bullying measures.
  
  Ravi was found guilty of 15 counts as a whole, including invasion of privacy and bias intimidation, which is a hate crime.
  
  He wasfound not guilty of several subpartsof the bias intimidation charges.
  
  While Ravi was not charged in connection with Clementi's death, which occurred shortly after the spying, the suicide was mentioned by witnesses during the trial.
  
  He will be sentenced on 21 May and could face up to 10 years in jail and possible deportation to India - although he has lived in the US legally since he was a young boy.
  
  Immaturity or malice?
  
  The trial heard that Ravi set up a webcam in his dormitory room in September 2010 and filmed Clementi kissing another man.
  
  Image caption Before killing himself, Tyler Clementi posted on Facebook, "Jumping off the gw bridge, sorry"
  
  Ravi then tweeted about it and tried to catch Clementi in the act again two days later.
  
  Prosecutors said about half a dozen students saw the video.
  
  Days later, Clementi leaped to his death, posting a status update on Facebook saying: "Jumping off the gw bridge, sorry."
  
  The trial heard that Ravi had planned to "expose" Clementi's activity and that he acted purposefully and maliciously.
  
  Prosecutors said there was abundant proof that Ravi had a problem with Clementi being gay.
  
  But the defence argued that Ravi, a first-year student at the time, was not homophobic and was simply behaving like an immature "kid".
  
  One of the many witnesses called during the trial included the man seen kissing Clementi, identify by his initials MB.
  
  Ravi did not testify, but jurors watched video of police questioning him after Clementi's death.
  
  Spotlight on gay suicide
  
  Clementi's death was one of a string of suicides by gay youths, and the case received national attention.
  
  Prosecutors were barred by the court from arguing that the spying had led directly to Clementi's death, while defence lawyers were prevented from saying Clementi had killed himself for other reasons.
  
  Clementi requested his room be changed before his death, according to testimony, and he loaded Ravi's Twitter page 38 times during the last two days of his life.
  
  One of Ravi's tweets said: "Roommate asked for the room till midnight. I went into molly's room and turned on my webcam. I saw him making out with a dude. Yay."
  
  In the wake of his death, New Jersey legislators passed an anti-bullying law, and Rutgers changed its housing policies in attempt to make gay students feel more comfortable.