For instance, due to the height differences of races, when they needed to insert Gandalf into a dynimac shot with a Hobbit, sometimes McKellen had to play in front of only green screen. Or i think the scene in which Legolas takes down the Mumakil there was nothing there, just the actor, at least in some shots.