Visible seam in displacement with Mental ray – Tutorial

Number of people ran into this problem where you notice a tear in the displacement when rendered with mental ray.
If you take a closer look at the render you will notice that this tear appear at the UV border edges, and that is due to the fact  that the sub-division approximation is smoothing the UV brooders, that’s why the displacement edges don’t match anymore.
mentalray CCmesh ON

.
To fix this problem we need to disable this new method of approximation called the CCmesh, by running this MEL command
addAttr -ln “miExportCCMesh” -at bool mentalraySubdivApprox1;

where “mentalraySubdivApprox1” is the name of your approximation node.
However this comes with  price, the CCmesh is much faster node to render  and once you disable it. You will get a hit at render time.

mentalra CCmesh Off

Recent Entries

8 Responses to “Visible seam in displacement with Mental ray – Tutorial”

  1. Sean Says:

    HI, when i use the line of mel

    addAttr -ln “miExportCCMesh” -at bool mentalraySubdivApprox1;

    the next time i render, it appears to have disabled the smoothing so it renders the displacement map on my unsmoothed model, then if i uncheck the attribute and render again the smoothing is back on but with the visible seems again. I tried it on a plane and it worked fine. Can you think why this might be happening on my mud box model.

    cheers

  2. Ashraf Says:

    Yes, this MEL will disable the CCmesh. as long as your approximation node is called “mentalraySubdivApprox1″
    check the name of that node on your model. and make sure its the same. you might have it called “mentalraySubdivApprox2″ or 3. depending on your scene.

  3. Brandon Webb Says:

    can this also be overcome by leaving the ccmesh active and using the “smooth uv’s” option when baking in mudbox? will they smooth in the same way so as to line up? I’m going to give it a whirl i had a mesh with this issue a little while back, ill post back.

  4. Ashraf Says:

    Unfortunately these are 2 different algorithms. You would still get the seams.

  5. Lindsay Tmms Says:

    Hey, i found a pretty annoying but effective workaround for this problem, if i take my lvl 0 mesh from mudbox, export it to maya and smooth it to the correct subD to match my uvs in mudbox then use this smooth mesh as the target when exporting displacements from mudbox, it uses the smooth uvs to generate the displacement

  6. Saf Says:

    Hi this command don’t work for me :( I am rendering with MR too

    // Error: Found no valid items to add the attribute to. Got a small displacement seam on my mesh. Help me if you can please ? :)

  7. Ashraf Says:

    Sometimes the copy and paste can be wrong
    try typing the actual command on your side

  8. Chrix Says:

    Works great! The only thing that I needed to change from the copy/paste was the quotes (“” instead of “”)

Leave a Reply