|
To render dispersion a little trickery is required. Carrara doesn’t know about multi-spectral light, so what we do is fake it out. Physically, what creates dispersion is a shift in the refraction values at different wavelengths. What we do in this process is to animate the refraction properties of the object we are simulating, and save the data as a sequence of images that we will then combine by averaging to form a single final image. Don’t worry, the shader will do all the heavy lifting. So here is the drill, assuming your scene is all set, and all you are doing is setting up the shader for your object: 1) Make sure you are at time 0!! 2) Add Fresnel to your Reflection and Transparency channels, and set the Mode to the corresponding channel. Use the pulldowns to set your Medium and Object Material. Set the Object to reference as your rendering camera. In step 5) we will use the “n2rd” value in the Calculated box as the index of refraction using Smart Pack/Index of Refraction/Other for CS3, or Index of Refraction/Other for CS4. 3) Check the color box in both channels. This will color the object according to its reflective and transparent properties that are correct fot its refraction relative to the incident medium n1 for the color of illumination set by the wavelength slider. 4) Slide Wavelength slider all the way to the RIGHT, both channels.The bezier tweener used to animate the index of refraction is increasing, so we need to start at the lowest refractive index, which corresponds to red. Refractive idex decreases with increasing wavelength of incident light; thus we render from red to violet. 5) Copy the n2rd value in the Calculated box to the Refraction channel “Other” value. 6) Go to the assembler room. Move the scrubber up to 6 seconds on Time line. Set your frame rate to 3 frames/sec. (any combination that gives you at least 12 frames should work.) Make sure to set your render timeframe from 0 to 6 seconds.If you want a smoother spectrum, generate more frames. 7) Back to the shader room. Move the Wavelength slider all the way to the LEFT, both channels. Copy the n2rd value in the Calculated box to the Refraction channel “Other” value. 8) Pop back to the assembler room. Open the tweener detail for your shader. You should have three tweened values-Reflection, Transparency, and Refraction. Set the first two to Linear tweeners. Set Refraction to a Bezier, with Ease In-Out at 0-100, and Tighten In-Out to 60-100. 9) Render the animation.Don’t forget to check the boxes for reflection, refraction, and transparency, and light through transparency. For best results, use full raytracing and gamma correction. 10) Save the animation in whatever format you need for the next step. 11) Combine all the images by averaging. |
||||
|
There are lots of ways to average- here are a couple. You can use ImageMagick which is freeware, available on both PC and Mac. Once you’ve installed it, you can use this batch file (for PC, you’ll need to do your own for Mac) to average the example file. This assumes you save with the name Disp.bmp, and use the default Premiere numbering system for the multiple frames. It is pretty straight-forward to modify the file for other names and data set sizes, if you want. Just put it in the directory where you save your images. I recommend using a sub-directory to keep from cluttering your main directory. Alan uses bTVPro for the Mac, which can do MUCH more than this function. It has a built in averaging function for use on Quicktime files. |
||||