Make sure your strokes were created with the PFX tool set to "Paint on Paintable Objects," not "Paint on View Plane."
In the brush attributes, look under Channels. Make sure Depth and Modify Depth are enabled.
In the camera attributes, look under Output Settings. Play with different Depth Type options.
From the Maya docs:
Paint Effects strokes render in the wrong order relative to other objects in the scene
Paint Effects uses the depth buffer generated by the scanline renderer to determine occlusion. For rendered effects where multiple surfaces are visible within a single pixel (such as transparency, antialiased edges, motion blur, light fog, and volume densities) this creates problems, as there is one depth value and one color per pixel to composite paint effects into.
You can affect how the renderer decides how to reduce multiple depth values visible within a pixel to the single output depth value using the camera Depth Type (in the Output Settings section of the Attribute Editor).
With Furthest Visible Depth, Paint Effects strokes lying behind these elements will punch through as if they were totally in front.
Closest Visible Depth picks the surface nearest the camera within the pixel. Thus a transparent surface or motion blurred streak will totally obscure any Paint Effects strokes behind them. The Threshold value determines the transparency at which surfaces will not appear in the depth buffer.
Transparency, transparency maps
In the Output Settings of your render camera, set the Depth Type attribute to Closest Visible Depth and adjust the Threshold.
Antialiased edges
In the Output Settings of your render camera, turn on Depth, then set the Depth Type to Furthest Visible Depth.
Turn off anti-aliasing for your objects, render your objects and Paint Effects strokes at a large size, and then use a third-party software product to reduce the size of your render and resample it.
Transparency, transparency maps, and antialiased edges
Render your Paint Effects strokes separately and composite.
Convert your Paint Effects strokes to polygons.
fangjunning
02-26-2008, 10:22 PM
It turned out that depth in the attribute of the camera was unchecked. Thanks a lot.
FN
CGTalk Moderation
02-26-2008, 10:22 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.
vBulletin v3.0.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.