With so much of the film riding on the dynamic between the two, the visual effects team had to make sure that Ava was immediately believable as a machine without letting design or technique get in the way of Vikander’s nuanced performance. The result is nothing short of a marvel. On the eve of the film’s expansion into even more US theaters, I spoke with visual effects supervisor Andrew Whitehurst about how they were able to tackle the challenge.

Alex Garland’s Ex Machina is slowly emerging as a sleeper sci-fi hit, and for good reason. It’s a deft, thought-provoking piece of filmmaking that asks tough questions about technology , gender, and — like some of the very best science fiction — the inherent deficiencies in human nature itself. At the center of it all is the relationship between two characters: a shy programmer named Caleb (Domhnall Gleeson) and a robot named Ava (Alicia Vikander), who may represent the first example of truly sentient artificial intelligence.

Bryan Bishop: Let’s talk about making Ava. Other than the restrictions with budget and time, what were the biggest challenges? Andrew Whitehurst: I think there’s a sort of film historical precedent issue, which is we didn’t want Ava to look obviously like a robot from any other film that people would be used to seeing. The C-3POs, and Maria from Metropolis; that kind of thing. I made a rule which I applied to myself as much as anybody else who was on the team working on it, which was no one is allowed to look at robots. We did get a whole bunch of reference images of sculptures, by Constantin Brâncuși, who did these sort of very organic, yet almost mechanical, modernist sculptures. And things like Formula 1 car racing suspension. Anything where strength and weight was a big issue in the design of them. And we used that, plus human anatomy, as a kind of starting point when we were beginning to physically build her. When Alex came to [visual effects company] Double Negative, he’d already been working with a comic book artist named Jock who’s done awesome work. I’ve always loved his stuff, so it was great seeing fresh pictures from him. And they’d come to us with some designs and some ideas, which we then worked up as we were discussing the practicalities of what could and couldn’t be built from the painted concepts. You get to a point with concept paintings when you have to say alright, this is as far as we can push a painting, and now we actually need to start building something tangible. It was [being built] in the computer, but it has form and solidity. Because with paintings, you can hide a lot in the brushwork. You can do a little brush stroke that suggests something, but it’s not discrete, and when you’re building something for real it has to be entirely discrete. "A lot of times when you see robots... you can cheat like hell." Overall, I think the approach to Ava was that iterative design approach, but she had to be mechanically plausible as well. A lot of times when you see robots, particularly in movies and you’re doing it with CG, you can cheat like hell. You can have things that will intersect ... you can get away with murder. I was absolutely determined that we wouldn’t do that. If it’s a film that has a slightly more fantastic aspect to it, it’s fine. But Ava as a character and as an entity on screen had to be entirely plausible to me to work. So I wanted to make sure when we were designing her that everything was functioning, plausible, and everything was in the right place. The validation of that was that a large chunk of Ava was 3D printed for a scene that takes place in the laboratory where she’s constructed, and when they 3D printed it, it all slotted together, and it all articulated properly. That’s something that most movie viewers, they don’t consciously notice it, but I think if we had cheated something about it wouldn’t have felt quite right. And I think that would have undermined what we were setting out to achieve.

It's a difficult balance to strike, because the audience has to understand she’s a robot, but for the movie to work that idea then needs to fall away, in the same way it does for Caleb. "So much of visual effects is psychology more than anything else." Exactly. We also put a lot of effort into things like the muscles contracting properly, and the various pipes and wiring having just a tiny amount of jiggle. And it’s something that you really do not notice. But I remember when we were looking at shots, for whatever reason when we put a shot through to render overnight that secondary animation hadn’t rendered properly, so it was missing. And everything suddenly felt very stiff. And you kick the shot off again, this time with that animation integrated into it, and it works again. It’s not something that you can necessarily put your finger on as being wrong, but if it’s missing then you suddenly feel that something’s strange. So much of visual effects is psychology more than anything else. You’re looking at what are the cues that we as humans latch onto when we look at something that makes it feel right. And it’s often those really kind of subtle things that help ultimately push it that last few percent to really sell the illusion. How many VFX shots were in the movie overall? Overall I think it was about 800, 350 or so of which were robot shots. ... But I think the thing that is notable — I mean, that's not a particularly high shot count by modern visual effects standards, but this film has many fewer shots in it. The average shot is probably about eight seconds long, which when you consider most action films, you're talking about shots that are often less than a second. The number of shots may be lower but the actual number of frames is pretty high just because each of those shots plays out for quite a while. I’m curious about how you shot the Ava scenes. It’s my understanding that you didn’t go the greenscreen route, or have Alicia Vikander’s face covered in crazy motion capture dots or anything. No. It was the first film I’ve ever done where we did not put a single greenscreen up. The key thing about the film fundamentally is that it is a series of conversations. And for those conversations to work and be engaging, you have to have two actors that are talking to each other, and then the audience can get involved in that conversation. And if that doesn’t work, it doesn’t matter what the visual effects do. You’re screwed, because there is no drama there. So we knew we had to let Alex and Rob [Hardy, the cinematographer] shoot it as they would shoot any dialogue scene with two actors sitting there, and that’s what was on set. "It was the first film I’ve ever done where we did not put a single greenscreen up." Alicia was wearing a costume that was mostly made of that grey mesh you see in her shoulders and upper torso area — she had a kind of catsuit that was made out of that kind of material. But the scenes had to be shot as if they were a regular dialogue scene, mostly because you needed to have that interaction between the actors. So you couldn’t use motion capture, for example. But the other reason was we had a six-week shoot, so we were doing between 15 and 25 set-ups a day which is a hell of a lot to shoot for a movie. That’s really motoring. And if you’re [constantly] saying, "Oh we need to put greenscreens up," or, "Oh we need to do a motion control or motion capture shoot," there just isn’t the time. You have to be fast, and you have to be very flexible.