To be sure to be well understood, imagine a scene, composed of a sphere with a ICE Cloud Particle around the sphere. The lightmap shader is only attached to the sphere (not to the ICE Cloud). When the lightmap compute his illumination, it casts shadow rays (and / or secondary rays depending of the sphere material), those rays hit the ICE Cloud Particle, and MR call the ICE Cloud Particle's geoshader / material for each ray. Even if I can put a completely transparent shadow shader on the ICE Cloud, which solve the problem of the color illumination, those calls are time consuming : the lightmap computation is more than 1000 slower when the ICE Particle is present.
So yes, maybe if I could put a custom attribute (like the classic visibility flags) on ICE Clouds which tells to MR to simply ignore them when casting ray in lightmap stage (the rays would traverse them as they wouldn't exist), it would be perfect, but I don't know how to do it. But I am not sure, maybe I ask something that the translator or even MR don't allow ? Rémi 2012/8/14 Chris Chia <chris.c...@autodesk.com> > What I would do is to have your lightmap algorithm look up for an custom > attribute in the scene and see what needs to be eliminated from > computation?! This would be a hack to solve your unique rendering > requirement ;) > > Chris > > On 14 Aug, 2012, at 9:55 PM, "Rémi ARQUIER" <arqu...@gmail.com<mailto: > arqu...@gmail.com>> wrote: > > You are right, the ICE Particles cloud are not evaluated for the lightmaps > (they don't affect lightmap illuminaton). > > I would want to compute the lightmaps and the final rendering in just one > click on "render". Not using two passes. Lets say that mental ray in "one > click on render button" decompose the global rendering into two consecutive > stages : > > Stage 1 - Lightmap computation. The lightmaps, applied on polygon meshes > compute some custom user data (whatever) and store them into ram. > Stage 2 - Tile Rendering. Other shaders read the custom user data from ram > and use it for final illumination of the ICE Particle Clouds. > > In stage 1, the ICE Particle cloud *must not* be presents for casting ray > speed optimization. > In stage 2, the ICE Particle cloud *need* to be present since they are > visible by all rays. > > > 2012/8/14 Chris Chia <chris.c...@autodesk.com<mailto: > chris.c...@autodesk.com>> > My qn is: why does your point cloud need to exist in your 'light map' > pass? Do you mean that the point cloud still needs to be rendered but not > evaluated for light map? > > Clear my doubt... > > Chris > > On 14 Aug, 2012, at 8:39 PM, "Rémi ARQUIER" <arqu...@gmail.com<mailto: > arqu...@gmail.com><mailto:arqu...@gmail.com<mailto:arqu...@gmail.com>>> > wrote: > > Thank you Chris > > Breaking the scene into two passes would solve that specific problem but : > > 1/ Our custom lightmap shader creates custom data (mental ray point > clouds, not maps) and keep them into ram. It would be inefficient to save > them then reload them using hard disk. > > 2/ We already use passes in our workflow and it would complicate it to add > other ones just for a shader. We need something "transparent" in the user > side. > > > > 2012/8/14 Chris Chia <chris.c...@autodesk.com<mailto: > chris.c...@autodesk.com><mailto:chris.c...@autodesk.com<mailto: > chris.c...@autodesk.com>>> > Why can't you break your scene into passes? With the point cloud hidden in > the "light map pass"? > > Chris > > On 13 Aug, 2012, at 10:20 PM, "Rémi ARQUIER" <arqu...@gmail.com<mailto: > arqu...@gmail.com><mailto:arqu...@gmail.com<mailto:arqu...@gmail.com>>> > wrote: > > > Hi list > > > > I would like to know if it is possible to exclude objects in the ligtmap > rendering stage. Specificaly I would like that some of ICE particle clouds > not be seen by object beeing sampled (for reflection rays and shadow rays > for example). > > > > I have tried combining a mip_rayswitch_stage plus a transparent shader > for the lightmapping rays on the particle material. It works, *but*, the > presence of the clouds considerably slow down the lightmap rendering stage > since the particles are still hit (by shadows and secondary rays and for > nothing). A "rendering lightmap visibilty flag" excluding the cloud for > real would be perfect, but doesn't seem to exist. > > > > Any idea ? > > > > I could write some custom MR shaders and custom plugins if necessary. > > > > Thank you for help > > > > Rémi > > >