ZBrushCentral

Rendering successful displacement in Maya 2008

Maya 2008 Displacements

It appears that a lot of people are having problems with Maya 2008 and rendering displacement maps. Two major changes have been made in Maya 2008 that impacts the ability to effectively render 32 bit displacement maps.
I did some reasearch and set up a mel script that will set up the scene file correctly. Thanks must go to those who found the problems with Maya 2008 early on. ZBC member marcotronic uncovered the CCMesh change.

The changes that Autodesk made are to the Alpha Detection and the mental Ray export mesh at render time. Maya 8.5 and earlier use Subdivision Surfaces at render time when a subdivision approximation node is assigned. Maya 2008 defaults to the CCMesh or Catmull Clark mesh. This is intended to be faster and support tris, ngons, and quads. The problem is it creates seams in the render.
badRender.jpg

I hope this helps. My thanks to everyone who has shared their experience and fixes on the forum especially marcotronic; who uncovered the new CCMesh primitive on the Autodesk site.

Scott

//COPY THE SCRIPT FROM HERE
// mental ray Subdivision Approximation script

// by scott spencer

//scott@scottspencer.com

//converts all subdivision approximation nodes in the scene from CCMesh to subdivision surface as well as sets the option

// to use maya style alpha detection

optionVar -iv “miUseMayaAlphaDetection” 1 -sv 1 1; //sets maya style alpha detection - mthe same as

// checking the Alpha is Luminance box in the file node but this works for all displacements in the scene

string $selected[] = ls -type mentalraySubdivApprox; // selects each subdivision approximation node in the scene and adds to an arry

int $size = size ($selected); // creates the counter variable

for ($a=0;$a<$size;$a++) //increments thru the array

{//beginning of loop

string $name = $selected[$a]; // this variable accesses each element of select using $a as an index

addAttr -ln “miExportCCMesh” -at bool $selected[$a];

}

//END OF SCRIPT

Attachments

bloat.jpg

sriptIcon.jpg

screen.jpg

shelf.jpg

goodRender.jpg

editor.jpg

Thanks a bunch for this it will help a ton.

thanks a lot, right now i did my first (good) displace render with sss material…
cheers prova.jpg

You are fabulous!!!
the seams were always a huge headache for me, and i could never find out what caused them.

Thanks!

Well Done Scott, well done… :smiley:

A do it all in one Mel script makes the process a whole lot easier than doing it manually via the previous 2008 fix method out there.
Thank you!

Whoever rated this as a 1 has obviously never touched ZB or MAYA before. Awesome tutorial for an otherwise complicated issue. Displacement seams = huge headache.

Hi Scott, Please Could You Tell Me, The “expression String” That You Wrote On Your Videotutorial Under The “alpha Gain Offsett” Node???
Thank A Lot
Marco

Oooh! Thank you very much! A wonderful all in one script!!

Many Many thanks, as usual…

you have no idea how helpful and timely this is!!!

mr co

= - filenodename.alphaGain / 2;

No problem guys, Im glad it helps. I took a LONG time to move to Maya 2008 and when I did I put this together. Figured I would share it here.
Now I need to update the displacement guide and my Gnomonology tuts.

Thanks Again!

S

You’re awesome Scott! Thanks for sharing the love! :slight_smile:

Ryan

Silly question:

Is there a version of Multi-Displacement for ZBrush 3.1?

I have been looking without any luck :frowning:

Thank you so much for that!

also thanks to marcotronic who spotted the subdivision approximation node bug in the first place.(that was a hard one to find!)

Elixir: It comes as part of ZBrush 3.1 Its under ZPlugin : )

Cheers,

Scott

. . Hey Scott,

Thanks for that info from you and marcotronic. One less headache @ wk in the Maya experience of ‘New Version Bugs’.

Dan

:+1:
Gnom. Anat. Class

As always some good stuff. Thanks Scott

Hey Scoth, thanks a lot for the great script and tutorial.
Speaking of your Gnomonology tuts. When are you goin to make the second part of the zbrush-maya disp. maps for extracting and applyng multiple disp. maps on a single mesh?

I can apply multiple disp. maps plus SSS in maya to a single mesh with diferent UV regions but with ctrl_multidisplace. I will like to do that with just maya node and shaders

About the script…i suppose that i don`t have to copy also the line //COPY THE SCRIPT FROM HERE…but i have to copy from the next line…
sorry…just checking…

Best Regards

I’m still getting seams ?? have your gnomonoloy video to and followed it. Any one see somthing I missed? I tried 8 and 16 for boarder settings and adaptive and dpsub and auto map in maya
settings.gif

Attachments

render.jpg