Alicia Vikander (Ava) and Alex Garland consult on the set of Ex Machina

Well before Alex Garland became the acclaimed writer of 28 Days Later, Sunshine and Never Let Me Go—some of the most original genre films of the new millennium—he spent hours as a young man in England tooling away on the latest in personal computing at the time: an 8-bit ZX Spectrum keyboard.

So when a friend passed along a copy of Murray Shanahan’s Embodiment and the Inner Life: Cognition and Consciousness in the Space of Possible Minds, it quickly rekindled his obsession with artificial intelligence.

“It was like mountain climbing,” Garland says of devouring the book, eager to understand Shanahan’s ideas about the potential of an entirely sentient machine.

Garland wondered what that moment would mean for man. The writer feverishly began work on a screenplay about the clandestine creation of a robot that would transcend famous thought-experiment exams like philosopher John Searle’s Chinese Room argument, which gauges a computer’s comprehension of language, and the Turing Test, an experiment designed to check a machine’s ability to exhibit intelligence. Although his duties writing 2012 thriller Dredd soon beckoned, it was clear to Garland that the story, Ex Machina, would be his next film. So in the process of imagining one machine, he set his sights towards another: the process of moviemaking.

Ex Machina is Garland’s directorial debut—though mention that to him and you’ll get little more than a shrug. After becoming a cause célèbre as an author with the 1996 novel The Beach, Garland was hired to adapt the book for Danny Boyle to direct. This already auspicious start proved even more so when the project introduced him to producer Andrew MacDonald, co-founder of the British-based production company DNA Films. MacDonald gave Garland a creative haven in which to breed his brand of high-concept, unusually intimate genre films.

Kyoko (Sonoya Mizuno) stares down Ava (Alicia Vikander) in a still from Ex Machina

Kyoko (Sonoya Mizuno) stares down Ava (Alicia Vikander) in a still from Ex Machina

An on-set presence on all the films made from his screenplays, Garland would consult with the likes of the VFX supervisor, the production designer or the actors, as any director would—unusual for a writer. He was even present for ADR. “The whole notion of directing, rather than being a big deal, had become increasingly small,” he says. “I don’t really distinguish between this film and previous films I’ve worked on. I’m just one of a bunch of people.”

There is a discernible through-line from his previous films to Ex Machina. The conceit of the first fully-conscious robot (named Ava, played by Alicia Vikander) embodies perennial Garland themes: the potential of human ingenuity, and the all-too-human frailty that’s exposed when creators confront what they’ve wrought. Garland gives the Frankenstein tale a uniquely contemporary spin. Like the humanoid, “female” Ava, whose classical beauty could have been executed by Apple’s design guru Jonathan Ive, Ex Machina has a clean, sleek style that places it snugly alongside such sophisticated science-fiction such as Blade Runner, Primer and Moon—but with a wickedly sharp sense of humor and enough “WTF” moments to become something entirely its own.

In an eerily plausible device, Ava’s knowledge and consciousness are drawn from the same search engine that gave her genius creator Nathan (Oscar Isaac) the billions to build her. When Nathan enlists the help of a randomly selected coder named Caleb (Domhnall Gleeson) to assess Ava’s sentience over a week of sessions at his remote home/laboratory, the film builds considerable suspense—not out of gauging what Ava can understand, but whether the two men fully comprehend the ethical ramifications of her invention.

Garland and Oscar Isaac, who plays the mercurial tech genius Nathan

Alex Garland and Oscar Isaac, who plays the mercurial tech genius Nathan

“As I was writing this stuff, I was thinking, ‘We’re never going to get anyone to give us more than £3 million ($5 million) for this.’ It’s too difficult. It’s not mainstream enough,” says Garland, who to his surprise was able to secure $15 million for a six-week shoot in the fourth quarter of 2013. Still, even with a limited setting and a small cast of characters (just four, including Sonoya Mizuno as Nathan’s mysterious Japanese servant), he knew his half-VFX/half-human lead character was going to require the bulk of the budget.

“Audiences are so sophisticated with what they will and won’t accept with FX,” says Garland. “We had to compete with films that literally have a budget 10 times what we had. I knew that whatever we had put aside for VFX and post-production was not going to be enough. There was going to be a massive, scary surprise that we wouldn’t learn until we got to the edit, so I was trying to leave the shoot with contingency money still in place. I was also scared about going over budget and then having to ask for more money. You know if you ask for more money, you open the film up. People start saying, ‘Why don’t you change this?’”

Rob Hardy, the film’s cinematographer, was impressed. When he arrived at Pinewood Studios in England, where interior shooting took place over the first four weeks, Hardy noticed that each of the departments were stationed together to encourage collaboration. The camera house was only a few feet away from the art department and the set department, and the digital theater was close enough that he could shoot tests and see the results almost immediately. The schedule was arranged just as thoughtfully, with eight weeks of prep, much of it with the actors available: workshopping the script in the morning and working out the logistics on set in the afternoon.

Garland’s combination of precision and humility (he calls his methodology “the anti-auteur theory”) makes passionate fans of collaborators. Take Vikander, whose porcelain features and graceful physicality from years as a ballet dancer made her an ideal choice to play Ava. In spite of a busy schedule that will see her in eight movies in 2015, she went out of her way to lobby for the role, shooting her audition tape at two a.m. while on the set of Son of a Gun.

Even Domhnall Gleeson, who appeared in both Never Let Me Go and Dredd, says he felt as if he won the lottery when he got the call. “Hilariously, it was like I was getting the email [that Caleb gets] from Nathan right at the beginning of the film, saying that I’d won a competition.” Why? “Alex is very economical with storytelling—how he gets important information across. I read this in an hour and a half, and then read again in its entirety.”

Then there’s Isaac, who first auditioned for a Garland picture in 2005 when Sunshine was casting. Weeks away from graduating from Juilliard, the actor became so obsessed with the script that he created his own soundtrack to take with him to the audition—though he ultimately didn’t get the part. (“I kept thinking about the script [afterwards]—I even thought, ‘These songs that I have are so good, I wonder if there’s a way I can get them to the production so they could use them, because that could really help the movie.’”)

To prepare Isaac for playing the menacingly brilliant Nathan, Garland and the actor talked for hours in the months leading up to production of Ex Machina: about everything from “qualia” (the experience of existence), to Noam Chomsky, to Nathan’s appearance. They settled on a utilitarian bald-headed, bushy-bearded look based somewhat on Stanley Kubrick. Says Isaac, “Kubrick was such an imposing figure, a figure of such mystery and intensity, that there was something of that that I wanted.”

More difficult to cast was billionaire Nathan’s breathtaking subterranean lair, set in Alaska. Conscious of time and budget, Garland wouldn’t allow the production to stray far from Pinewood for the exterior shoot. Yet “Spain wasn’t right and the Alps were too chocolate-box-ian; too familiar.” Production designer Mark Digby and art director Michelle Day looked all over Europe and finally found the Juvet Landscape Hotel in Valldal, Norway, a postmodern nine-room resort. Glass, concrete and wood tucked into a remote mountain setting, it was perfectly emblematic of the symbiosis between nature and man-made technology.

The stunning architecture of the Juvet Landscape Hotel made a perfect imaginary scientists’ haven

The stunning architecture of the Juvet Landscape Hotel made a perfect imaginary scientists’ haven

Back at Pinewood, Hardy installed 15,000 mini-tungsten pea bulb lights into the sets. Wanting to avoid the fluorescent light that bathes so much of science-fiction, Hardy wanted the tungsten to add “a softness and an emotional warmth” to the set’s classic hard lines and rigid structure. As it turned out, the tiny lights had an additional benefit: “We could control the space in a way that not only was very quick, but really created subtle differences and shifts in the shape and the texture of the light.”

For the sake of saving Garland’s contingency budget, speed was at a premium on the production, says the director: “The real way to make a film cheaply is to shoot it quickly. The more weeks you shoot, the more you hemorrhage money.” Garland maintained “continuous days with no breaks, very intensive working periods—but everyone understands that at 6 o’clock we stop, so it’s a fair deal. For the most part, we’re aiming for three takes and we’re moving on.” That said, Ex Machina is a slow burn. “Normally, if you’re shooting quickly, you use it almost as a virtue—a guerrilla aesthetic of grabbed, handheld stuff [that] creates an energy. That was the wrong energy for this, so we had to figure out a way of shooting very, very fast whilst capturing a calmness.”

Hardy’s solution was to give the camera movement a “creeping” quality, moving ever so slightly to give the audience a feeling of “leaning in” to study the characters, as Caleb and Nathan themselves study Ava.

“They’re like animals circling each other in the wild,” says Hardy. “I’m always a fan of the mid-shot, because it combines the emotion of the close-up with the [context] of a person’s position in an environment, which you get in the wide shot.” The room where Caleb observes Ava was rich with compositional potential for the cinematographer. “I could get frames within frames within frames, which tell you a lot about the characters. I used light to do that, as well as the verticals and the horizontals in that space, and reflections [in the glass]. I could break up a composition with Caleb and Ava in it, either opening up the space between them and allow them to become emotionally close, or closing it down to emphasize the barriers between them.”

Hardy used a Sony F65 camera with handmade anamorphic Crystal Express lenses—“from the ’80s; cooked glass, a British-made glass.” Because of the lenses’ idiosyncrasies, “it was imperative that the camera I chose embraced every discrepancy. So we tested the RED and the Alexa. The RED didn’t really render the landscapes the way I wanted it to. The Alexa was great, but it seemed to negate my lens choices—it didn’t really pick up the fine details of the lenses, whereas the F65 gave us everything.”

The crew had to get creative realizing Ava on screen. Initially, Garland brought on the comics artist Jock, with whom he’d worked on Dredd, to come up with the first designs of the character. An undisguised product of the male gaze, Ava’s design doesn’t skimp on traditional markers of physical beauty (sleek curves, small waist), though she has a translucent torso through which her organs—or rather, her wires—are visible.

Leaving Vikander’s face and silhouette largely intact, the design lent itself to as little interference as possible on the set. VFX supervisor Andrew Whitehurst and his team at the British VFX house Double Negative encouraged Garland and his crew to be free with what they shot, promising they could fix it in post. “They understood our visual manifesto, so we could shoot the story in as human a way as possible,” says Hardy.

The camera crew still had to be conscious in how they framed Vikander within a shot, though. “It felt like was a very extended version of that scene in Austin Powers where he’s naked and hiding behind all those strategically placed fruits,” Garland says with a laugh, adding that all the close-ups in the film were practical shots, while the mid- and wide-shots of Ava were reworked after principal photography.

As for the contingency funds that Garland had refused to dip into during the shoot? “We used all of that for the back of Ava’s head and neck…some beautiful VFX work, and that was never planned.”

Vikander’s midsection and the back of her head and neck were replaced in post with a transparent fiberglass-like material

Vikander’s midsection and the back of her head and neck were replaced in post with a transparent fiberglass-like material

Kubrick be damned—Garland achieves his exacting vision through a degree of flexibility. “I’d come off the back of a film that for various reasons had been very difficult, and I went into this film saying, ‘We’re not doing that again.’ There is another mindset that exists with some filmmakers, who say that unless a shoot is fucking miserable, it’s not going to be any good; a kind of flagellating version of filmmaking where artistic integrity is born out of blood and sweat. I wanted to prove to myself that was bullshit.” MM

Ex Machina opens in theaters on April 10, 2015, courtesy of A24. Photographs by Liam Daniels, Courtesy of A24. This article appears in MovieMaker‘s Spring 2015 issue, on newsstands April 28.