EH_Studio Posted 13 hours ago Share Posted 13 hours ago (edited) I really like the cellular noise node that can be used inside a point VOP, as it yields good borders compared to trying to remap worley/voronoi patterns. The downside is that it can only be used on a 2D uv map. How would one go about getting the same results with a vector 3/3D input? Similar to the 3D outputs of Unified Static, Turbulent, AA noise, etc. I've tried searching, but haven't really found anything directly addressing the issue. Thanks! Edited 11 hours ago by EH_Studio Needed clarification. Quote Link to comment Share on other sites More sharing options...
Librarian Posted 9 hours ago Share Posted 9 hours ago vector p = @P; // Center control, optional p -= chv("pivot"); // Scale the cellular pattern p *= chf("scale"); // Rotation controls in degrees float rx = radians(chf("rotate_x")); float ry = radians(chf("rotate_y")); float rz = radians(chf("rotate_z")); matrix3 m = ident(); rotate(m, rx, {1, 0, 0}); rotate(m, ry, {0, 1, 0}); rotate(m, rz, {0, 0, 1}); // Rotate the cellular noise space p *= m; // Directional stretch makes the rotation visible p.x *= chf("stretch_x"); p.y *= chf("stretch_y"); p.z *= chf("stretch_z"); float f1, f2; vector pos1, pos2; vnoise( p, chf("jitter"), chi("seed"), f1, f2, pos1, pos2 ); // Border calculation float edge = f2 - f1; float border = 1.0 - smooth( chf("border_width"), chf("border_width") + chf("softness"), edge ); // Cell color value float cell = rand(pos1 + chi("seed")); // Final result float result = lerp(cell * chf("cell_brightness"), 1.0, border); @Cd = set(result, result, result); f@cell_border = border; f@cell_value = cell; f@cell_result = result; 1 Quote Link to comment Share on other sites More sharing options...
EH_Studio Posted 8 hours ago Author Share Posted 8 hours ago Awesome, thanks so much for your help! 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.