Jump to content

Nicolas90

Members
  • Content count

    5
  • Donations

    0.00 CAD 
  • Joined

  • Last visited

Community Reputation

0 Neutral

About Nicolas90

  • Rank
    Peon

Personal Information

  • Name
    Nicolas
  1. Hello dear community, I am having trouble scripting a second button on my hda. Both functions for the two buttons have been defined in the OnCreate callback in the scripts tab. While the first one is working fine, clicking the second one throws an error, saying the function or attribute defined in the parameter settings is not available. The callback-parameter for the first button has the value: kwargs["node"].hdaModule().OnCreateCurveButtonPressed() The second one has the parameter: kwargs["node"].hdaModule().OnCreateSectorsButtonPressed() And this is the error message that the console throws: Traceback (most recent call last): File "<stdin>", line 1, in <module> File "C:/PROGRA~1/SIDEEF~1/HOUDIN~1.607/houdini/python2.7libs\hou.py", line 23413, in __getattr__ def _SIDEEF_getattr__(*args): return _hou.HDAModule___getattr__(*args) AttributeError: 'module' object has no attribute 'OnCreateSectorsButtonPressed' Does anybody know whats causing this?
  2. Hello dear community, I'd like to build a simple HDA that lets me build a street from a curve. I'd like to have it configured in a way, that I get the same controls as we get for the Curve-Shelftool. I already found a handle called "curvepointoptions" which only lets me modify existing points. However, what I am trying to do, is to start from a blank state with all the options. Can anybody tell me how to properly setup such a tool? I already dug into the documentation, but I still can't make any sense of it. All the best, Nicolas
  3. Getting point neighbor in Python

    Hello dear community, I am currently trying to setup a city generator as part of my bachelors thesis. For a basic street layout, I am using a voronoi sop on a plane and fuse these points. It would be a big ease to be able to find the neighbors of a point (not vertices) and get their position. I did some workaround by creating a dictionary with position vectors and counting the positions that match, so I can at least count the neighbors. Does anybody know a trick or a function to do this in pythin? I know there is a VEX function that does that, however I don't know VEX pretty much and I am having trouble understanding their usage, although I read the docs. Any kind of help would be much appreciated. Best regards, Nicolas
  4. Question regarding UV attribute of vertecies in Python

    Hello Edward, thank you very much for your reply. I already tried the following: # This code is called when instances of this SOP cook. node = hou.pwd() geo = node.geometry() # Add code to modify the contents of geo. for vert in geo.prims()[0].vertices(): vert.setAttribValue("uv",(0,0,0)) However, the node fails and states that the attribute doesnt exist Is there any way to read and print out all properties in the console? EDIT: I found out how to query the verts Attribs, but the tuple that gets returned is empty
  5. Hello dear community, I am just writing a little Python sop that can Unwrap a polycurve like a uvtexture node does on a nurbs curve with [Arc Length Spline] setup. My question is, what is the attribute name of the uv coordinate? I tried uv and uv[1] as its shown on the spreadsheet. Does anybody know the answer? Best wishes, Nicolas
×