A complex sim morphs realistic water into various objects.
Water. Mark Stasiuk, co-owner and CG supervisor at Fusion CI Studios, knows the substance well, especially in its digital form.
For the past several years, Stasiuk has created scripts for generating realistic CG water in a number of films, including The Guardian and The Curious Case of Benjamin Button. From turbulent oceans, to churning seas, to authentic-looking splashes and waves interacting with real-world or digital objects, Stasiuk and his crew seemingly have done it all. Recently, they even turned computer-generated water into various forms.
On the surface, this shape-shifting of water from a believable-looking fluid into unbelievable objects may seem out of sync with what Fusion CI is usually tasked to do. However, when examined at a deeper level, the connection becomes clear. Again, the group had to develop unique fluid-morphing technology that would enable them to manipulate water to achieve very specific action.
The simulation was for the New Zealand creative agency Sugar and its client, Fonterra, which was introducing a new brand of “smart” water called Whole. The concept called for the Whole brand of water to rise into the air and transform itself into the various shapes. “They wanted the water to be the star and tell the story—that the water was special and imbued with intelligence and a life of its own,” explains Stasiuk.
The agency, along with New Zealand VFX house Department of Motion Graphics (DMG), formulated storyboards for the 30-second, all-CG commercial showing the various shapes, “but they didn’t have a clear idea of how the water would behave and move from shape to shape,” says Stasiuk. “The conceptual idea was that the water would move sort of like a swarm of bees, with intelligence but with a life of its own.” Sugar and DMG also wanted the water to transition directly from one form to another.
It didn’t take long for DMG to realize that it was looking at a project that involved some difficult water effects. “From the moment we first laid eyes on the storyboard, we knew this was going to be one of the most challenging projects we had ever undertaken,” says Linds Redding, creative director at DMG. “If we had grasped at the time just how challenging it was, we might well have thought twice about saying ‘yes’ with such unseemly haste. From the outset, we realized we were going to need some specialist help.”
That is when Fusion CI became involved. The company is well versed in making advanced fluid simulations, and to do so, it creates a lot of custom tools for specialty jobs that require more than out-of-the-box solutions. Approximately 60 to 70 percent of the time, clients approach the firm to work on “really hard stuff—the simulations that are tricky,” says Stasiuk.
Water Work
Indeed, CG fluids remain among the most difficult effects for which to achieve natural looks and behaviors. In this instance, the crew needed to push the simulation even further by morphing the water into specific shapes.
The commercial begins with a puddle of CG water, before the fluid springs to life into the first shape. From there, the project involves one continuous, 30-second, 650-frame shot, done in a single, complex fluid simulation within Next Limit’s RealFlow.
“Fluid looks most realistic and fluid-like when it is in its natural forms—droplets, puddles, streams, splashes,” says Stasiuk. “When you push fluid into a specific geometric shape, you’re forcing it to perform unnaturally, while still demanding that it look like fluid. As the fluid transforms toward a highly detailed shape, you have to sculpt its motion so that its behavior looks and performs naturally.”
In addition, says Stasiuk, you have to make sure that only the exact quantity of fluid that will fit on the surface of the geometry is attracted to the surface. “If you add too much fluid or distribute it badly, it will turn into a giant glob, and you won’t see the details of the object,” he notes. “And once [the water] is on the shape, you don’t want it to look like a static ice sculpture, so you have to develop ways of making the fluid continue to move even as a still object, creating the illusion of fluid without destroying the details of the geometry. It’s tricky.”
Tricky, yes; impossible, no. And the good news was that Stasiuk did not have to develop the tools needed from scratch. Fusion CI already had a proof-of-concept tool that could form a single shape, something basic, that the facility had built for a previous project. “It was something we could use, but when we got further into this work, we completely rebuilt the tool because the project required so many different effects and controls. So we ripped [the code] apart and started again.”
During R&D, the group developed a proprietary fluid-morphing technology scripted through Python. Stasiuk provides the following before-and-after comparison of the fluid-shaping tools: The original proof-of-concept tool contained 250 lines of code; at the end of this project, the tool contained approximately 1700 lines of code. And all that code formed a proprietary plug-in to RealFlow.
Fusion CI worked in concert with DMG, which did all the camera animations and renderings. DMG provided Stasiuk and his group with the geometry for all the forms that the water had to assume—a brain, a water bottle, a bridge, and a bunch of bananas—which was done in Maxon’s Cinema 4D. The Fusion CI team then used Autodesk’s Maya to massage that geometry as the underlying shapes for the fluids.
Fusion CI output the DMG animated shapes as OBJ files, then imported the information into Maya, simplifying the data and using the modeling tools in Maya to adjust the geometry so the simulations would run more efficiently. Next, the team output those results to the RealFlow format.
The last step, and the most crucial one, involved applying the proprietary tools to drive the simulations within RealFlow. “Over the years we have amassed a big library of all these tools that do all kinds of different fluid-effects phenomena. So when someone comes to us, we can usually think back and adapt something we have done before,” explains Stasiuk. Because of this, Fusion CI can spend less time on R&D for a project than it would starting from scratch. For the Whole water commercial, the team spent about six weeks developing the technology, and then another two weeks to run the sims and finish the job.
In the application, the water had to look and behave like real water, but at the same time, it had to form sharply defined shapes with a lot of detail. And, the water had to hold the shapes so the viewer could identify the form. “For example, the water had to form this very detailed brain shape, but at the same time, we had to maintain the illusion that it was water forming this thing. If you get all the particles to glom onto the shape and stick and stay, it looks like an ice sculpture. It starts to look like geometry.”
Using the earlier version of the tool, that’s exactly what happened: The plug-in formed the shapes very clearly, Stasiuk says, but the substance didn’t look like water anymore. It looked like an ice sculpture. The trick, he says, was to get the water to slosh around a bit while it formed the shapes, and then keep rippling, moving, and dripping. To this end, it had to have constant bits of water that dripped off. That extra water was generated with the rest of the water but would be allowed to drop off the shapes.
“Having the water form a shape but still behave like water is sort of paradoxical,” says Stasiuk.
Finishing Up
When Fusion CI was done with the simulation, it transferred the data to DMG in New Zealand via FTP, a process that took a few days in itself. “The data is huge,” Stasiuk says. While the end result is one long, continuous sim, the work actually entailed a number of versions of the simulations, each taking an average of three days to run on 64-bit Windows XP machines with eight cores and 16gb of RAM.
Fusion CI created the data for each sim, establishing the particular behavior. The particle files were then meshed during a post process. The sim resulted in approximately 600,000 particles, while the mesh contained between three million and five million polygons, depending on what was occurring in the shot. Fusion sent these meshes to DMG, to complete the commercial.
Stasiuk’s group compressed the 650 frames of data for each simulation down to 25gb, and then sent that via FTP to the visual effects facility—a process that took two days. After receipt, DMG imported the meshes into its Cinema 4D renderer.
“DMG was great to work with,” says Stasiuk. “They gave us the time and creative space we needed to make the fluids work, and had brilliant ideas on how to get the most out of the water. On top of that, their camera work and lighting made the water look fabulous.”
While the team at Fusion CI is no newcomer when it comes to fluid simulation, Stasiuk notes that this application was unique in a number of ways. He points out that the company is often asked to do either accent types or environmental types of fluid effects. He points out the differences: Accent effects are like characters having a fight, wherein the character splashes the other with a pan of oil, for instance, and his group does the oil as an accent add-in effect. An example of an environmental effect would be a helicopter flying over an ocean, and that ocean is part of the background’s natural environment.
Mark Stasiuk from Fusion CI scripted the fluid-morphing technology used in the Whole water commercial through Python.
“However, this was a highly art-directed hero effect that was the entire visual for the entire commercial. It’s not like it involved a little splash here or there behind a character,” Stasiuk says. “It was the character, and the only character in the whole commercial. There was a lot to do, but you don’t get these opportunities often where your effect is the only thing happening in the spot.”
All the work Fusion CI did for this application paid off quickly. The day after the studio delivered the Fonterra simulations, it received a call for work on a music video wherein dancers turned into water.
In less than two weeks, Fusion CI was able to adapt the tools from the earlier job and produce five shots for the video. Again, letting their creativity flow.
Karen Moltenbrey is the chief editor for Computer Graphics World.