CGTalk > Software > Autodesk Maya > Maya Rendering
Login register
reply share thread « Previous Thread | Next Thread »
 
Thread Tools Search this Thread Display Modes
Old 09-02-2009, 09:37 PM   #1
royterrrr
Expert
 
royterrrr's Avatar
portfolio
Papillon Papillon
Lighting & Environment Artist
Square Enix
Montreal, Canada
 
Join Date: Feb 2005
Posts: 1,837
mia_material for realistic leaves

After seeing Alessandro amazing work:
http://forums.cgsociety.org/showthr...15&page=1&pp=15

i wanted to achieve a similar effect.Now i never got a response whether he used translucency or not. My guess is yes, so i want to know whats the correct steps:

1-thin walled checked
2-i am using a 0.1 value for trancparency because translucency requires some level of transparency. is that value enough? too high, too low? because when i put it to 1, i get very strong translucency but the material gets a bit dark.
3-translucency weight:1 because the leaves are not transparent.
4-translucency color, should i choose a flat color? or should i plug the same texture as my diffuse slot
__________________
sor.typepad.com

Last edited by royterrrr : 09-02-2009 at 09:39 PM.
 
Old 09-03-2009, 02:50 AM   #2
tharrell
Highly caffeinated
 
tharrell's Avatar
Trey Harrell
Toronto, Canada
 
Join Date: Aug 2004
Posts: 719
Translucency is going to get you half of the way there, but you're likely going to want to do some subsurface scattering and add an extra layer or two of specular (a wide rough one, and a tight one, much like skin).

The preferred workflow for skin & other organics these days is to pipe the output of a subsurface shader as additional color atop an mia_material. You can paint veining in your leaves in the subsurface layer, and turn off the specular and diffuse in your sub layer as well (unless they look good, then keep 'em in

Hope this helps,

--T
 
Old 09-03-2009, 04:29 AM   #3
royterrrr
Expert
 
royterrrr's Avatar
portfolio
Papillon Papillon
Lighting & Environment Artist
Square Enix
Montreal, Canada
 
Join Date: Feb 2005
Posts: 1,837
Quote:
Originally Posted by tharrell
Translucency is going to get you half of the way there, but you're likely going to want to do some subsurface scattering and add an extra layer or two of specular (a wide rough one, and a tight one, much like skin).

The preferred workflow for skin & other organics these days is to pipe the output of a subsurface shader as additional color atop an mia_material. You can paint veining in your leaves in the subsurface layer, and turn off the specular and diffuse in your sub layer as well (unless they look good, then keep 'em in

Hope this helps,

--T


if i plug a sss shader to the aditional color of the mia_material then it wouldn't be physically correct because the mia_material is based on this formula : diffue+reflection+refraction=1. Now if you add an aditional color, it will be added to the overall value and it would be bigger than 1.
Besides, what really happens in the sahder when you plug an sss to the aditional color slot?
__________________
sor.typepad.com
 
Old 09-03-2009, 04:47 AM   #4
tharrell
Highly caffeinated
 
tharrell's Avatar
Trey Harrell
Toronto, Canada
 
Join Date: Aug 2004
Posts: 719
Quote:
Originally Posted by royterr
if i plug a sss shader to the aditional color of the mia_material then it wouldn't be physically correct because the mia_material is based on this formula : diffue+reflection+refraction=1. Now if you add an aditional color, it will be added to the overall value and it would be bigger than 1.


That's absolutely correct. The color of your diffuse + specular reflection can't exceed 1 for it to be energy conserving. You generally dial down your diffuse level to compensate for the piped through SSS, but it won't be "physically accurate".

That said, there's a distinction to be made between "physical accuracy" and "it looks awesome". Most folks using fast_skin are using the diffuse in mia_mat these days and using the workflow that I just described.

Translucence is cheated SSS + transparency by the way, very much not physically accurate.

Quote:
Originally Posted by royterr
Besides, what really happens in the sahder when you plug an sss to the aditional color slot?


In a nutshell, this:

http://forums.cgsociety.org/showthr...?f=121&t=629792

(that's the "skinplus" workflow in 3DSmax -- SSS into additional color on an mia)

Granted it's skin. But look nice and closely at the greens and how they fade into shadow...

--T
 
Old 09-03-2009, 05:29 AM   #5
royterrrr
Expert
 
royterrrr's Avatar
portfolio
Papillon Papillon
Lighting & Environment Artist
Square Enix
Montreal, Canada
 
Join Date: Feb 2005
Posts: 1,837
Quote:
Originally Posted by tharrell
That's absolutely correct. The color of your diffuse + specular reflection can't exceed 1 for it to be energy conserving. You generally dial down your diffuse level to compensate for the piped through SSS, but it won't be "physically accurate".

That said, there's a distinction to be made between "physical accuracy" and "it looks awesome". Most folks using fast_skin are using the diffuse in mia_mat these days and using the workflow that I just described.

Translucence is cheated SSS + transparency by the way, very much not physically accurate.



In a nutshell, this:

http://forums.cgsociety.org/showthr...?f=121&t=629792

(that's the "skinplus" workflow in 3DSmax -- SSS into additional color on an mia)

Granted it's skin. But look nice and closely at the greens and how they fade into shadow...

--T


so you plug your sss shader to your mia_material aditional color slot, why not diretcly the diffuse?

if i get it right: - reflections/specular and part of the diffuse are driven by the mia_material
- part of the diffuse are also driven by he mia_material
- what drives the transparency then?

regarding the hulk thread, wich page talk about the shading network details , didn't find it.
__________________
sor.typepad.com
 
Old 09-03-2009, 05:54 AM   #6
tharrell
Highly caffeinated
 
tharrell's Avatar
Trey Harrell
Toronto, Canada
 
Join Date: Aug 2004
Posts: 719
Generally, instead of using the diffuse component on (say) a fast_skin, you use the diffuse on the mia_material at .3-.5ish contribution instead. You're turning off the diffuse on the SSS mat entirely so that stuff doesn't get blown out, and it maintains some semblance of physical accuracy (ie not reflecting more light than hits it).

Here's a post by Zap (who programmed fast skin and the arch mats) talking about the workflow in 3ds Max... pretty much the same in Maya, except the connections are easier and you don't need a specialized .mi to do it.... maya details are down in the commments section.

Just apply the fast_skin to an object first, so that the lightmaps etc etc are created, and paste them from the fast skin shading group to the mia_mat shading group.

http://mentalraytips.blogspot.com/2...-combining.html

And it looks pretty darned awesome. Used this workflow for an aloe plant on a gig not too long ago and it looked phenomenal.... can't find examples at the moment, but I'll post em if I find them.

--T
 
Old 09-03-2009, 06:12 AM   #7
tharrell
Highly caffeinated
 
tharrell's Avatar
Trey Harrell
Toronto, Canada
 
Join Date: Aug 2004
Posts: 719
Also worth mentioning that you use the diffuse to keep from having to check "use indirect illumination" on your fast skin....

There's been a bug in Maya 2009 and 2010 that SSS lightmaps take an eternity to calculate if final gather is turned on. Of course AD talked it up as a feature... something like "due to more accurate calculations, SSS maps with final gather now take a billion times longer to generate".

Scenes rendering 10x as slow from Maya 2008 to 2009 qualify as a bug to me.

But I digress...

Anyhow, I generally cheat my mia_diffuse a little higher than I should to compensate for the lack of FG contribution in my subsurface, because render times including indirect in my SSS are intolerable.

--T
 
Old 09-03-2009, 10:08 AM   #8
fabergambis
Frequenter
 
fabergambis's Avatar
Fabrizio Gambacorta
3D modeler
Dallara Automobili
Varano de' Melegari (PR), Italy
 
Join Date: Jun 2005
Posts: 171
Send a message via MSN to fabergambis
I usually use a mia_material_x with at least 0.2/0.25 transparency, a 0.95 translucency weight with a solid clear green color instead of the same texture I use for diffuse, otherwise the effect I get is too dark, or you should use a clearer version of the diffuse texture.
Never tested any of the SSS shaders for leaves but in most cases I think the mia should be faster and easier: it depends on your needs.
__________________
www.fabriziogambacorta.com
 
Old 09-03-2009, 03:26 PM   #9
royterrrr
Expert
 
royterrrr's Avatar
portfolio
Papillon Papillon
Lighting & Environment Artist
Square Enix
Montreal, Canada
 
Join Date: Feb 2005
Posts: 1,837
Quote:
Originally Posted by fabergambis
I usually use a mia_material_x with at least 0.2/0.25 transparency, a 0.95 translucency weight with a solid clear green color instead of the same texture I use for diffuse, otherwise the effect I get is too dark, or you should use a clearer version of the diffuse texture.
Never tested any of the SSS shaders for leaves but in most cases I think the mia should be faster and easier: it depends on your needs.


for mid range/ background leaves, i would definitivly use the mia_material with similar values.

tharrell, thanks alot for the info, your method is specially useful for hero objects.
- if i got it right you copy and paste the lightmaps of a misss_fast_skin_maya shader to the mia_material SG.
- drag the sss shader to the additional color of the mia_material
- apply the mia_material to the object.
-turn off diifuse color and weight of the sss shader (what about the overall color slot?)
- play around with the "Subsurface Scaterring layer" values

- But mastezap mentioned that you also should turn off "unscattered diffuse" in the sss sahder. I can't find that section

-did the AD fixed the bug of lightmaps rendering superslow with FG in Maya 2010?
__________________
sor.typepad.com
 
Old 09-03-2009, 04:02 PM   #10
tharrell
Highly caffeinated
 
tharrell's Avatar
Trey Harrell
Toronto, Canada
 
Join Date: Aug 2004
Posts: 719
Yep, you've got it right.

The diffuse that you turn off is the ambient color (leave black) overall color (leave white) and the diffuse color (leave blueish, but turn the weight to 0). It's the block at the top of the node.

The overall color is a multiplier on the entire network, so if you like the look but it's too bright, you can scale it down with that.

Yeah, definitely not suggesting that you put SSS on a billion background objects that you can cheat, but for hero stuff up close to camera it looks really nice.

And no, the bug isn't fixed in 2010... it's a feature now!

--T
 
Old 09-03-2009, 08:50 PM   #11
InfernalDarkness
Madness. Madness, I say!
 
InfernalDarkness's Avatar
portfolio
Sho Pi
CG arch/viz
Seattle, USA
 
Join Date: May 2008
Posts: 5,590
I'm not sure where you're at with this one...

...but if it's a personal (no NDA) project, would you mind sharing your results Roy? As you make progress, I mean. No rush. I'm working on a personal "landscape" project in a similar vein as our hero Alessandro, and having a nightmare of a time with my leaves...

But I have been significantly impressed with MR under Win7 x64 / Maya 2009 x64. Pushing many millions of polys more (at rendertime) than I ever was able to do a year ago. I hope you're experiencing the same luxuries, because when I originally saw Alessandro's work, it truly seemed impossible to do with Maya. Now, it's still impossible to match, but hopefully one can get close to that level of detail and realism!

Anyway, this thread rocks and thanks to all for posting helpful ideas and techniques.
__________________
Commodore 64 @ 1MHz
64KB RAM
1541 Floppy Drive


"Like stone we battle the wind... Beat down and strangle the rains..."
 
Old 09-03-2009, 09:03 PM   #12
royterrrr
Expert
 
royterrrr's Avatar
portfolio
Papillon Papillon
Lighting & Environment Artist
Square Enix
Montreal, Canada
 
Join Date: Feb 2005
Posts: 1,837
Quote:
Originally Posted by InfernalDarkness
...but if it's a personal (no NDA) project, would you mind sharing your results Roy? As you make progress, I mean. No rush. I'm working on a personal "landscape" project in a similar vein as our hero Alessandro, and having a nightmare of a time with my leaves...

But I have been significantly impressed with MR under Win7 x64 / Maya 2009 x64. Pushing many millions of polys more (at rendertime) than I ever was able to do a year ago. I hope you're experiencing the same luxuries, because when I originally saw Alessandro's work, it truly seemed impossible to do with Maya. Now, it's still impossible to match, but hopefully one can get close to that level of detail and realism!

Anyway, this thread rocks and thanks to all for posting helpful ideas and techniques.


Of course!
i did some tests with leaves some time ago and it's generally easy to get descent results with good texturing.
My main focus right now is to model/shade grass like Alessandro's impressing grass, it's much harder than leaves.
Anyways, i will post renders/files regarding the progress for leaves and grass, so that we could join forces.

btw how many triangles are you able to handle in your viewport shaded, textured?
__________________
sor.typepad.com
 
Old 09-03-2009, 09:12 PM   #13
InfernalDarkness
Madness. Madness, I say!
 
InfernalDarkness's Avatar
portfolio
Sho Pi
CG arch/viz
Seattle, USA
 
Join Date: May 2008
Posts: 5,590
Well when you say "handle" it could mean "and still tumble / zoom in this lifetime", or it could just mean total display handling. So far I've hit no limit on how many polys it will display, and my scene may have 10 million or so. But I have to use a great many display layers (PFX_plants_far, PFX_plants_near_right, Poly_trees_far, and on like that) to make the scene functional for zooming and stuff. I imagine the poly-limit / frame-rate factor is similar to gaming performance on this card, which isn't horrible, but if I were pushing the same 10 million polys (faces) in Unreal 3 or Protoype for example it would probably bog down just as much.

But my homestation only has a Geforce 7950GT in it, with 512MB of RAM. Not a "recent" GPU by any means. I'll post a screenshot at some point but I don't intend to hijack your thread, my friend! It's good to know there are others working on similar things, though. Thanks for sharing and for all the tips.
__________________
Commodore 64 @ 1MHz
64KB RAM
1541 Floppy Drive


"Like stone we battle the wind... Beat down and strangle the rains..."
 
Old 09-04-2009, 01:44 AM   #14
techmage
living in maya
 
techmage's Avatar
portfolio
Ryan
USA
 
Join Date: Apr 2005
Posts: 1,076
royterr, this has been a subject on my mind for a long time and something I play around with quite a bit. I would like to know the ideal way to set up leaf and grass materials as well.

I asked allesandro over on evermotion about his mia_material settings for leaves but he never responded. IIRC correctly in a post he did mention he used all mia_material, and I don't remember him mentioning misss. So I assume his plants have no misss shader in the mix. Of course, I could be completely wrong, I have no idea. But from looking at his renders, they do not look like they have misss shaders on them to me. I think it might be very proper adjustment of mia_material settings and colors, and then very well done color correction.

The thin-walled translucency function on the mia_material was designed for exactly this purpose and I do think it offers all that is required for grass blades and thin walled leaves. I mean, the misss shaders don't even calculate properly on thin-walled surfaces do they? I thought they were intended for sealed meshes with volume.

I'll run some tests myself and post them.

Last edited by rygoody : 09-04-2009 at 02:59 AM.
 
Old 09-04-2009, 04:22 AM   #15
royterrrr
Expert
 
royterrrr's Avatar
portfolio
Papillon Papillon
Lighting & Environment Artist
Square Enix
Montreal, Canada
 
Join Date: Feb 2005
Posts: 1,837
Quote:
Originally Posted by rygoody
The thin-walled translucency function on the mia_material was designed for exactly this purpose and I do think it offers all that is required for grass blades and thin walled leaves. I mean, the misss shaders don't even calculate properly on thin-walled surfaces do they? I thought they were intended for sealed meshes with volume.


my intuition also tells me it's the mia_material that has been used in the scene.
it's going te be a tough one but nothing is inpossible.

The first thing i noticed is that the ground beneath the grass is textured with some leaves/soil texture and helps really alot in giving the impression of dense grass covering all the surface.

As for the geometry, i think he started with a PF grass perset and tweaked it alot because i have tried them all and nothing ressembles his grass.

i will post mt tests soon.
__________________
sor.typepad.com
 
reply share thread


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
CGSociety
Society of Digital Artists
www.cgsociety.org

Powered by vBulletin
Copyright 2000 - 2006,
Jelsoft Enterprises Ltd.
Minimize Ads
Forum Jump
Miscellaneous

All times are GMT. The time now is 11:52 PM.


Powered by vBulletin
Copyright ©2000 - 2016, Jelsoft Enterprises Ltd.