1、在2D实拍视频中合成3D动画在2D实拍视频中合成3D动画3D In A 2D Scene 在2D场景中加入3D动画 Ben Cowell Cricket翻译 cuiyunpeng 我相信你一定会被这篇教程所的缜密的思维、精致的叙述所感染!This is a very simple tutorial demonstrating how to take 2D video footage and composite a 3D animated object in the scene. Im not going to go into every specific MAX feature and opt
2、ion used, Instead Ill be concentrating more on the actual process and flow of work and files. 这是一个关于如何在2D视频脚本中混入3D动画物体的简单教程。教程不涉及3Dmax的详细功能,而是注重与实际的工作程序。 1.Convert your video sequence to individual TIF files. 1. 把你的视频序列转换为TIF文件。As we have discussed earlier when working with effect we want to keep fi
3、le quality as high as possible, therefore JPEGs are not the best medium for image storage. In this tutorial well be using TIFF files or TARGA fileswhen we require an alpha channel. Take this TIFF sequence and store it for later. 我们要尽量保持文件的品质,所以JPEG等格式不在考虑范围之内。自在这个教程中,当需要alpha通道时我们向选用TIFF或TARGA格式。把视频
4、转换成TIFF序列以备后用。 Unless youre using a very high end machine youre not going to want to be dealing with large amounts of files while compositing, so take one frame of your sequence and keep it handy. Store the rest of the files somewhere else for later. Keep one frame as a proxy. Make sure you keep you
5、r files and directories neat, compositing can be a logistical nightmare with the amount of files youll be dealing with. A bit of planning and neat directory structuring can save you a lot of headaches later on down the line. 除非你使用的机器非常高端,否则在合成时不能处理大量的文件。所以从你的视频序列中选出一帧并放在容易调用的地方。保持一个静止帧作为代理。一定要保持你的文件
6、和目录清晰明了,因为如果要处理大量文件的话合成操作将会苦不堪言。进行一点计划并保持文件组作执整洁会在后期避免许多麻烦。2.Create the Animation. 2.创建动画。Im not going to talk much about your actual animation. Ill assume you have something simple like a rolling ball or the little car Im using in my demo. Remember that your camera cannot move in this example (came
7、ra matching is supported in MAX, but Ill not touch on that for this demo, well be working with a simple locked off camera). 这里不涉及具体动画制作,我肯定你手头上有像球滚动或汽车移动这样的可在这个示例中使用的小动画。一定要保证在动画中摄像机是静止的。(虽然3Dmax支持摄像机匹配,但在这个示例中不涉及这些。我们将处理简单的摄像机被锁死的动画。) 3. Tear your hair out lining up the camera. So now you have a sh
8、ort animation and a video sequence. The next step is to make the camera in your animation line up with the camera you used for your video shoot. 3.现在准备好了一个小动画和视频序列。下一步是将3D动画中的摄像机与视频中使用的摄像机对齐。 Now is the time all those measurements and notes you took onset will come in handy . assuming you did actual
9、ly make all those notes on set. If not then its a very long slow process of setting the viewing angle and the zoom of the camera and shifting its orientation until it matches. 现在手头上应该有你在拍摄时的测量数据和笔记。否则设置3D动画中的摄影机的角度、焦距、方向与实拍时一致将会是很慢的过程。 To speed this process up it would help if youd shot a few frames
10、 of a real object in your scene, and then keep this for reference along with the dimensions of the object. Then when you come to MAX you can load a frame of this into your background and create the object using its exact measurements. Now you can be sure your scale of your 3D objects in relation to
11、the background footage and positioning of the virtual camera will be correct. 为了加速这个过程,在实拍时加几帧参考物体会很有帮助。当进入3Dmax中你可以在如一帧作为背景并以其为参考创建物体。现在已可以保证3D物体的放缩值、移动与实际相符。I used a video case, took the shot into MAX, created a video box in MAX and then lined them both up perfectly, this way i could be sure where
12、 the ground was in my MAX scene, and that the animation would align correctly with the footage. 我把一个录像带盒摄入MAX,再在MAX中创建一个虚拟的方块与其严格对齐,这样我可以保证虚拟的场景与实拍的场景吻合。 As you can see above it can take a lot of work to line the objects up correctly, and you may require a few reference objects to ensure the camera
13、is perfectly matched. 从上图中可以看出对齐物体需要许多工作。你可能需要多个参考物体来使摄像机完美的吻合。4. Lights!. 4. 灯光! Once youre sure you have your camera matched, freeze it in MAX to avoid accidentally shifting it whilst you continue to work on the scene. 一旦你对齐了摄像机,在MAX中锁定它,以避免在下面的工作中不小心被移动。 Now you can refer to all those lighting no
14、tes you took on set. I tend to use a little cheat and place some white ping pong balls in the scene and shoot a few frames, then when i come back to the computer, i can create some balls in MAX and get the lighting and positioning to match perfectly. 现在你可以参考在实拍时的灯光纪录。我喜欢在实拍中加入几帧乒乓球的画面,在MAX中我创建一样的球体一
15、保持光照和位置吻合。 Again this will take time, lighting is an art form. Its important not to rush this stage as the quality of the lighting will decide whether or not an effects shot works. 这也需要时间,打光是一门艺术。这一步一定不能着急,因为打光的品质将决定最终效果的质量。 Play close attention to shadows and the color of the light in the scene, al
16、so be aware that unlike in computer animation, light in the real world bounces around, so if an object is placed on a white surface light will bounce from the white surface onto the underside of the object. You will have to try to simulate all this with your computer lighting, which can be a very ha
17、rd task. 注意场景中的阴影和光的颜色,注意,与电脑动画不同的是,显示中的光线会被四处反弹,所以当一个物体在被放置在白色表面上将把白色应在物体的底部。你必须努力用电脑中的光模拟这一切。这将会是项艰巨的工作。 The best advice to matching lighting is good observation and note taking during the shoot. 吻合光照的最佳建议是仔细观察和在拍摄时纪录笔记。 5. Anchoring your images using shadow. 5. 用阴影描绘图像 There are many visual clues
18、 our eyes need to understand the relationship between objects in an image, but one of the most important is shadows. Shadows help us understand where the light is coming from, how many light sources there are and the intensity of each. 我们的眼睛需要许多视觉线索来判断一张画中物体的关系,其中最重要的是阴影。阴影帮我们理解光从哪里来,有多少个光源和每个光源的强度。
19、 In this example the intensity and blur of shadows will be achieved in post production so Ive used ray traced shadows to give me perfect black shadows with a hard outline. 在这个示例中阴影的强度和模糊度将在后期处理中完成,所以我是用光线跟踪类型的阴影来产生完美的黑色硬边阴影。 Assuming your lights are set up correctly your shadows should work without
20、much alteration, we simply have to place proxy objects in our scene to receive the shadows. Proxy objects will be placed wherever there is an object in our shot that will receive a shadow from our CG object. If you look at the example below you can see that Ive had to recreate the CPU, the desk, the
21、 wall and the cup to receive shadows from my car. 为保证灯的位置正确设置,阴影不应有太大的改动,我们必须在场景中创建虚拟物体来接受阴影。在实拍中有实际物体的地方都应放置相应的虚拟物体来接收CG物体产生的阴影。从下图中可以看出我创建了主机、桌子、墙壁和杯子来接收小车产生的。6. Multi-pass rendering. 6. 多次渲染 To allow me to control the attributes of each shadow individually in post production Im going to render ea
22、ch shadow out separately. In my example there are three shadows, a downward shadow beneath objects, and then a long shadow cast behind. Ive split the render of the long shadow into two passes, one for the vertical objects such as the cup and the CPU, and one for the horizontal objects such as the de
23、sk. This is because the horizontal shadows are much lighter than those cast on vertical objects and Id like the ability to control this in post production. 为了在后期处理中能分别控制每一个阴影的属性,我将会分别渲染出每个阴影。在例子中有三个阴影:在物体下指向下的阴影,然后是物体后的长阴影。我把长阴影的渲染分成两步,一是对于垂直的物体例如、杯子和主机,另一个是为水平物体例如桌面。这是因为水平方向的阴影比在垂直物体上投射的阴影要轻的多,我想要在
24、后期处理中能控制这些特性。 So now we want to render out out shadows for the whole sequence. MAX comes with a material called shadow/matte that will only render shadows cast on the object this is ideal for our purposes. We can apply this material to the objects in the scene such as my proxy CPU, desk, wall and cu
25、p. 现在我要为整个场景渲染出阴影。MAX有一种材质叫做shadow/matte(阴影/遮罩),它将只渲染被投射在其物体上的阴影,这对我们达到目的是理想的材质。我们可对场景中的虚拟物体例如主机、桌子、墙壁和杯子赋予这种材质。 Now if we set the environment background to white and render out a shot youll see you only get the object and the shadows it casts. 现在如果我们将场景的环境背景设置为白色并渲染出,你发现你只得到了小车物体和它投下的阴影。 The proble
26、m is we still have the 3D object in the shot, which we really dont want when we come to post production. When using ray traced shadows MAX wont allow you to see shadows without the object being visible, so well use a plugin texture called which is available from the nice people at : 问题是在镜头中仍有我们在后期不想
27、看到的3D物体。当时用光线跟踪类型的阴影时MAX不允许在物体不可见是投射阴影,所以我们将使用一个叫做cast shadows only(只投射阴影)的纹理插件。插件可从 This material can now be applied to the object (in my example the car) so that when we render we only see shadows. Now youll have to play with the shadow cast/receive options for your proxy objects as obviously we d
28、ont want them to cast shadows on each other. 这个材质现在可以被赋予物体(在这个例子中是小车),结果是当渲染时我们将只看见阴影。现在我们必须调整虚拟物体的阴影产生、接收选项,以避免它们之间产生阴影。 Now we can render our shadows out one by one. In my case this involved rendering out 300 frames for each shadow, each time turning lights on or off and altering the cast/receive
29、shadows options for various objects. 现在我们能一个个渲染出阴影了。这个例子中我为每阴影渲染300帧图像,每次为不同的物体设置阴影产生、接收选项和调整光源的开闭As you can see above you now have three sets of shadows. Take these frames and store them for later, once again keeping a proxy of each for compositing. 从上图可看出现在有三种类型的阴影。储存这些帧,再次为每段设定一个代理。7. Shadows cas
30、t by foreground objects. 7. 前景投射的阴影 Youll notice in my example that the monitor should cast a shadow on the car as it emerges from between it and the CPU. This is simply achieved by creating a proxy monitor, and assigning our cast shadows only material to it. Not we are ready to perform the final re
31、nder of the car element. These frames should be saved as TARGA images as the Alpha Channel will come in useful when we perform the composite. 你会注意到在例子中当小车在主机与显示器之间是显示器应在小车上投射阴影。这可通过创建显示器并赋予其产生阴影的材质见大的解决。现在我们准备好了渲染小车这个元素。因为在合成时需要Alpha通道,所以这些帧应被储存成TARGA文件。8. Putting it all together. 8. 把他们放在一起。 Once again Im not going to go into any real depth on the software side on compositing all this together. For this example I used Aftereffects. 再次说明我不会深入软件的技术细节。在这个例子中我使用Aftereffects。 You may have been wondering why I reminded you to keep a copy of one frame
copyright@ 2008-2022 冰豆网网站版权所有
经营许可证编号:鄂ICP备2022015515号-1