peliosis Posted August 30, 2005 Share Posted August 30, 2005 So I have them...few hundreds of lights instanced to points of some geometry. I'd really like them to cast some nice soft shadows and I'd really like the shadows NOT to be raytraced:) My question is obvious but I don't have a clue what should I write after the "$" in the name of shadowmap file to automatically generate a different file for each light? Does it look like : "shadowmap.$something.pic"? Bow to all that wish to answer:) Peter Quote Link to comment Share on other sites More sharing options...
Jason Posted August 30, 2005 Share Posted August 30, 2005 If you look in the Light's helpcard, it should mention $IPT - which is the point number to which the light is instanced to. So: /mydir/myshadowmap_$IPT.$F.pic ...is possible. Good luck, Jason Quote Link to comment Share on other sites More sharing options...
peliosis Posted August 30, 2005 Author Share Posted August 30, 2005 Thanks a lot, now it creates the maps but doesn't cast shadows:) I'll play some more to find out what's wrong. By the way... What should I include after the dollar if there are many not instantiated lights, what is the variable for "current light" while creating shadowmaps? Peter Quote Link to comment Share on other sites More sharing options...
deecue Posted August 30, 2005 Share Posted August 30, 2005 $OS should do it.. from the help: " To store the name of the current operator (say in the name of a Z-depth map, you want the name of the light within the filename), you can use $OS. $OS-$F.pic Gives filenames like: light1-1.pic, light1-2.pic, light1-3.pic, etc. Changing the name of the operator (say from "light1" to "light1wHalo") automatically updates the output filenames as well. " Quote Link to comment Share on other sites More sharing options...
Jason Posted August 30, 2005 Share Posted August 30, 2005 Thanks a lot, now it creates the maps but doesn't cast shadows:)I'll play some more to find out what's wrong. A couple more hints: Remember that you must turn on "Autogenerate Depth Maps" from the light you're instancing. Also, you must assign a shadow shader - and the best way to only have a single shader assignment that knows how to index the individual shadowmaps is to use $OBJ in the shader. $OBJ is substituted with the name of the entity (object or light) to which the shader is bound. So, often enough you'll have something like: `chs("/obj/$OBJ/depthmap")` ... in the Shadow Shader's Depth Map field. Play with that for a while Quote Link to comment Share on other sites More sharing options...
peliosis Posted August 30, 2005 Author Share Posted August 30, 2005 Ok, you got me. Thanks It works like a charm, but I still can't find it in help. It's not in "Houdini basics" is it:) P Quote Link to comment Share on other sites More sharing options...
peliosis Posted August 30, 2005 Author Share Posted August 30, 2005 Oh my, thanks guys, I love odforce:) Quote Link to comment Share on other sites More sharing options...
Jason Posted August 30, 2005 Share Posted August 30, 2005 It works like a charm, but I still can't find it in help. 20945[/snapback] No problem... This is definitely something that would be great to have as an Example in the helpcards. What also might be nice is if you can post it Quote Link to comment Share on other sites More sharing options...
peliosis Posted August 30, 2005 Author Share Posted August 30, 2005 No problem...This is definitely something that would be great to have as an Example in the helpcards. What also might be nice is if you can post it 20948[/snapback] I will but I have to feel more comfortable with this stuff and finish my scenes without errors. A moment ago I was sure there have to be a separate shadowmap file for each light. I plan on making some tutorials in the future but I have to gain more knowledge. This software has many gotchas:) Thanks Peter Quote Link to comment Share on other sites More sharing options...
sibarrick Posted August 30, 2005 Share Posted August 30, 2005 Maybe another one for those user help tab wotzits Quote Link to comment Share on other sites More sharing options...
peliosis Posted August 30, 2005 Author Share Posted August 30, 2005 Maybe another one for those user help tab wotzits 20951[/snapback] If you need it Quote Link to comment Share on other sites More sharing options...
peliosis Posted August 30, 2005 Author Share Posted August 30, 2005 There is a strange thing with pointlights and shadowmaps: when I create a pointlight and set it up for depthmap shadows, it doesn't cast shadows in all directions. After switching to cone light, adjusting the rotation and switching back to point, everything is allright. With raytrace shadows pointlight behaves as expected (omni light) That was the cause of my troubles with strange shadowmaps. But why a pointlight works so oddly? There is no reason to use pointlights with depthmap shadows then. Quote Link to comment Share on other sites More sharing options...
Jason Posted August 30, 2005 Share Posted August 30, 2005 That was the cause of my troubles with strange shadowmaps.But why a pointlight works so oddly? 20958[/snapback] The reason is that Mantra does not generate cubic (or raytrace panoramic) zdepth shadowmaps for Onmidirectional lights. This is quite common out there in the world of depthmap shadows for many renderers. Quote Link to comment Share on other sites More sharing options...
peliosis Posted August 31, 2005 Author Share Posted August 31, 2005 The reason is that Mantra does not generate cubic (or raytrace panoramic) zdepth shadowmaps for Onmidirectional lights. This is quite common out there in the world of depthmap shadows for many renderers. 20959[/snapback] Thanks for explanation. I just used max for too long:) Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.