Tori Spelling's troubled husband Dean McDermott will appear on Tv drama series Csi: Crime Scene Investigation as a registered sex offender accused of murder.

The actor will hit the small screen as a guest on an episode, which will air this weekend (ends28Dec14).

Csi producer Don MCGill confirms the casting news, stating, "We're super excited to have Dean on the show. He plays a man with a shady past who is guilty of heinous crimes, but is he guilty of murdering an entire family? Only the Csis can get to the truth."

MCDermott has had a tough year - his efforts to save his marriage following a 2013 cheating scandal were featured on his wife's reality Tv show True Tori. He recently quit the programme, admitting it was "overwhelming" to air his fidelity issues in public.