Jump to content

konstantin magnus

Members
  • Content count

    603
  • Donations

    0.00 CAD 
  • Joined

  • Last visited

  • Days Won

    35

konstantin magnus last won the day on September 5

konstantin magnus had the most liked content!

Community Reputation

356 Excellent

About konstantin magnus

  • Rank
    Houdini Master

Contact Methods

  • Website URL
    http://www.konstantinmagnus.de

Personal Information

  • Name
    Konstantin
  • Location
    Stuttgart, Germany

Recent Profile Visitors

6,281 profile views
  1. Ok, here comes the nice and simple SOP solution: Segment the input line with a polycut node. Align the segments with a primitive node. Assign letters with another primitive node. paragraph.hipnc
  2. Evenly Distributed Hexagons On A Object

    Hi Melis, how about combining these two methods: Hexagon patterns: https://www.sidefx.com/forum/topic/49509/?page=1#post-276316 Pattern projection: https://www.sidefx.com/forum/topic/60740/?page=1#post-272057
  3. Specular Reflection

    Try PBRrefract instead of PBRreflect.
  4. Baking grass to plane

    Hi Marco, you can build your own planar baking tool inside SOPs and COPs: Scale object to unit size with 1 / max(max($SIZEX, $SIZEY), $SIZEZ) in a transform node. Shoot rays at the mesh from COPs with the intersect() function. Grab the UV coordinates via primuv(). Transfer any kind of texture map values by using colormap(). This also works for geometry attributes such as normals, depth or bounding box info. Here is the minimalist code (to be used in a COP snippet inside a VOPCOP2GEN node): string geo = 'op:/obj/geo1/OUT'; string tex = '/Users/konstantin/maske_rot_Map_Albedo_4K.jpg'; vector pos_img = set(X, Y, 0.0); vector dir_ray = set(0, 0, 1); vector pos_world; vector uvw_prim; int prim_mesh = intersect(geo, pos_img, dir_ray, pos_world, uvw_prim); vector uvw_mesh = primuv(geo, 'uv', prim_mesh, uvw_prim); vector map = colormap(tex, uvw_mesh); vector color = map; R = color.r; G = color.g; B = color.b; A = prim_mesh != -1; baker.hipnc
  5. Random Sequence jpg to each grid

    It can be more efficient to apply various textures inside a shader:
  6. It's the most versatile 3D package I know and I don't even use it for effects. I guess it's just Houdini's entirely different philosophy and scope that can be overwhelming (and sometimes disappointing) in the beginning. I see Houdini rather as a system for building procedures. But some users don't embrace this and keep requesting to turn it into another Cinema 4D with better simulation abilities.
  7. I guess historically Houdini was not used much for assembling scenes. Also everyone is asking for different tools, so I am quite happy the developers are focusing on the big picture. Houdini is rather about building your own tools: Right click on the shelf bar, 'New Tool' and put something like this under the 'script' tab to get started: // aligns all selected geometry nodes to the bottom min_height = 100000.0 for node in hou.selectedNodes(): for child in node.children(): if(child.isDisplayFlagSet()): bb_min = child.geometry().boundingBox().minvec() if(bb_min[1] < min_height): min_height = bb_min[1] for node in hou.selectedNodes(): for child in node.children(): if(child.isDisplayFlagSet()): bb_min = child.geometry().boundingBox().minvec() offset = min_height - bb_min[1] node.parm('ty').set(offset) The first mayor loop is finding the lowest minimal height within all immediate child nodes and the second one is applying the offset on object level.
  8. Hi Masoud, you could build a custom shelf tool for aligning objects. Accessing the bounding box values for each selected geometry might be a good start: for node in hou.selectedNodes(): for child in node.children(): if(child.isDisplayFlagSet()): bbox = child.geometry().boundingBox()
  9. Assign texture around a point

    Hi Antoine, this shader maps a transparent PNG on a background texture right were a point is located. decal_shader.hipnc
  10. Procedurally reverse objects

    Shoot rays along the normals. If they all end up on the piece they are coming from you know it's inverted. inside_out.hipnc
  11. gradient r&d

    When decorating three-dimensional meshes I usually rotate() the directions from N to up so they are horizontal for atan() to work properly. float radius = chf('radius'); float tol = chf('tolerance'); int pt_near = nearpoint(1, v@P); vector pos_near = point(1, 'P', pt_near); vector nml_near = point(1, 'N', pt_near); float dist_near = distance(v@P, pos_near); vector dir = normalize(v@P - pos_near); vector up = set(0,1,0); matrix3 m = dihedral(nml_near, up); dir *= m; float angle = fit( atan(dir.z, dir.x), -M_PI, M_PI, 0.0, 1.0); vector color = hsvtorgb(set(angle, 1.0, 1.0)); float width = abs(dist_near - radius) < tol; v@Cd = color * width; color_wheels_3D.hipnc
  12. gradient r&d

    You can create lots of color wheels around points on a grid: float radius = chf('radius'); float tol = chf('tolerance'); int pt_near = nearpoint(1, v@P); vector pos_near = point(1, 'P', pt_near); float dist_near = distance(v@P, pos_near); vector dir = normalize(v@P - pos_near); float angle = fit( atan(dir.z, dir.x), -M_PI, M_PI, 0.0, 1.0); vector color = hsvtorgb(set(angle, 1.0, 1.0)); float width = abs(dist_near - radius) < tol; v@Cd = color * width; color_wheels.hipnc
  13. For a cage model turn the mesh into a SDF volume, dilate it and convert it to a low poly representation. Optionally take volume samples to test whether the new mesh is fully outside. cage_model.hipnc
  14. gradient r&d

    The same workflow applies for meshes, too. colorcurve_meshes.hipnc
  15. gradient r&d

    1. Regarding the pinch: You can get rid of it by either setting the 'destination min' of fit2 to something greater than 0. Or by simply unplugging it from the next node called smooth2. 2. Regarding a more casual solution on arbitrary curves: There is no shame in using standard SOP nodes. The resample node can create a U attribute running along each curve from 0.0 to 1.0. The color node maps float attributes such as U. The attribute transfer node blends those colors to the grid by taking some nearby samples. .. which can then be smoothed even further by an attribute blur node. In a VOP measure the distance with xyzdist, tune the result with a curve ramp and mix your gradients against a solid background color. colorcurve.hipnc
×