• No tags were found...


You will notice that the shadow file appears entirely black. Thisis because the shadow was rendered with a black backgroundand won’t be visible until it is composited on a different color.Click the Component 4 button on the bottom stowbar to showthe alpha channels for all the images. You will use the shadowlayer’s alpha to build up a shadow in the layered image later inthe lesson.Click Show All Planes to return to the color channels.Note: The other selected operators are still available throughthe tabs that can be found at the bottom of the Viewerpane. Only four operators can be viewed at one timetherefore one of the original four selected operators wasdropped from the list.4. CREATE SKYIn the Viewer pane press tab > Ramp and MMB-click to add.At first the ramp is not visible because it has been added to oneof the hidden tabs. Click on the ramp1 tab at the bottom of theviewport to display it. Because of the Composite Project settingsthe resolution is automatically 640 X 480.In the parameter pane, change the Ramp to Vertical. Click onthe Points tab and set the Color of Point 1 to a white. Set theColor of Point 2 to a dark blue. Set the Segment 1 Interpolationto Ease Out. This will be used as sky image that will sitbehind the existing background.3. LAYER IMAGESIn the Viewer pane, put the mouse cursor over BGdeep_pic andpress tab > Layer. This image is set as the background layer. Itwill then prompt you to select the Foreground 1 to Layer. Clickthe trail_pic image. Select the shadow_pic image as the Foreground2 layer then the snail_pic image as Foreground 3.RMB-click to accept your selection.Move your cursor over the layer1 panel and press t to focus onthe layered image.5. ADD THE RAMP TO THE LAYERIn the Network pane, click the output of ramp1, wire it intolayer1. In the Viewer pane, click on the Layer1 tab. Notice thatthe ramp has been put in the foreground.Compositing CG Elements 3

Click on layer1 in the Network pane to select it. In the Parameterpane, click on the arrow next to ramp1 four times until it is first inthe list. You can also re-order the layers by dragging and droppinga layer into place. In the Network pane, press l to clean upthe layout.2. DARKEN THE SLIMEWith your cursor in the Viewer pane over the translated slime,type tab > Bright and RMB-click to accept. In the Parameterpane lower the Brightness to 0.6.ADJUST INDIVIDUAL LAYERSEach of the layers connected to the layer COP can be modifiedindividually to enhance their look. These modifications will beinserted as new operations sitting inbetween the existing ones.1. REPOSITION THE SLIMEIn the Viewer pane, press t to see all the selected images. In theNetwork pane, click on the display flag of the layer1 COP thenshift-click on the display flag of the trail_pic COP file to add itto the Viewer pane.With your cursor in the Viewer pane over the slime image, typetab > Transform and RMB-click to accept. After acceptingthe operation the translate handle will appear in the middle ofthe slime image. Use the transform handle to drag the slimeupwards until it is definitely positioned under the snail. Previewthe results in the layer1 view.3. STRENGTHEN THE SHADOWIn the Network pane, Click the display flag of layer1, thenShift+LMB-click the display flag of the shadow_pic layer toview it as well.With the cursor over the shadow image in the Viewer pane presstab > Bright and RMB-click to accept. Deselect the R G andB buttons in the Plane Scope parameter, to limit the effect ofthe Bright operation to the Alpha plane.In the top stowbar in the Viewer pane deselect the ApplyChanges to all Views button. Move your cursor over thebright2 image and press spacebar-x to focus on it. Its namewill highlight in yellow.Select Show Component 4 in the bottom stow bar to see itsAlpha channel while Layer still shows all planes. You can nowinteractively turn up the Brightness and see the immediateeffect on the shadow layer and the final result of the layering.Set Brightness to about 2.5. The alpha for the shadow getsbrighter while the shadow in the layered image gets darker.4. BLUR SHADOWWith the cursor over the bright2 COP in the Viewer pane, presstab > Blur and RMB to accept. Again, deselect the R G and Bbuttons in the Plane Scope parameter.4

COMPOSITING EFFECTSSet the blur Size to 50.5. VIEW THE LAYERED CLIPSLMB-click the display flag of layer1 to view this operation andfocus on the results of the changes made so far.In the Viewer Pane press tab > Vector and RMB-click toaccept. Deselect the R G B and A planes, and delete the * inPlane Scope. Replace the asterisk with N in order to onlyaffect the Normals plane.COMPOSITING EFFECTSIn addition to basic layering effects, you can set up more complexcompositing networks where you add effects such as fog toyour shot or even re-light it using information stored in a DeepRastor file.RE-LIGHT THE SCENEMost of the compositing decisions made so far have been subtleand provide a refinement on the original. Now imagine that thedirector has an epiphany and directs you to change the shot to anight shot. Rather than going back to the 3D scene, repositionlights and re-render, you can take advantage of rendering DeepRastors which contain not only color information but also surfacenormal and point position information.1. INCREASE GENERAL RASTER DEPTHTo relight the scene, you will need all the pixels to be set up as32 bit Floating point. Select Settings > Composite Project...and set the Pixel format to 32 bit FP. Click Accept to convertall of the images in your project. This higher raster depthwill provide more accurate results when you apply the newlights.2. NORMALIZE VECTORSIn the display controls in the top stowbar change the displayfrom C to the N plane. This displays the normals created by theDeep Raster options when these images were rendered. Normalsdescribe which direction each point of the geometry is facing.You will need Normal (N) and Point Position (P)information if you are to relight the scene. The current normalswill work properly, but it is a good idea to make the normals uniformso you can visualize them better.3. ADD FRONT LIGHTChange the display plane back to C (color). In the Viewer pane,press tab > Lighting and RMB-click to accept.Tip: At top right of the Houdini workspace there is a buttonthat says Always. Click once of this to change it toNever. Now Houdini will not re-cook the operators asyou change parameters. You can add a whole series ofchanges then press Update to see the results.Under the Light tab, set the following parameters to positionthe light:Surface Type to Point and Normal Maps.Position to 0.3, 1, 0.5;Attenuation to 4;Direction to 0, -0.8, 1;Cone to 10;Cone Falloff to 15.Compositing CG Elements 5

4. ADJUST ATMOSPHERIC EFFECTThe light is now positioned, but you still need to adjust the rolloffand photon scattering. Click on the Lighting tab and set thefollowing:Add to Original Color to Off.Ambient to 0.1, 0.1, 0.1, 0.1;Diffuse to 0.7, 0.7, 0.6, 0.7.These settings define the new light and use it in place of theexisting lighting values. Click on the Volumetric tab and adjustthe following:Atmosphere Scatter to 0.25;Light Falloff to 10;Ray March Step to 0.2.Click Update to see the how these settings create a new lightingeffect. These values came from a creative exploration andyou may want to change them if you want to explore an alternativelight setup.With the cursor over color1 in the Viewer pane press tab > VEXFilter. RMB-click to accept. Change the VEX Function tozexpand by clicking on the selection arrow for this field. Nowthe Depth information has been converted to 3D point information.Click Update.Click the display flag on light1 to show this node only, andselect it as current if it is not already.7. CREATE BACK LIGHTNow you will add a second light to illuminate the shell a bitmore. In the Network pane, press Ctrl-c then Ctrl-v to copyand paste the light node. Set the display flag on light2 only. Setlight2's parameters. Under the Lighting tab:Ambient to 0, 0, 0, 0;Diffuse to 0.5, 0.5, 0.4, 0.5;Under the Light tab:Position to -0.8, 0.5, 1.4;Attenuation to 2;Direction to 0.55, -1, 1.7;Cone to 30;Cone Falloff to 20;Under the Volumetric tab:Atmosphere Scatter to 0.1;Light Falloff to 3.Click Update.5. ADD Z-DEPTH PLANE TO SKYIt is subtle but the sky is not being lit properly. This is because,unlike the other images which were rendered with Deep Rastersettings, the sky ramp has neither a P nor an N plane.Shift+click on the ramp COP’s display flag to view it alongsidethe light COP in the Viewer pane. With the cursor over theramp COP in the Viewer pane press tab > Color. LMB-clickon the ramp image to select it to add to, then RMB-click toaccept.In the Parameter pane, click on the Image tab and set AddPlane to Z. This will add a Z-depth plane that will tell Halo howfar back or forwards to place it in the scene. Under the Colortab, set the Scalar value to 20. This will place the ramp wellbehind our scene. Click Update.6. CONVERT DEPTH PLANE TO POINTS8. LAYER LIGHTING COPSShift+LMB-click in light1's display flag to view both Lightingnodes. In the Viewport press tab > Layer, it will select onelayer as the background. LMB-click on the other image toselect it as foreground and RMB-click to accept. Set the displayflag on layer2 only.6

COMPOSITING EFFECTSChange the Global Operation to Add. Set the display flag onlayer2 only then click Update.Click Update.In the Network view. press l to organize the operators.2. CREATE DEPTH PLANEIn the Viewer pane press tab > Depth of Field and RMB-clickto accept. By default this has created a new plane for us calledM, which creates and alpha-like channel based on the Pz plane.Change the display to the M plane.CREATE FOG AND DEPTH BLURYou can also use the depth information found in the shot to adda fog effect. This will provide some atmosphere to the image.1. CREATE FOGIn the Viewer pane press tab > Fog and RMB-click to accept.Click on the Layer tab and set the following:Layered to Y Layered (Below), this will create a groundmist effect;Layer Edge to -3;Layer Falloff to 9;Falloff Function to Ease Out.Go back to the Fog tab and set the following:Fog Type to Additive Fog;Fog Density to 0.01;Fog Color to a dark grey - around 0.36 in all fields.If you have a fast enough machine and you set Updating back toAlways, you can interactively change the Focus Distanceslider and watch the effect in the Viewer pane. When creatingmasks it is important to note that the whiter an area is, the moreeffect a masked operation will have. An area that is black willnot be affected. Set the Focus Distance to 2.5, and theDepth adjust to 1.1.Compositing CG Elements 7

3. ADJUST DEPTH PLANEIn the Viewer pane press tab > Contrast and RMB-click toaccept. Click on the Mask tab and turn off the Plane Scope forR, G, B and A then replace * with M. Set the Global ContrastBlack parameter to -0.05 and the White parameter to 1.5.CONCLUSIONYou now have a basic understanding of how Houdini can beused to composite CG elements. From basic layering toadvanced effects utilizing deep rastor images, Houdini’s compositingtools let you bring together the parts of a shot andadjust it procedurally.4. ADD BLUR TO MASKIn the Viewer pane press tab > Blur and RMB-click to accept.Change the Viewer pane to view the C plane. Change OperationMask to First Input, and the input field to the right to M.Deselect A from the Plane Scope. Turn Accurate Mask Blurto on and set the value to 0.01. Now increase the Size to 30.The Blur has taken the information from the M plane andapplied the corresponding blur to the C plane. Now the snailseems to pop out of the image.5. RENDERIn the Network pane, press tab > ROP File Output, thenLMB-click to accept. Using this node you can render imagesdirectly out of COPs. Click the output of the blur2 node andwire it into the input of rop_comp1. Click the Render button toview the results.8

More magazines by this user
Similar magazines