Making a new Star Wars movie can be like gaining access to a toy collection that has been amassed over four decades. For the creators of Rogue One, a film designed as a narrative lead-in to the original Star Wars, it was a chance to play with characters, vehicles and locations sacred to this series.
But as they revisited the 1977 George Lucas movie that started the Star Wars franchise and gave fresh screen time to some lesserknown heroes and villains, the staff of Lucasfilm and Industrial Light & Magic faced artistic and technological hurdles: most prominently, using a combination of live action and digital effects to bring back the character Grand Moff Tarkin. This nefarious ally of Darth Vader and commander of the Death Star was played by Peter Cushing, a horror-film actor who died in 1994.
In doing so, they waded into a post-modern debate about the ethics of prolonging the lifespan of a character and his likeness beyond that of the actor who originated the role.
The effects experts and storytellers behind Rogue One, which was directed by Gareth Edwards and written by Chris Weitz and Tony Gilroy, said they gave careful thought to these issues and were guided by their reverence for the interstellar epic.
"A lot of us got into the industry because of Star Wars and we all have this love of the original source material," said Mr John Knoll, chief creative officer at Industrial Light & Magic and a visual-effects supervisor on Rogue One.
In his view, the character effects are "in the spirit of what a lot of Star Wars has done in the past".
Some vintage Rogue One characters were easier to conjure than others. General Dodonna, a rebel officer from the original Star Wars, was simply recast. He was played by Alex McCrindle in the first film and Ian McElhinney in the new one.
Tarkin presented considerably greater difficulties, but the filmmakers said it would be just as difficult to omit him from a narrative that prominently features the fearsome Death Star - the battle station he refuses to evacuate amid the rebels' all-out assault in Star Wars.
"If he's not in the movie, we're going to have to explain why," said Ms Kiri Hart, a Lucasfilm story development executive and Rogue One co-producer.
For principal photography, the film-makers cast English actor Guy Henry (Harry Potter And The Deathly Hallows Parts 1 and 2, 2010 and 2011), who has a build and stature like Cushing's and could speak in a similar manner.
Throughout filming, Henry wore motion-capture materials on his head so his face could be replaced with a digital re-creation of Cushing's piercing visage.
Mr Knoll described the process as "a super high-tech and labour-intensive version of doing make-up".
"We're transforming the actor's appearance to look like another character, but just using digital technology," he said.
Lucasfilm and Industrial Light & Magic said their re-creation of Cushing was done with the approval of the actor's estate. But the technique has drawn criticism from viewers and writers.
The Huffington Post called it "a giant breach of respect for the dead" and The Guardian said it worked "remarkably well", but nonetheless described it as "a digital indignity".
Mr Knoll said he and his colleagues were aware of the "slippery slope argument", that their simulated Cushing was opening the door to more and more movies using digital reproductions of dead actors.
But he does not imagine that happening.
"This was done for very solid and defendable story reasons. This is a character that is very important to telling this kind of story."
Mr Knoll added: "It is extremely labourintensive and expensive to do. I don't imagine anybody engaging in this kind of thing in a casual manner."