PengZhang Posted June 19, 2013 Share Posted June 19, 2013 Hi,guys, i have a shader question here. i want to do some displacement on my rigidbody chunk to add detail. let's say we have a cube,in the attatchment jpg ,it is a.(you can imagine it is a rigid chunk), if i add noise displacement on it,i got b. but,i do not want the top face get the displacement,because i hope the top face looks like a flat ground. so i set the noise vector y to 0,and i got c. the problem is the top face looks strange,the reason i think is the x z position of the top face changed, the normal should changed too. so,i set the normal vector y 0,then i got d,you can see,there is some change,but it did not solve the problem. what can i do to get what i want? i need your help. thank you. Peng Zhang. shader_displacement6.hip Quote Link to comment Share on other sites More sharing options...
gui Posted June 19, 2013 Share Posted June 19, 2013 I think the way to go is not messing up with normals and positions. If u are using the "displace along normal" node, just add an attribute in shops, that has a value of 0 where u don´t want displacement and 1 where u want. Read that in shops using a parameter node with the attribute name in it, and multiply the displacement amout by this number. 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.