anxcon opened this issue on Jan 14, 2006 ยท 8 posts
anxcon posted Sat, 14 January 2006 at 3:55 PM
making a patio for my latest 3d house, but need a texture thinking to make it brick, or cement, or have both options :P cement was easy and is finished, but trying to work on brick now but problem i have is 1) making rings instead of lines, that walls have and 2) keeping bricks with square corners, sides keep getting tapered 2nd isnt a huge problem, more of a personal want trying to stick with poser nodes only, no textures due to i have a habbit of resizing everything as i model :P and the end patio will have morphs for size anyways so dont want bricks to be growing big cuz of the texture :)and editting mat room nodes would be easy :)
danamongden posted Sat, 14 January 2006 at 5:26 PM
You should be able to use the U_offset and V_offset inputs on the brick node to essentially take samples using a different coordinate system. Set up the trigonometry to convert the normal U/V coords into a polar coordinate system, i.e. angle and radius from your center point, i.e. 0.5,0.5. Then use those polar coordinates to drive the u/v offsets into the brick node. That should get you something to start with, but you'll probably have the immediate artifact that the bricks near th edge will be wider than the bricks near the center. You could probably adjust that by using your calculated radius coord to drive the Brick_Width input so that the farther out you went (higher brick-V) the narrower the bricks (in polar coords). When projected onto the plane, it should even out. It's an interesting problem, and I'm tempted to fiddle with it myself, but I'm on another deadline right now. Maybe later.
AntoniaTiger posted Sat, 14 January 2006 at 5:28 PM
One sneaky thought: is there a way of doing the UV map so that the rings are mapped in UV space as straight rows? You'd need a disc in the mesh... No, you could manage with an arc of bricks, but it couldn't include the centre of a circle, and distortion would be a problem. The Mesh would need enought points to make each row of bricks independent. To be honest, you might as well draw a bitmap whioh can control a blender node. That lets you combine a brick texture with a mortar texture, doing much the same job as a Brick node. You can get decent textures with fairly simple node combinations. The trouble is that moving mesh points with a morph will distort the texturemap, and shader nodes depend on the UV coordinates, usually. So simple x/y scale changes might be managable, but otherwise?
anxcon posted Sat, 14 January 2006 at 6:37 PM
ya the center problem came to mind already decided on using a marble or something texture for middle about 2-3 foot diameter in the center, fixing the problem just need to figure out the math for the brick node
DRACONIAN posted Sun, 15 January 2006 at 5:22 PM
danamongden posted Sun, 15 January 2006 at 5:40 PM
I tried to work up the nodes for this, but the problem is getting into polar coords. To do get the angle, I'd need an inverse sin, cos, or tan, but only the normal methods are available, not the inverse. Anyone know how to do an inverse tangent in a shader node?
nruddock posted Sun, 15 January 2006 at 6:04 PM
Attached Link: http://www.runtimedna.com/mod/forum/messages.php?forum_id=43&ShowMessage=186659#7
"*Anyone know how to do an inverse tangent in a shader node?*" Funny you should ask ;)I can do arcsin and arccos, but not arctan as the approximation functions only have a valid input range of -1 to 1.
Note that it isn't perfect yet, as it doesn't have any quadrant processing.
danamongden posted Sun, 15 January 2006 at 11:18 PM
Well, you end up with all three sides of the triangle (u-.5, v-.5, and the hypotenuse), so arcsin or arccos are equally useful. Alas, I don't have the time to spend on this right now.