These days, the film rights to books expected to be bestsellers are snapped up even before the books are published. That’s the case with longtime Chicago resident and author Marcus Sakey, whose “Afterlife” — being published by Amazon July 11 — has had its movie rights acquired by Imagine Entertainment, Ron Howard and Brian Grazer’s production company.

Sakey, who will write the screenplay, confirmed the deal on Twitter, adding, “So excited about this. Ron Howard and Brian Grazer are literally the best in the business.”

As first reported by Deadline.com, “Afterlife” is a described as a “mind-bending science fiction tale, a love story that crosses parallel worlds,” and is being compared to the tone of such films as “Ghost,” “Inception” and “The Matrix.”

Previously, Sakey’s novel “Brilliance” was sold to Legendary Pictures for $1.25 million several years ago. David Koepp was drafted to adapt the book as a star vehicle for Will Smith, but the film project stalled as Legendary’s leadership went through a change.

“Brilliance” sold more than a million copies, and the film rights eventually reverted to the novelist, who since penned two more novels to complete a trilogy.