phantom vex variable
3576 6 0-
- zdimaria
- Member
- 390 posts
- Joined: Jan. 2012
- Offline
-
- symek
- Member
- 1390 posts
- Joined: July 2005
- Offline
zdimaria
is there any way to have different phantom settings in different deep rasters?
Kind of. Phanton simply says mantra, don't even bother to run surface shader for primary rays, assume object's opacity is {0,0,0} in that case.
You can model your shader similarly per AOV basis by multiplying every export with opacity computed with getraylevel(), so whenever getraylevel() returns 0, you are at phantom phase (Of={0,0,0}), otherwise… whatever you wish.
-
- tamte
- Member
- 9380 posts
- Joined: July 2007
- Offline
I'm not sure that will work, this method can be used to get phantom behavior and much more for sure, but I doubt that you can do this per AOV as I think all AOVs share the same opacity ( correct me if I'm wrong )
so if your diffuse is invisible to camera rays and you want your normal pass to be visible for camera rays, multiplying diffuse with 0 for primary rays will give you just black for that object, it will not be transparent, and if you set opacity of your shader to 0 for primary rays your normal pass will be gone as well.
(the possible way may be setting the Sample Filter for AOV to Closest Surface, but I don't think it will do any good, it's lot of problems expecially with cut out opacities)
so if your diffuse is invisible to camera rays and you want your normal pass to be visible for camera rays, multiplying diffuse with 0 for primary rays will give you just black for that object, it will not be transparent, and if you set opacity of your shader to 0 for primary rays your normal pass will be gone as well.
(the possible way may be setting the Sample Filter for AOV to Closest Surface, but I don't think it will do any good, it's lot of problems expecially with cut out opacities)
Tomas Slancik
CG Supervisor
Framestore, NY
CG Supervisor
Framestore, NY
-
- symek
- Member
- 1390 posts
- Joined: July 2005
- Offline
-
- tamte
- Member
- 9380 posts
- Joined: July 2007
- Offline
try it with more objects on top of each other
are you able to get full AOV color of the object closest to the camera? in my experience in “Full Opacity Sampling” the samples are mixed together if the opacity is not 1 and since you cannot have it on 1 due to faking phantom for diffuse, they will mix
only the “Closest Surface” works kind of correctly apart from mentioned problem, but only if opacity is not 0 so like 0.000001
but maybe there is something I am missing and it works somehow, but I don't see the option of specifying opacity per AOV
are you able to get full AOV color of the object closest to the camera? in my experience in “Full Opacity Sampling” the samples are mixed together if the opacity is not 1 and since you cannot have it on 1 due to faking phantom for diffuse, they will mix
only the “Closest Surface” works kind of correctly apart from mentioned problem, but only if opacity is not 0 so like 0.000001
but maybe there is something I am missing and it works somehow, but I don't see the option of specifying opacity per AOV
Tomas Slancik
CG Supervisor
Framestore, NY
CG Supervisor
Framestore, NY
-
- zdimaria
- Member
- 390 posts
- Joined: Jan. 2012
- Offline
-
- symek
- Member
- 1390 posts
- Joined: July 2005
- Offline
-
- Quick Links

