Need help hiding object but still cover another object behind it

Basically what the title is. Ahh I can’t upload image :frowning:
Imagine I have 2 object, a part of object 2 behind object 1, so that part can’t be see , so I hide object 1 and rendered, that part of object 2 became visible but I still want that part of object 2 still can’t be see or it become transparent, can’t I?
ps: sorry for my bad english but plz help me, I can’t continue work on my game:(

Do you mean:


You can hide the yellow cube (still make it renderable) then use a Mask layer so it masks off the area of the blue cube

Or you can set each material a material index, enable the material index pass and use an ID Mask node to make a mask for that material.

oh yes it is. Thank you :o

I have another problem again :frowning: object render so well but when I render using freestyle, it’s still draw black line on hide part, what do I do?

Some one help me please!