HELP! compositing transparent object


#1

Hello,

I am currently puzzling my head over how to composite video footage with this semi-transparent “helmet” object I rendered in 3ds max/ vray. I basically want to put the rendered object on a real head. Because the object is transparent, I have to make sure that it looks like the head is inside the transparent object. That means I want to see the front surfaces, but not the ones in the back that would be covered by the head if it was a real transparent object.


Thats how the final object is supposed to look like.

I tried to cut the object in half to render the front side and back side separately. But because it is transparent I ended up with a “seam” and a surface layering that is not quite right.
My tests:


Front side rendered separately.


Back side rendered separately.


Both sides stitched together.

Does anybody has a similar problem? Any ideas or even a solution would be much appreciated. Thanks for your time!


#2

Can I ask why you are cutting it in half? You should be able to composite the original right over the footage no problem, and it will come out the same as the render.

If you don’t want to see the back side (as if the head is blocking the inside so you can’t see the other side), you need to make a holdout mask.

This holdout mask would probably be best done in 3d with a base 3d model matching your person’s head. If you render that as a pure black surface shader with no alpha inside of your cube and have that as part of your render it will cut out the side that isn’t visible from your camera. Then you should get your semi-transparency in the front, while blocking the back from the head inside.

Kind of hard to explain but hopefully a similar technique to this will work. I’m not familiar with Vray or 3ds max but this is how I would go about it in Maya. I’m sure there’s a similar way to do it with those.


#3

Hi Alex,
Thanks a lot for your reply.

This sounds like a good idea. I also thought about creating some kind of mask within the 3d object, but I was not sure about the material settings. It should not be invisible for the camera but block the back part of the object.
You reckon a black material with 0% alpha would still cover the back part of the object if positioned inside the helmet.

Eventually, I will animate it. Do you know if there is a way of exporting a video as a ‘holdout’ mask? Otherwise I would have to do that procedure for every frame.

Thanks for your help!
All best,
Lukas


#4

Are you compositing this over a real persons face? If so, usually I go about doing this by having some sort of object track. Meaning you place tracking markers (dots) on the persons face and then get the motion from it.

Once you have that you can parent your 3d object to the tracking data, etc. Then you render this out as a sequence. You would parent both your helmet thing as well as the holdout geometry with the black / no alpha shader.

You can also hand key this if you don’t have a lot of motion and think you can match it by hand, but I would animate the face black shader object first, and then parent the helmet to that, if you are doing that approach.


#5

I want to use real video footage and overlay the 3d object. the motion of the real footage head will be tracked so that the helmet can be animated according to the movement.

Do you mean I need to also animate the black shader object to match the outline of the person in the video?
Could you please share the material settings for the black shader object with me?

Thanks!


#6

Like I said I’m not familiar with Vray or 3ds, I primarily do work in Mental ray in Maya. Basically it just needs to have a zero-alpha and a black shader. Similar to the “use background shader” in maya, so maybe you can search for an equivalent in 3ds max.

You could also render both halves like you did and then rotoscope the back half, but I’m not sure why you are getting the overlay issue, so I would probably go the other route.

Good luck to you,

Alex


#7

For Vray, to get this holdout geometry rendering correctly it won’t matter what colour you assign it, so long as it’s 100% opaque. All you need to do is assign a default grey Vray material then right click the geometry, go to Vray properties and in the top right of dialogue box tick the Matte Object box and change the Alpha contribution to -1.

This will ensure the holdout geometry does not render but affects the alpha of anything else behind it in the scene from the camera’s point of view.

Hope that helps!


#8

That sounds easy. I will try that.

Thanks GrahamMac!


#9

Hi GrahamMac,
Thanks for your reply. That’s exactly the setting I was looking for.

What would be your strategy to match the video footage with the holdout mask object. Should that holdout object be a geometry or could it just be a simple plane with the mapped video footage?
Thanks for your help
much appreciated!


#10

Stick a 3dplane inside the object and project3d the head (rotoscoped) on it. Make the plane child of your object at least for translation, rotation is not important, it is better to face the camera.
Trust me, you do not want to model the head.