Bernie Tiede walks into a court before a hearing granting his release Tuesday. (LM Otero/AP)

This is a moderately crazy story involving a mortician getting convicted of murder, spending 15 years behind bars, having his story told in a movie starring Jack Black and, ultimately, being released to move in with the acclaimed director of said movie.

Bernie Tiede, a mortician in Carthage, Tex., was sentenced to life in prison in 1999 for shooting a rich, elderly widow named Marjorie Nugent. Tiede and Nugent had met when Tiede, assistant director of a funeral home, helped plan her husband’s funeral. They struck up a friendship and he began working for her and traveling with her. But in 1996, he shot her and put her body in a freezer, where her remains sat for months before being discovered.

This story was recounted in a Texas Monthly article by Skip Hollandsworth that said the entire tale “was like an East Texas version of ‘Midnight in the Garden of Good and Evil.’ ” Hollandsworth found a town that loved Bernie Tiede and didn’t seem to care much for the the late Marjorie Nugent. This quote in his article summed up the reaction from people around Carthage:

“From the day that deep freeze was opened, you haven’t been able to find anyone in town saying, ‘Poor Mrs. Nugent,’ ” said city councilman Olin Joffrion, a respected Carthage insurance agent. “People here are saying, ‘Poor Bernie.’ ”

Hollandsworth’s article was the basis for “Bernie,” a movie starring Jack Black as the mortician and Shirley MacLaine as Nugent. (Matthew McConaughey played the district attorney who prosecuted Tiede’s case.) “Bernie” was directed by Richard Linklater, best known for directing “Dazed and Confused,” “School of Rock” and the “Before Sunrise” series, and the script was written by Linklater and Hollandsworth. The film was given limited release in 2012. It received very good reviews, earning a score of 90 percent on Rotten Tomatoes, but otherwise didn’t make a particularly big dent in the popular consciousness. (If anything, it was largely noted as one of those movies McConaughey made during his recent “Hey, Matthew McConaughey is making good movies again” revival.)

But even a relatively overlooked movie starring Jack Black, Shirley MacLaine and Matthew McConaughey is a movie starring Jack Black, Shirley MacLaine and Matthew McConaughey. That attracts some attention. A defense attorney in Austin named Jodi Callaway Cole, who saw the movie at a screening sponsored by Texas Monthly, said the movie raised some issues for her,  and she eventually took on Tiede’s case. Linklater, who said he believed Tiede was given “an extremely harsh sentence,” gave Cole the $2,000 in prize money the film won at the South by Southwest Festival.

This week, a judge agreed to let Tiede out of prison. Tiede had been sexually abused, something that wasn’t brought up during the 1999 trial; psychiatrists now say that the shooting was not premeditated and that he had a “disassociated” episode relating to his earlier abuse. They also say Tiede doesn’t present a continuing danger to society.

Linklater testified on Tiede’s behalf this week and even offered to let Tiede live with him in Austin. (This last part is what has caused a surge in new interest in Tiede’s story, because Oscar-nominated writer-directors typically don’t invite convicted murderers to live in their homes.)

Tiede was released on a $10,000 personal bond and given several conditions, one of which is that he does indeed have to live with Linklater. (He also has to seek psychological help and he can’t have any guns.) The director who made a movie that helped free Tiede said he didn’t have any reservations about letting Tiede move in, according to the Texas Tribune.

“Myself and others are determined to help him in any way we can,” Linklater said.