1
$\begingroup$

Thanks for taking the time to hear out my predicament.

So I'm trying to recreate some vg items, nbd, but I'm having trouble finding an answer (let alone a proper title for the question..) as to how you would make materials to jump ahead/in front of other materials like seen with the viewport's "X-ray" feature.

enter image description here Cycles Viewport w/ X-ray on

Here's what I need: a material/object that fazes through another. I've been experimenting and backfacing comes close, but causes unsightly shadows and doesn't really work along the neck of the bottle. Really I'm just wanting the equivalent of what's seen on screen without ruining the basic diffuse, or the red material fazing though other objects besides the bottle.

(Bottle and Liquid are separate meshes)

Thanks again, any help is appreciated.

$\endgroup$
1
$\begingroup$

You can move liguid to second layer and create second render layer. After merge them in compositor.

enter image description here

In this case you can't use Material ID or Object ID, because liquid is in other object, or suzanne in cube in my case. But is good to know there is this possibility. Workflow: use "Pass Index" (material or object) for create mask and after use this mask to separate object in compositor.

$\endgroup$
  • $\begingroup$ Won't this also create overlaps to everything else in the scene? Honestly I don't think there is a working solution to my problem, but I thought'd be worth asking. $\endgroup$ – LanceBeryl Aug 15 '16 at 19:15
  • $\begingroup$ Here's a better example of what I'm trying to achieve. i.stack.imgur.com/0HKsV.png Again, backfacing comes close, but it ruins the look of the diffuse; you have to disable shadows and diffuse in (the object's) cycles settings in order to see it at all. I'm looking to find an effect that works just the same as described: allows one material/object's visibility to through another without doing the same to any other material/object in the scene. $\endgroup$ – LanceBeryl Aug 15 '16 at 19:37
  • 1
    $\begingroup$ @lk321 Yes of course, this overlap all in scene, and that's the point of x-ray. :-) You can play with factor in "Alpha over" node and also you can let liquid/suzanne in both of the render layers. But you must be careful about IOR. Another option is mix transparent shader with glass material. To be honest, now I'm not sure what you need exactly. I know only two possibilities: let liquid "as is" and use glass (or other transparent) material - realistic render, or use method on my image - unrealistic render for show what's inside the bottle. $\endgroup$ – Shubol3D Aug 16 '16 at 14:23
  • $\begingroup$ Maybe you need add another objects, that overlapping liquid. Look what I wrote under attached image - use Material or Object ID for mask, or you can make 3rd layer with objects which overlapping liquid and merge them in compositor. $\endgroup$ – Shubol3D Aug 16 '16 at 14:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.