ZComposite

   5227   6   0
User Avatar
Member
325 posts
Joined: July 2005
Offline
http://img99.imageshack.us/my.php?image=compz6ot.png [img99.imageshack.us]

Greetings everybody,

I have run across a strange issue. I've got a very simple scene: a cube and a sphere, each rendered separately in *.picnc file with Pz (DeepRaster) channel. Then I try to compose them in HALO. Again - the simplest setup: 2 File nodes (bar_z.picnc and ball_z.picnc) - piped into ZComposite node.

As you can see from the image - we can see the contours, emanating through the objects' surface, which is not exactly what is expected…

It seems that either in HALO or it happens during the rendering - but the contours of our geometry receive wrong Z data. That is - Z data on the borderline “object<->outer_space” is wrong. And we get a pronounced object contour, as a result.

How can this situation be solved? I tried to supress the “Z channel” - so that I literaly deleted all the Z data in one of the objects - and then used the offset in ZComposite node. This works in some way - but is this the only walkaround?

Thanks.
I liked the Mustang
User Avatar
Staff
5156 posts
Joined: July 2005
Offline
In the Deep Raster page of the mantra ROP where you've specified Pz as an output channel, make sure than ‘Enable Filtering and Blending’ is off. Otherwise, it'll antialias the Z data along the edges depending on the coverage ‘A’:

Zout = Zfg * A + Zbg * (1-A)

In your example, Zbg will be zero (since there's nothing behind the block). This will cause your edges to become closer to the camera than the rest of the block - definitely not what you want.
User Avatar
Member
325 posts
Joined: July 2005
Offline
so, you mean that I simply must turn off filtering and it should work?
I liked the Mustang
User Avatar
Staff
5156 posts
Joined: July 2005
Offline
Yes, just for that deep raster channel. You can still filter color & alpha, and other deep raster channels if desired. This will keep you image quality looking good, but remove the Z artifacts.
User Avatar
Member
4140 posts
Joined: July 2005
Offline
I've never used zdepth compositing for intersecting geo - I would think that in the same way you could see the AA edges peeking through in that test, any intersecting lines would likewise *not* have any AA, and would buzz, wouldn't they?

Cheers,

J.C.
John Coldrick
User Avatar
Member
325 posts
Joined: July 2005
Offline
wow. it works! w00t

Thanks!
I liked the Mustang
User Avatar
Staff
5156 posts
Joined: July 2005
Offline
I would think that in the same way you could see the AA edges peeking through in that test, any intersecting lines would likewise *not* have any AA, and would buzz, wouldn't they?

With the default supersampling of 1, you would get non-AA'd intersections. With a supersampling of 3, they are pretty well blended. Of course, this takes longer (9x in fact), which is why it isn't set as the default (assuming that a lot of Z composites don't have intersecting geos).
  • Quick Links