In Mike Newell’s Prince of Persia: The Sands of Time (out soon on Blu-Ray &DVD), rogue Prince Dastan (Jake Gyllenhaal) safeguards a magical and sought-after dagger that can reverse time. We look at a few of the major effects sequences by Cinesite, MPC, Framestore and Double Negative, & the previs work by Nvizage. VFX supervisor : Tom Wood.
Prince of Persia is released on DVD and Blu-Ray Sept 14th Buy it here from Amazon & this helps support fxguide
Cinesite youthens Kings, adds to cities
Cinesite’s key shots – 285 of which are in the film – included youthening effects, digital city extensions, a Hassansin attack sequence and a digital lioness. For flashback shots featuring Nizam (Ben Kingsley), Cinesite showed the director a proof-of-concept to de-age the actor 30 years younger.
“It’s a 2D effect but it relies on good data being gathered during the shoot,” explained Cinesite visual effects supervisor Sue Rowe. “We cast two youth doubles who stood in straight after the take with the original actors so we could take high-res digital stills in the same lighting conditions. We added darkened eye lashes and thickened hair, and removed wrinkles and age spots. These were then tracked onto the actors’ skin using our in-house software Motion Analyser, which basically sticks the new skin on top of the old skin - like a digital skin graft.” A similar approach was used for the death of King Sharaman (Ronald Pickup), who is poisoned by snake venom, using a combination of 3D veins and skin graft, with smoke done in Maya Fluids.
A chase sequence in the city of Avrat involved 3D set extensions, overseen by Artemis Oikonomopoulou, with added 3D arrows, 2D arrows, matte paintings, face replacements, wire and rig removals and the addition of general atmosphere – a typical approach to Cinesite’s city work, which also involved work for shots of a young Dastan being chased through Nasaf. “Like Lego building blocks, we had a number of bases, a number of towers, and some domes and minarets of various sizes,” said Rowe. “Combine this with a selection of doors and windows and you have infinite variety for your 3D.”
“Only about a third of the city was real,” continued Rowe, “but it was definitely worth shooting in the location. You have to experience the light and atmosphere of Morocco (where exteriors were shot) to get the best out of your scenes. The mountains were blue in the shade and red in the sunlight.
In fact, that was the challenge we encountered when the shoot was over and we had to match studio shots with locations shots. The studio lighting just didn’t have enough depth. Mat Kasmir, our 2D lead, did a great job re-sculpting the shots to give them an authentic look.”
Dastan battles the Hassansins, a group of evil warriors, in a sequence at the Hidden Valley and Temple of Water. Cinesite augmented weapons to include 3D swords, daggers and whips, with some re-speeds done in Motion Analyser. “We choreographed the sequence with Artemis and our animation supervisor Quentin Miles,” said Rowe. “Although we shot references of the whips on set, the stunt team only had a handle in their hands so we had some freedom as to where the whip would fall.” A mysterious cloud and sand trails surrounding the arrival of the Hassansins was realised in Houdini.
MPC plans a town
Alamut, a sacred desert city housed behind high walls with a central Golden Palace, is invaded early in the film by the Persian army. Dastan finds himself caught up in the invasion and it is here that he discovers the Dagger of Time and meets Tamina. Shots of the city and the invading armies were realised by MPC under visual effects supervisor Stephane Ceretti. Production designer Wolf Kroeger supplied concept art to MPC and worked with previs artists from Nvizage to establish layouts and the basic form, size and scale for the buildings. “Tom Wood then gave us a book called The Orientalists,” said Ceretti. “It’s a book about painters from the 18th century with lots of really nice atmospheric renders and lights and silhouette-type paintings.”
MPC sent a stills photographer and location manager to the north of India for three weeks to collect reference, based on initial photos provided by Tom Wood. Production shot parts of the invasion sequence on built sets in Morocco and at Pinewood Studios, which were both LIDAR scanned for reference. To create the city in 3D, MPC developed a new layout tool they called Town Planner. “Essentially, it allowed us to design the city and organise it by the type of buildings and do many iterations really quickly,” explained Ceretti. “We had a library of buildings we had modelled and textured based on the stills reference and photogrammetry techniques and could place certain ones in pre-determined areas. So for a poor area of the city we had certain buildings and then a richer area would have different ones.”
Drawing on the underlying structure of MPC’s existing proprietary ALICE crowd system, Town Planner gave MPC an initial pass at the city that could be augmented with other surrounds like gardens, streets and trees, as well the surrounding mountainous environment. “Buildings are pretty much a crowd that doesn’t move,” noted Ceretti. “We already had layout tools for the crowds – why not make it similar? In the end, we stripped out everything we wouldn’t need in terms of simulation of crowd motion and just used it for layout, but it was still a huge render so we had to split up parts of the city and bake out different renders in RenderMan to make it possible.” In the end, this amounted to about 20,000 buildings and 180,000 props – things like canopies, piles of wood and pots. For shots of the invading army and other crowds in the city, the ALICE software was used to generate 10,000 agents made up of soldiers, flags, citizens, horses and camels, and then integrated into the city shots. Further projection work was done in both Shake and Nuke to allow for 3D space adjustments and other details to be added, along with the layering of atmospheric dust, mist and rays of light.
One of the key shots seen in the Alamut invasion involved a sweeping camera move around Dastan as pauses atop a gate about to jump into the city. A plate of Jake Gyllenhaal on a beam was shot against greenscreen at Pinewood. “Firstly, we had to change the camera move from what was shot at Pinewood,” said Ceretti, “because the the camera couldn’t go far enough away from Jake in order for us to see the city. So we re-projected him onto a digital double so that we could pull away a bit further.” MPC modeled the gate based on the LIDAR scan of the Morocco set, with a CG city in the background. Further elements of the shot included CG armies surging towards him and smoke and atmosphere added into the shot. “Also, the version in the movie has been sped up in the edit – which worked great – but the version we worked on was 1800 frames which was actually a pretty slow move around Jake.”
Framestore’s snakes and sand room
Resting at an oasis at one point in the film, Dastan encounters the Hassansin Vipers, six foot long snakes used almost as ninja weapons by his attackers. Dastan successfully dispatches the Vipers using the Dagger’s powers in the fight sequence, which called for burrowing shots, extreme close-ups, slow-motion actions and even a snake dissection. Framestore was responsible for designing the overall look of the Vipers. “The brief was what kind of snake can you keep up a person’s sleeve, get out of a costume very quickly through the arm hole, and then what looked really cool and dangerous?” said Framestore visual effects supervisor Ben Morris. “Although they’re only two metre long vipers, Tom Wood wanted them to have quite gnarly scales. Some vipers have horns on the front of their scales. There’s also some scale risers over the eyes. So we wanted them to look like a military tank that stormed through the desert.”
FX lead Alex Rothwell developed a custom Maya plugin that could create geometry scales on top of a very simple tube used as the animation rig. “In previs and animatics,” said Morris, “we realised that although you think of scales as quite thin, they actually change the diameter of the snake quite significantly. The plugin allowed animations to control scale distribution, the look of the scales, the inclination – similar to a feather system. The scales were also there for the animators to see rather than only appearing at render time.”
Using a mini-library of scales, artists could place paler or flatter scales at the end of the tail and then smooth belly ones for underneath the Vipers. “Then as we came up to the head, we knew we’d be doing some big hero shots, so we actually transition from the procedural plugin to a set of hand modeled scales done in Zbrush or Mudbox that started just behind the back of the jaw,” said Morris. “The key to all of this was that scales don’t stretch. What we wanted were very hard scales and the skin underneath needed to stretch. Using those techniques we allowed our snake’s mouth to open and the skin underneath to be exposed and revealed whilst keeping the integrity of the individual scales.”
For a slow-motion and freeze shot of a Viper about to attack, the look of the inside of the mouth also became important. “Tom wanted that translucent raw chicken fish look to the mouth which was almost horrible and pukey with quite a high spec or gloss on top,” said Morris. Another scene called for Dastan to cut one of the Vipers open. “For that we used all sorts of custom body animation rigs. We had an inner tube of a bike tyre jammed full of raw salmon and tuna with blood and other entrails with two corks stuffed in the end. Every time it cut open it squirted this hideous smelling fish stuff all over Ben Kingsley on a very hot set. Although we had the tuna sushi surprise inside, we actually ended up replacing most of that with CG flesh because we needed it to move with the snake’s body accurately.”
Towards the end of the film, Dastan and Tamina find themselves at the edge of a mighty underground chamber. As they negotiate their way across the room, the floor begins to dissolve and form a massive sand whirlpool. This ‘Sand Room’ sequence was almost entirely devised by Framestore after being asked to come up with a bridging scene for the film. “They came to us on Friday lunchtime and said they were meeting on the Monday and that we had to come up with how to fill in two to four minutes of screen action, including parkour, potentially sand and subterranean stuff,” explained Ben Morris. “We immediately ran down to the pub and thought, ‘Oh my God, what are we going to do?’. Pablo Grillo, the animation supervisor, and Kevin Jenkins, who’s our visual effects art director, took our initial ideas and turned them into a quick previs and animatic. The basic scheme was that we were thinking of an hourglass that drains – the whole structure of the room had to feel quite odd. It’s very deep and wide but shallow in height with huge buttress walls, because it’s a trap mechanism.”
Kevin Jenkins was then seconded to the production art department for the next few weeks to work with production designer Wolf Kroeger. Although two weeks had been originally planned to film the sequence at Pinewood, only four days remained available at the end of the shoot. On set, Jake Gyllenhaal performed actions on a ramp along with some pedestal and tower pieces against greenscreen. “One thing that became clear immediately,” noted Morris, “was that the sand slope that we had built wasn’t great for sliding and that it was a pain to re-set and almost dangerous in terms of getting sand in people’s eyes. So scrapped that idea and put Jake on a slick MDF wooden slope that he could slide down quickly.”
After the shoot, Framestore post-vized the Sand Room sequence for nearly six months. “It had about 40 cuts and the sequence went from 250 shots down to 50 and up to 120 and down again,” said Morris. “Ultimately we kept in the main things they were after which was parkour, the sand flow and the hero backflips at the end. The majority of it ended up being CG. We did do a large practical shoot where we poured huge buckets of sand gushing through archways, over lumps and down a slope flowing very smoothly. That became good reference for our CG render tools.”
Initial work on the sequence began with animators working on a very simple nurbs or poly plane. “We would cut out the Dustan elements and they would then use virtual cameras to slightly distort the angle on the shot performance,” said Morris. “They based the entire scene in a very primitive world where we had a flow plane and then they did very basic animation timings for the destruction and collapse of the architecture. Once we had the whole thing laid out as a post-viz, we had key animation beats. There were key moments, like when the sink hole originally collapsing underneath him or him sliding down on the plinth. Then he slides under what we called the Buster Keaton wall – the classic ‘you think it’s going to squash him’ moment. The wall collapses and he’s saved by an archway. Then there was the ‘sand fall’ in the chasm of death scene at the end. Once those had all been approved in terms of general structure and choreography, we then went in and designed in all of the room and the details after the event. That was a terrific template for the effects artists. We knew what shots we could achieve with the live action elements and what needed to be digital doubles.”
TDs ran very simple simulations over the surfaces of the low-res geometries for the main structure of flow. At the same time, artists ran rigid body simulations for the falling architecture. Both tools were brand new for Framestore. “We wrote a very high speed interactive RBD solver based on the Bullet open-source physics library toolset and that was integrated into Maya,” explained Morris. “It allowed us to simulate tens of thousands of destroyed geometries all at the same time.” For the sand flow, Alex Rothwell wrote simple dynamics tools that would respond to the curvature of the low-res geometry and objects that were in the path. “In both of these simulation tools, we decided we wanted fast turnarounds and avoid huge simulations for the sand and we wanted a multi-layered solution for the RBDs. What that would allow us was lots of iterations to change things rather than sending something off to the farm for a week and then finding that it didn’t do what we wanted. So all the tools were built in a very modular fashion like that. We could generate different ways to perturb the flow of sand. We had triggering systems for the RBDs that could shatter. You’d start off with larger blocks of maybe ten fused together bricks that could then shatter into individual bricks and then into smaller pieces, depending on the forces of the impacts.”
Rothwell also wrote a cache format called Pcache that allowed Framestore to generate low resolution particle simulations for the sand. “It gave us lots of different layers in a universal cache format and then that would be ported to RenderMan which would upscale the number of particles,” said Morris. “It had a Python binding so we could actually script the way in which 3D particles stamps were created for the final render. That then passed into a RenderMan DSO that allowed us to render two billion particles in certain shots. It’s an incredibly modular tool and the other thing it allowed us to do was let our Maya and Houdini artists generate simulations of our flowing sand in a common file format that could passed to our lighting TDs and render people.”
For the final look, multiple layers of sand simulation were combined. “Once we got the speed and pace and shape of the flowing sand to where we wanted it,” said Morris, “we’d then do special collision simulations on the walls or on bricks that are in the flow. We’d have splashes from all of the rigid bodies that landed. Then you had airborne sand and dust. Each of the architecture tiers had sand falls so that when it lent over and crashed you’d get sand pouring off it there as well. In order to get some sort of volumetric niceness to our sand – one of the reference pieces we looked at in our research was that dune dirt buggy photos where you see people surfing down dunes where they kick up huge plumes of sand. We realised that although it’s a particulate medium, it looks like very beautiful sculpted forms with very subtle internal lighting and self-occlusion. That’s not something you can get out of the standard diffuse lighting that you might throw at particles.”
A further tool written by Rothwell involved voxel occlusion calculation on the large sand simulations. As Morris explained: “It actually came out of another company tool that he wrote for Aslan’s hair in Narnia where we wanted self-occlusion inside the mane of Aslan. He brought that tool across into the Pcache render pipeline for our sand. Occlusion is something that we’ve used for years – say ambient occlusion – but not in particle simulation. As soon as we switched this on, we suddenly got all this beautiful detail in what would normally be shadow. All of the internals and undersides of sand splashes particularly in the sand fall.”
For compositing, Framestore relied initially on Shake but then moved over to Nuke during production. “Nuke has a great native 3D camera and we could do a lot of re-lighting and could lay in an awful lot of 2D elements accurately into our 3D scenes,” said Morris. “So all of our rigid body and certain elements of our sand simulation could be imported into Nuke directly which allowed our compositors to do accurate representation of multi-planing 2D dust elements. We’d put through some digital matte painting touch-ups if necessary and then the compers would get all of those layers. Also, Kevin Jenkins had painted such beautiful concepts for each of the key beats that our lighters knew very early on what they aiming for in terms of lighting. The lighting TDs, headed up by Rob Allman and Neil Weatherley, along with Laurent Hugueniot, the CG supervisor, they got it pretty bang on in terms of lighting. So the compers got down to the detail of integration which was often very tricky. We did use a library of 2D elements to mix some real elements with CG. They were huge shots and they completely turned our pipeline on its head. The client always said, ‘More is more, Ben. Never forget, more is more.’”
Dneg delivers the Dagger and the Sands of Time
Double Negative, under visual effects supervisor Mike Ellis, handled the Dagger of Time and final Sands of Time sequences. After discovering the Dagger in Alamut, Dastan soon learns its secret powers. Pushing in a button on the dagger handle causes time to stop and rewind, except for the person holding the dagger who can see the events unfolding. “Originally, Tom Wood’s idea was to think of them as open shutter photography effects like a slitscan or long motion blur,” said Ellis. “Of course, it had to be CG but he wanted it have a very photographic feel.”
The final technique ultimately relied on event capture using multiple cameras to capture live action of the actors that could then be re-created as a CG version of the scene – a technique that had seen some initial development on Quantum of Solace. “Using nine cameras,” explained Ellis, “we could effectively cookie cut 3D shapes by roto’ing forms in each shot and combine them into a wobbly mesh that we could then project the live action back onto. We could create new camera moves with full original photographic textures with all the right lighting.”
The Dagger of Time scenes – four moments of rewinding throughout the film – were shot on a series of up to nine 35mm cameras on 5219 Kodak VFX film stock for minimum grain. As each scene was set at night, director of photography John Seale boosted the lighting for the rewind setups immediately after the forward action scenes had been filmed. “It meant that the actors were all in the right frame of mind and knew exactly what they’d just done,” said Ellis. The scenes were shot mostly 48 frames per second and sometimes down to up 72.
Double Negative surveyed each set for the rewind scenes so that they could be re-constructed in CG. The bedroom chamber scene, in particular, included numerous intricate details. “We were expecting it to be quite a clean and empty room,” recalled Ellis, “but when we got there it was incredibly ornate with goblets, food and candles! All of this had to be replicated.” Visual effects editor Derek Burgess assembled basic edits of the multiple camera footage, roughly blocking out timings for where the CG could be performed would go by mixing between cameras. “We could then take in a minimum amount of footage and start roto’ing each camera for each scene from each individual camera,” said Ellis. That allowed Double Negative to start its ‘volume carving’ technique, where the roto from each camera was projected to form a cookie cutter shape of a human being.
Although this shape was quite a basic and wobbly human form, artists could effectively shrink-wrap the form to refine the mesh. “We would compare two sets of cameras at a time and where they land on the wobbly mesh we could work out the difference and retract them,” explained Ellis. “What we end up with is a good clear form in 3D space on which to project our textures from the nine cameras. We also had to create basic digi double which we could then track very closely to our wobbly mesh.”
The rewind scenes also featured swirling sand effects as the characters broke apart and reformed, accomplished using Double Negative’s proprietary fluid dynamics system Squirt. “Because we had our characters as full 3D forms, we had textures for particles that you wouldn’t even normally see behind the characters,” said Ellis. “When they started to break apart, we weren’t getting just cheated projections or particle colour or tone. We were getting real textures that were being thrown around.” Up to 20 layers of particles were ultimately composited in full CG comps of 30 to 40 passes using Shake.
For the final sequence, Dastan and Tamina find themselves in a massive cavern with a giant sand glass in the middle – the Sand Glass of the Gods. Realising that he must use the sand glass to turn back time and restore Alamut to more peaceful times, Dastan plunges the dagger into structure and begins the process. “The sand glass was something no one had ever seen before so there wasn’t really any reference for it,” said Ellis. “We knew it wasn’t like ice, it was kind of quartz, but it was also very transparent. In the end we went to a local new-age shop and bought the biggest crystals we could find and shone lasers through them and put them on turntables and filmed lots of reference that way, trying to match that crystal look, especially the flaws.”
The final CG version of the sand glass was 300 feet high, matching a practical chamber on set that was only 40 feet high and 6 feet wide made out of glass perspex, and augmented with a self-illuminating magical swirling sand. “When the dagger is stabbed into the crystal and sand starts gushing out,” explained Ellis, “it had to be like a caged animal escaping. It had to be like an aggressive angry entity. That would go back into the walls of the chamber and start making rocks and things fall down. Then we had to have rocks falling and passing through the stream of sand. So there’s all this kind of circular process of sand animation. We used Squirt to turn around and see the results of our sand animation.” Dneg artists ran a simulation of the sand hitting the wall of rocks, then re-ran it once the motion of the rocks had been finalised. “We instanced particles for the sand rather than having to render CG three-dimensional forms,” noted Ellis. Other effects for the sequence included digi-doubles for wide shots and multiple dust layers.
Nvizage previses Persia
A team of artists from Nvizage created 15 previs sequences for the film over a year-long period from their London studios, on the Moroccan set and at Pinewood. The studio came on board right at the start of the show alongside the storyboard artists. “At this stage there was little in the way of production design,” explained Nvizage previs supervisor Martin Chamney, “so we began creating what we call ‘pitch viz’. Focusing on script visualisation and narrative we set a pace on fleshing out initial action cinematics before some of the production issues had been figured out.” The major sequences were fleshed out in this way, including the Alamut siege, oasis battle, the rewind sequences and the final sand room sequences, sometimes in collaboration with the relevant VFX facility.
Tom Wood guided the look and feel of the previs with Nvizage relying on their own expertise for getting through shots. “We took Tom’s advice on generating a high octane assault on Alamut,” said Chamney, “giving a non-spectator feel, Saving Private Ryan style, pace, panic, disorientation, shaky visceral camera work, and just about everything uncontrived. Tom wanted us to steer away from these old fashioned deliberate VFX shots when viewing the city and make it feel incongruous whenever possible. Another important part of our previs was to study the techniques of parkour. Our animators took considerable time reviewing some of the amazing stunts of David Belle, characterising any actions of Dastan whenever appropriate with these wonderful energetic moves.”
Artists worked in Maya and delivered shots as QuickTime movies edited in Final Cut Pro and enhanced with sounds and music. Some proprietary tools and add-ons for Maya were necessary for certain previs sequences. “For the Persian sandstorm scenes,” said Chamney, “we coded some proprietary tools for flocking the armies. In the collapse of Alamut, we spent time on building lots of Maya particle effects of rocks smashing down and dust kicking up everywhere. The look dev for the first reversing of time also needed some additional techniques with particles, and some beautiful time stamping techniques in After Effects.”
The staging of the action in the Oasis battle with the Hassansin Vipers was one of the more challenging scenes to previs. “The stylistic storyboards which portrayed a lot of movement and mood, were edited into an animatic,” explained Chamney. “After blocking out shots based on the boards, the screen direction was a little confusing. We set about addressing the problems by creating slates, with notes and descriptions for new camera angles in the edit. The layout had to be revised a number of times and our virtual previs set, loosely based on a location and somewhat fictional, was tailored to suit the action. This sequence involved a number of actors, where the Hassansins ambush Dastan and his men. Several battles outbreak at the same time, and attacks come from multiple directions. Part of the trick was to keep the action pacey, and continuously re-establish actor’s positions without messing up the screen direction. This sequence involved the entire team at one time and because of the time constraints we had animators working on different beats and shots were assembled as soon as they came off the production line.”
We've been a free service since 1999 and now rely on the generous contributions of readers like you. If you'd like to help support our work, please join the hundreds of others and become an fxinsider member.