sanostol Posted July 13, 2009 Share Posted July 13, 2009 (edited) Hi, I searched but could not find, maybe You can give me a hint. I want to control the anisotropic direction with a texture. something like this. the texture lools like this and the result looks like this: in this mentalray shader the effect is on specular and reflections. I'm stuck Martin Edited July 13, 2009 by sanostol Quote Link to comment Share on other sites More sharing options...
Guest Swann Posted July 13, 2009 Share Posted July 13, 2009 (edited) Just bumping UP. I'm also interested. Edited July 13, 2009 by SWANN Quote Link to comment Share on other sites More sharing options...
DaJuice Posted July 14, 2009 Share Posted July 14, 2009 (edited) This seems to work okay: Radial ramps in COPs tiled & layered over another. The texture is then used to drive the UVs for your anisotropic shader. Edited July 14, 2009 by DaJuice Quote Link to comment Share on other sites More sharing options...
sanostol Posted July 14, 2009 Author Share Posted July 14, 2009 (edited) Might I ask You for a examplefile? My result does look quite crappy Edited July 14, 2009 by sanostol Quote Link to comment Share on other sites More sharing options...
DaJuice Posted July 14, 2009 Share Posted July 14, 2009 Here you go. Make sure to go to the copnet and write out the texture first. aniso_texture.tar.gz Quote Link to comment Share on other sites More sharing options...
sanostol Posted July 14, 2009 Author Share Posted July 14, 2009 (edited) mh, it seems i missunderstood the conzept I thought that the shader needs a u and v coordinate to do the pattern. but it seems You plug the same gradient in all coordinates wired but working but what about reflections is it possible thanks Martin Edited July 14, 2009 by sanostol Quote Link to comment Share on other sites More sharing options...
Jason Posted July 14, 2009 Share Posted July 14, 2009 mh, it seems i missunderstood the conzept I thought that the shader needs a u and v coordinate to do the pattern. but it seems You plug the same gradient in all coordinates wired but working but what about reflections is it possible thanks Martin If you render with PBR, that anisotropic specular should reflect your scene correctly without changes. For anistropic reflections in Raytace/MP mode, I don't believe there is a node or VEX command to do that for you. You'd have to roll your own... we had to. Quote Link to comment Share on other sites More sharing options...
sanostol Posted July 14, 2009 Author Share Posted July 14, 2009 ui, that's quite challenging calculon is thinking .... If you render with PBR, that anisotropic specular should reflect your scene correctly without changes. For anistropic reflections in Raytace/MP mode, I don't believe there is a node or VEX command to do that for you. You'd have to roll your own... we had to. Quote Link to comment Share on other sites More sharing options...
calix Posted July 14, 2009 Share Posted July 14, 2009 Hey Martin! Maybe this links are useful... http://www.sidefx.com/index.php?option=com...cf7a5a422ca74a4 http://www.sidefx.com/docs/houdini9.5/nodes/shop/v_aluminum http://www.alan-warren.com/shaders/vex-uber-shader/ (check the source) cheers Quote Link to comment Share on other sites More sharing options...
sanostol Posted July 19, 2009 Author Share Posted July 19, 2009 how can i get a vector that is aligned to a textured gradient. for example I don't want to know the actual value of red at the shadingpoint , but the direction of the vector. I read in the help about the dv/du functions, but help assumes that You know it allready good enough. Can someone explain it a tiny little bit deeper? Martin Quote Link to comment Share on other sites More sharing options...
Dennis Posted May 26, 2010 Share Posted May 26, 2010 Hey there, I didn't want to create a new topic for that, so I thought this might be the perfect place for the problems I am experiencing with controlling the anisotropic direction with a texture. As you can see I'm getting a dark or white (depending on the u and v roughness) halo effect around my anisotropic pattern. I tried everything that came to my mind to get rid of this and played with all kinds of filtering options but without any success. I hope someone has an idea how to solve this issue. I totally trust in the knowledge thats present on this forum Cheers, Dennis anisotropy.zip Quote Link to comment Share on other sites More sharing options...
LEO-oo- Posted May 26, 2010 Share Posted May 26, 2010 Nice job! Thanks for sharing! Quote Link to comment Share on other sites More sharing options...
DaJuice Posted May 27, 2010 Share Posted May 27, 2010 Yes, I'm not sure what the root cause of those artifacts is. I haven't found a really practical solution but there's a couple of things you can do to alleviate the problem. One is to start off with a higher-res texture. I've edited the copnet in your example and the actual tiling is done in the shader now. You have to go to the copnet and render out the texture first. The other thing is to make mantra do higher-quality dicing. Under PBR, cranking up the Ray-Shading Quality improves things quite a bit but it's very very memory hungry. It seems for the setting to have any effect, there either needs to be displacement going on, or the surface being shaded needs to be parametric (ie. NURBS or SubDs) and have the Re-Dice Displacement parameter enabled (it's hidden away by default). If you look at the file you'll notice a couple of added parameters on the objects for that, and they're also being rendered as subdivision surfaces now. The sucky thing is that memory consumption and render times go way up, so I can't say really "problem solved". There must be a better solution, but I'm not exactly sure what's causing this to being with... anisotropy_edit.zip Quote Link to comment Share on other sites More sharing options...
Dennis Posted May 28, 2010 Share Posted May 28, 2010 Thank you DaJuice. As you say, it's not really a "production ready" solution, but at least it works. For a small scene I might afford this workaround. As you might have noticed I rendered my texture with no antialiasing as I was thinking that might be causing the interpolation between the uv values. Just like an antialiased depth map is producing wrong depths around antialiased geometry edges. I also tested the scene with a non rat texture and "vm_image_rat_makemips" switched off to get rid of unwanted antialiasing that might happen due to mipmapping (that however might be total bullcrap and if so, please correct me). But it has to be something that's happening inside the renderer. Maybe someone who has more insight of the inner workings of rendering has an idea? Quote Link to comment Share on other sites More sharing options...
Serg Posted May 28, 2010 Share Posted May 28, 2010 Try using the colormap node instead of texture because "This VOP uses point sampling and does not perform filtering of the texture", iirc it helps prevent the interpolation that is occurring at the edge between one disc and the next, also, rendering in Raytrace mode should help. I made a anisotropic shader for the MP/RT renderer's and came across the same problem (was using same style of defining direction). S Quote Link to comment Share on other sites More sharing options...
Dennis Posted May 28, 2010 Share Posted May 28, 2010 Hi Serg, unfortunately your suggestion with using the colormap VOP didn't work. I'm using PBR Raytracing already and also tried to change the filtering in the texture VOP to "Point", but that didn't help either. Have you managed to get rid of this error using the colormap VOP in conjunction with mantra RT? Maybe I also have to create my own anisotropic shader for MP/RT. I would really like to be able to use PBR though. cheers, Dennis Quote Link to comment Share on other sites More sharing options...
Serg Posted May 28, 2010 Share Posted May 28, 2010 Hi Serg, unfortunately your suggestion with using the colormap VOP didn't work. I'm using PBR Raytracing already and also tried to change the filtering in the texture VOP to "Point", but that didn't help either. Have you managed to get rid of this error using the colormap VOP in conjunction with mantra RT? Maybe I also have to create my own anisotropic shader for MP/RT. I would really like to be able to use PBR though. cheers, Dennis Looking at the last render (thought it was quoted from the first) I dont think I ever got it to look better than that. But I did not need to render with higher dicing quality though, I dont see why the raytracing engines would need it. Perhaps it's because the discs have anti-aliased edges baked into the texture? S 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.