Join David Mattingly for an in-depth discussion in this video Animating the camera, part of Digital Matte Painting Essentials 5: Camera Projection in Maya.
We're ready to add an animated camera to our scene, but it be nice to see the view as large as possible. I have on Overscan in the View menu. And if you drop down to Camera Settings, you can go back to Fill for this part of the project. Also, we had on High Quality Rendering while setting up our textures, but let's go back to Default Quality Rendering, since it'll make the view ports update faster. If you have a fast computer, you can leave high-quality on. Your scene will look prettier.
If you didn't set all your maps to combined, and highest quality in hardware texturing for the material, you'll have to go back and set those now to get a nice preview. Make sure your projection cam is selected. Duplicate the projection cam, either by going up to Edit and choosing Duplicate, or pressing Cmd or Ctrl + D. Inside the attribute editor, select the first tab that just says projection Cam 1, and rename it animation cam. Be sure to rename it.
Naming your cameras can avoid a lot of scratching your head, wondering what camera does what. Remember we locked all the attributes of the projection cam, so we wouldn't accidently move it. Since the animation cam is the duplicate of that, it's locked also. We need to unlock it in the Channel Box, select all the attributes that are greyed out, right click and unlock them all. The animation camera needs to move. Let's look through the Animation Cam view and notice that it's exactly the same as the projection cam view, since we haven't moved it.
Before we start designing our shot, we need to change the render and resolution. Open up your render settings and set the renderable camera to the Animation Cam. We set up our project, the same size as the painting. 3840 by 3324 pixels. That way when we did test renders while setting up our geometry, it would exactly match the painting. However as we add in our Animation Cam, we'll want to render it a more cinematic aspect ratio and in a smaller size.
You can change your render size without messing up the Projection Cam aspect ratio. That's set on the Projection Cam and must not be changed. You could do HD 1080 which gives you 1920 by 1080 pixels, but that's a very horizontal format. You might want to use full 1024 format, which is 1024 by 768, which gives you a squarer format to render to. That's what I'm going to use for this render.
Notice that the render size is shown at the top of the view, 1024 by 768. And that's the aspect ratio we'll be framing our shot to. In my interface, Maya is showing only 24 frames. But you should type in 200 here to get the entire length of the shot in the timeline. Now double check that the Animation Cam is selected and the timeline is on frame one. And, press the S key to set a keyframe. Notice that in the channel box, all of the transforms of the Animation Cam turned red.
That shows that all of these attributes have key frames on them, and are ready to be animated. Also, make sure that this little key at the bottom left corner is clicked, turning the key red. This is called Auto Key, and whenever you move the camera after the first key is set on frame one, it'll set another key, making Maya animate between those two positions. Drag the time indicator in the timeline to frame 200, and let's move the camera. Push the camera in and pan and rotate off angle a bit.
We're having a problem with the sky when we rotate. We're seeing the edge where Maya repeated the texture. Don't worry about that for now. We'll fix that problem in the section about advanced camera projection. Push in a bit more And let's fix the angle so that we look up on the castle more at the end of the shot. And take a look at it by dragging back and forth on the timeline. That looks pretty good. Notice how the walls of the castle move against each other and there's a profound parallax shift between the castle and the background.
Sadly, you can't channel your inner Michael Bay and spin all around the castle. As we're set up here, a modest move is all we can do. Let's go back into the Perspective view and we can see why. If you go too far behind the castle, the projection will fall apart. The projection on the back is just the front projection shot through to the backside of the cube. Also the towers and dome, since they were just projected on a cube, will fall apart quickly if you push in too far or rotate too far off the angle. Let's go back to the animation cam view.
I'm going to save this for you premium members as 4_CameraProjection_AnimatedCamera.ma. We're all ready to do a render which we'll do in the next lesson.
- What is camera projection?
- Isolating the layers in your painting
- Setting up for projection camera
- Adding geometry
- Projecting textures
- Animating the camera
- Vertex modeling
- Animating the background
- Adding flames, smoke, and glows
- Rendering your project