Show in Contents
Add to Favorites
Home: Autodesk Maya Online Help
Open the third scene for the lesson
Lesson 3: Creating a liquid simulation with nParticles
Assigning material shaders
Render your liquid simulation
In this section, you render your nParticle
effect using the mental ray for Maya renderer. Since rendering a
particle effect can take several minutes to an hour, in this lesson,
you only render selected frames of the simulation. Rendering simulated
frames is the easiest way to see how some attributes affect your simulation.
To prepare your scene
for rendering, you assign mental ray mia_material_x shaders
to the pitcher, glass, and water meshes. Lights have been created
and placed in the scene so that realistic shadows and reflections
appear in the rendered frame. The scene also includes a camera named renderCam that
is positioned for the rendered view. For more information about
rendering, see the Rendering and Render Setup guide.
Preparing to render
To prepare your scene
and workspace for rendering, you will do the following:
- Cache your simulation so that you can
play it or scrub through it to locate the simulated frame you want
to render.
- Change the view arrangement of your Maya
workspace to make it easier to assign material shaders to meshes
and view rendered frames of your simulation.
- Show hidden light objects and the camera
you use to render a simulated frame.
To cache your simulation
- In the Outliner,
select nParticle_Water.
- Select
nCache > Create New Cache > .
The Create
nCache Options window appears.
- In the Create nCache Options window,
do the following:
- Set the Cache directory to
the folder where you want your caches saved.
- Set the Cache name to LiquidSimulationCache.
- For File distribution,
select One File.
- Click Create.
- Go to the beginning of the playback range.
To change the view arrangement and display
hidden objects
- Select Windows > Saved
Layouts > Hypershade/Render/Persp.
The Hypergraph,
Render View, and the current perspective view are displayed. This
view arrangement makes it easier to assign shaders to your objects
and to view rendered frames of your simulation.
- Open the Outliner in
a separate window by selecting Window > Outliner.
- Hide the nParticle_ Water object
by selecting it in Outliner, then selecting Display
> Hide > Hide Selection.
- Show the Water_Mesh object
by selecting it in the Outliner then
selecting Display > Show > Show Selection.
- In the Outliner, -click
the main, rim, and fill lights,
then select Display > Show >Show Selection.
The lights used for rendering
the simulation appear in the scene.
- In the perspective view, select Panels
> Perspective > renderCam.
You now view the scene
through the camera that you will use to render.