Forests in maya mental ray.


#861

I watched the video, Dario, but didn’t catch the trick to instancing groups? If I can get this to work, I don’t have to Combine my trees, and will have the leaf groups be separate objects still - this would totally rock.

In other news, I realized this week while playing an old adventure game where we’ve all seen SpeedTree in action. Oblivion uses SpeedTree! And it’s amazing for realtime trees, obviously. Have mine a bit modded out to use even higher-res textures and a much farther draw distance than stock Oblivion, and it’s excellent. But even if it would work great with mental ray, the trees are too Vue-ish in quality to be considered realistic, really.


#862

Hi
The paint effects group as you know, not instanced with spPaint3d, so you not able to distriduited that on your place ground. spPaint3d run with single mesh. Try it and say me if you are able to distribuite the painteffects trees in ground with rotation random scale well. You get an error, error in distribution, leaf in a place and main in an other place. With this workflow, you ditribuited it well.
I’m not talk about combine trees, the painteffects are the same. leaf and main and flower in a group


#863

I read somewhere that ILM used SpeedTree for the Avatar intro of the movie (the camera flight above the jungle) and Weta later used their trees for the movie itself.

@ytsejam1976 thanks for the tip but this solution doesn’t work for duplicating binaryproxies with the geo shader or does it?


#864

Yes

Uploaded with ImageShack.us


#865

:applause: :buttrock:

thanks for that… xD especially for grass this is soooooo nice.


#866

@Dario: Just re-watched it and paid closer attention - you are a genius, my friend! This is so helpful, it just changed my entire workflow and makes my trees and plants so much easier to work with! You’re the best, thanks a ton… Can’t believe I didn’t think of this too, it seems so obvious, but I guess I thought that parenting them wouldn’t necessarily mean intanced duplicates, but it obviously works fine!

@m0z: Indeed, SpeedTree is a great technology, but still lacks a few functions I require for realism, such as sky-sensitive leaves, etc. My guess is that it can do all those things, but for the sake of a game like Oblivion, it’s not necessary and would hamper framerate and GPU performance, especially back in 2005 when it came out. Not a big fan of Avatar, but I suppose they looked good, at low resolution flying past the screen so fast you don’t need a bunch of detail. Good enough for film, anyway!

But SpeedTree costs more than Maya, so it’s kind of out of the question for personal work or a small studio even. Not as pricey as the Unreal Engine licensing, so I imagine if you were doing a video game with CryEngine or Unreal, the price of SpeedTree would be negligible in the budget really. And of course the Avatar staff had no problem funding it.


#867

true. I stick to paintFX anyway. There’s this nasty sun-direction bug with the leaves in 2011 and I read here that Duncan mentioned it’ll be fixed in 2012. Maybe I don’t get it but afaik it behaves just the same?

edit: just tried the “parent” trick - absolutely perfect :smiley:


#868

@InfernalDarkness
Thank you. Is possible to use your feedback on my linkedin account :slight_smile:

@moz
The leaf at sun run on maya 2012. Now, it’s possible to control the leaf normal direction for a good result.


#869

I don’t know about that, the “Leaf Forward Twist after converting to polygones and putting the camera high above” hack works better for me :surprised Any suggestions? Does the branch twist or other values influence the leaves to not face the sky? There’s obviously something I’m doing wrong because I don’t see that much difference between 2011 Leaf Facing Sun and 2012.


#870

The problem that was fixed was that leaves were flipped for odd branches. Thus on these ones they would be facing down instead of up. In general this is more noticable if you had some bend to shape the leaves, or if you had two sided shading. The forward twist technique suffered the same problem before 2012 as well, with some face normals pointing up and some down. Note that if you use the forward twist technique then I think the bend effect on the leaf does not work so well, but perhaps you have some bend yet prefer the flatter look?? Other than that I’m not sure why you might be preferring the twist method.

Duncan


#871

In fact i have much great Trees and leaf with “Leaf Forward”.

@Dunkan. For the future, something like a create your trees and branck base on Curve, for modelling the trees?

Ciao and good work


#872

(Talking about Paint Effects)

I’d really like to see an option for making a non-overlapping branch connection, mainly for higher res models.
Another great improvement would be the power to decide what comes first between branches twigs, leaves, and flowers in any order (yes also flowers). Something like Branches after Twigs but broader in the system. And lastly an integration with the particle system using particle instancing. Oh yes, I was forgetting native MR integration…
Yeah I’m dreaming…


#873

I’m trying to simulate a cloudy day but I can’t get my leaves to be translucent. I’m using an IBL+Final Gather because it gives me nice soft shadows but when I load the render pass set to “translucence” it’s always black.

Has anyone one found a way to do it?


#874

I’ve been trying to find the time to generate an example but thought in the meantime I’d point it out in here:

You can use the User Data shaders in 3.9 to better manipulate your instances with different values tied to a single shader. So now 200 trees can look different while maintaining the same shader.

Add this to the better texture caching and you should be able to render much MUCH more than before while simplifying the workflow. Below is an example given to me that uses instanced tulips. The flower petals all share the same shader but render with different colors.


#875

that is nice, how to setup the User Data shader?


#876

http://kiryha.blogspot.com/2011/04/userdata.html


#877

Actually that’s not the issue here. When normals are flipped and you are using Fresnel reflection, bounces off the back of the material receive the inverse of that number. For example if you had a water shader applied to a plane that you were using as a pond:

  • Looking from above the plane down into it, you get a refractive index (and the resulting Fresnel reflectivity that goes along with it) of 1.33.
  • Looking from below the plane through it to the sky, you get a refractive index of 0.75 (1 / 1.33).

The way to circumvent this issue in MR for your trees and leaves is to use your own BRDF definition instead of Fresnel. Ie: turn off use Fresnel and just plug in arbitrary values into BRDF 0 and BRDF 90. It’s not quite as physically accurate, but it’s better than turning off backside reflections or getting insane chrome reflection levels due to your IoR inverting thanks to normals.

Alternatively (I haven’t tested this yet) you may be able to simple plug in a Fresnel mapping into the BRDF 0 and BRDF 90 attributes to maybe attempt to override the fact that Mental Ray accurately deals with the normals and reflections.

99% of the time, it’s an absolute blessing that it handles them the way it does. 1% of the time, you wish there was an override in the Mia_X shader called “Fresnel normal ignore” or something.

Extremely informative thread guys. Pleasure to read and see everyone being so helpful towards each other.


#878

An other topic:
I’ve been using Onyx for a dew days now and I think it’s awesome. Although the max plugin isn’t as stable as the standalone software. But if I’d like to export it from max to maya with the wind - does FBX take care of animations or do I need a per frame baked proxy mesh? If so: a MR proxyfile created in max should work in maya too right? I’m talking about the binaryproxies btw.


#879

…While we’re discussing Onyx: Is there a way to export trees and grass from Onyx into Maya at actual scale?
I’ve noticed that if change the units in Onyx to “feet”, a larger version will exported but it’s still far too small.

Is there a way to export an Oak tree that’s 60 feet tall within Maya?


#880

@Dangertaz: Sorry I didn’t respond more promptly, guess my inbox was full here or something.

As for scale, I’ve found very little in the way of unifying scale externally then bringing it into Maya. What I’ve been doing when it’s necessary is importing the .obj into Rhino first, then re-exporting it back to Maya after properly rescaling the trees and flowers, etc. Not exactly the easiest way to do it.

But 60 feet = 18.28 meters, so you could start there inside Onxy? That should give you the complexity and leaf-scale you’re hoping for.