A New Brunswick man has received an automatic life sentence after he switched his plea on Thursday to guilty of first-degree murder in the death of his newborn son.

Rodney Miller, 28, of Moores Mills, near St. Stephen, took the unusual step after the Crown prosecutor's closing arguments.

Defence lawyer Joel Hansen told Court of Queen's Bench in St. Andrews that he had discussed Miller's options with him during the recess and Miller decided to change his plea from not guilty to guilty of first-degree murder.

"He wanted to come clean on the whole thing," Hansen told reporters outside the courtroom.

"Obviously anybody who had observed the videotaped confession of Rodney Miller will realize that it was quite obvious that it was not sort of a passion play. It was something that had been thought on, and deliberated upon for at least three months prior to the event and that's sort of classic first-degree murder," he added.

Justice Hugh McLellan said that the evidence was blatant that Miller did kill his baby. He said Miller's clear and plain confession in his videotaped statement to police speaks for itself.

The judge described the evidence in the case as distressing.

Miller told police he stabbed his son through the heart, wrapped him in a teddy bear blanket, and hid the body under the corner of another house on his property that he was fixing up.

After he drank a few beers and smoked a joint, Miller took the boy's body out to nearby train tracks, poured gasoline over the infant and set him on fire.

"It was, I think, readily apparent that Mr. Miller had a serious uphill row to hoe today to get over the mountain of evidence against him," said Crown prosecutor Jim McAvity.

Still, the sudden change of plea took McAvity and fellow Crown prosecutor Randy DiPaolo by surprise, he said.

Crown refused plea

Miller will not be eligible for parole for 25 years.

Miller had offered to plead guilty to second-degree murder earlier this week. but the prosecutors refused to accept the plea.

On Wednesday, the court was shown a videotaped interview with Miller where he told police the baby's mother had threatened to commit suicide if he didn't get rid of the baby.

An RCMP investigation concluded the baby was born some time between Jan. 5 and Jan. 22, 2009.

Miller previously pleaded guilty to a charge of disposing of the body of a child with intent to conceal the birth, but the judge issued a stay on that charge.

The baby's mother, Sarah Russell, 20, is charged with manslaughter and being an accessory after the fact in her baby's death.

She is scheduled to be in court for a preliminary hearing on Nov. 16.

The prosecutors declined to comment on what, if any, effect Miller's plea to first-degree murder will have on Russell's case.

"That's a separate matter, it's still before the courts … and we don't want to get into discussing that at this point for fear of prejudice to that case," said DiPaolo.