The Scottish actor is no stranger to detective drama. His portrayal of Ian Rankin's Rebus was widely panned and he was replaced in later versions by Ken Stott.

The new show is billed as "an all-encompassing parody of every police procedural ever written".

It follows DCI Cloth, described as "a maverick, heavy-drinking loner", and his sidekick played by Suranne as they encounter arrogant TV chefs, vampish pathologists and a devious killer.

Charlie is part of the team writing the screenplay based on a story by novelist Boris Starling.

He said: "After you've seen A Touch Of Cloth, you'll never be able to watch another detective show again. Not because it's a devastating pisstake, but because you'll have smashed your TV to pieces in a disappointed fury."

Charlie, who co-wrote the 2005 sitcom Nathan Barley, is best known for writing his Screen Burn column in the Guardian and for presenting Screenwipe - a satirical look at television - on BBC4.