Duplicating Max's falloff reflection feature?

I want the reflection to falloff after a certain distance. In Max you just tell the reflection to fall off and dial it in. I've tried to cook something up in the rendertree but to no avail.
Anybody have a clue if it's possible?
Ed, Jeremy,....anyone?
thanks.

Plug an Incidence node into the reflection node. Play with the Incidence settings, you should get something like you want.

Bernard Lebel

thanks for the suggestion, however I don't think I explained properly. I not looking to get the edges of my object to reflect. I want my object to reflect the closest object the strongest and gradually fade to the weakest with things that are far away. It's kind of like putting depth fading in the reflections.
Anymore suggestions? Thanks.

I'm no expert in XSI by any means, but I think this is exactly what the "gloss" feature is for in a material's reflection status box. Move gloss up to 1 and adjust the samples up while previewing in the render region until you get results you are happy with.

Jesse

Altough the gloss parameter does that, I find it extremely crappy. Whatever level of samples you put you never get rid of the graininess.

I'm working on a way to acheive the falloff effect. As soon as I have usable results I'll post them :slight_smile:

Bernard Lebel

@@@I'm no expert in XSI by any means, but I think this is exactly what the "gloss" feature is for in a material's reflection status box

Not quite. Gloss is the oversampling of the reflection so your reflections don't all look like perfect in-focus chrome. That is, multiple reflection rays are cast at slightly different directions and averaged to give the final result. The quality of the result is dependent on both the number of oversample rays and the amount of offset applied to the rays. The higher the offset, the more you'll need to sample to keep the gloss from looking grainy. Low offsets can get away with fewer samples because the results returned from the reflected rays won't be very different from each other.

As for the 'falloff' effect with reflections, you'll need to measure the length of the cast reflection ray and knock down it's influence the closer it gets to it's specified max distance. The result is then averaged with the material's diffuse color. I'm not sure if the proper nodes are exposed to pull this off as you'll need access to the child state of the material which contains the data of the reflection ray. Most of the nodes in the render tree only work on the current state, not the parent or child states.

In case you're wondering what a 'state' is, it's a table of data that mental ray uses to keeps track of what's going on during the render (trace depth, current running shader, ray type, current pixel being rendered, etc..). Shader writers have access to this information, but end users do not unless a shader writer creates a shader to expose this information. The scalar_state and vector_state shaders expose a small percentage of what's available in the state.

I don't have XSI in front of me, but offhand I'd say you'll have to write your own shader to create this effect (don't worry, it's not difficult).

Matt


Matt Lind
Animator / Technical Director
Softimage certified instructor:
Softimage|3D
Softimage|XSI
speye_21@hotmail.com