Jump to content


  • Content count

  • Donations

    0.00 CAD 
  • Joined

  • Last visited

  • Days Won


Stalkerx777 last won the day on October 23 2019

Stalkerx777 had the most liked content!

Community Reputation

139 Excellent

About Stalkerx777

  • Rank
  • Birthday 03/02/1984

Contact Methods

  • Skype

Personal Information

  • Name
    Alex Rusev
  • Location
    Vancouver, Canada

Recent Profile Visitors

9,634 profile views
  1. Instead of having a checkbox for each filter, you could have a menu like parameter, with a script that lists your multiparm value, thus you will avoid messing around with checkboxes and which of them wins. As to the rest of your question, there are 2 common models of scripting in Houdini. I call them pull and push models. In a push model, you hook a callback on a parameter and that callback is pushing values to other Houdini nodes. The main shortcoming of this model is not being able to set parameter values in locked assets. It also makes it hard to debug complex setups(especially not yours) when you have no idea where a parameter value came from. In the pull model, you hook an expression on the parameter and it does the job. No problems in locked assets and no need to guess the origin of the value in it. The downside is that users won't be able to edit these parameters obviously. In your case, if the relationship between your CONTROLS and ris1 nodes is deterministic(e.g they know about each other) choose either to push to ris1 from a callback on a menu parameter on the CONTROLS or pull the value from an expression on ris1. Whatever fits better. Good luck.
  2. Right, as Tomas said a parameter expression might work for you, if not, then what you can do is in your onInputChanged handler of your hda, you would register a callback on the node's inputs. (Simplified, untested) def _callback(): pass for inp in hda_node.inputs(): inp.addEventCallback([hou.nodeEventType.NameChanged], _callback) You will need to take care of removing the callback if it's there already before adding a new one.
  3. To be honest, you've chosen the wrong place to ask basic C++ questions. 1. Look closer and you'll find the definition in the C file. 2. What do you expect it to return and why? This is your plugin entry point, Houdini calls it to register your new operator. P.S. Learning C++ via HDK is a very wrong strategy imo.
  4. map uniform pattern on a geometry

    https://www.sidefx.com/tutorials/making-procedural-patterns-tutorial-houdini-cinema4d/ https://github.com/alexxbb/gpattern
  5. Executing hda python script every frame

    Rather than pushing the values to a parameter on a camera from your HDA, consider setting a Python expression on vcomment something like: hou.nodeType('your_hda_type').hdaModule().get_comment() It's not always possible to set it up this way, depending on your requirements, but it's for sure always better to pull values rather than push to parameters. At least you won't have problems with locked nodes and it doesn't change the scene state.
  6. onCopy event in hda

    def is_copy_paste_event(kwargs): if not kwargs['node'].name().startswith('original') and not kwargs['old_name'].startswith('original'): original_node = kwargs['node'].parent().node('original0_of_%s' % kwargs['old_name']) return True if original_node else False Use this in an OnNameChanged event handler
  7. Drag and drop QtWidget data to a parameter

    The docs in that example say: This example demonstrates specifically how to enable dragging items from other parts in Houdini and dropping them into the Python Panel interface. So dragging anything to your custom widget makes sense, because you can handle different cases in your code, but dropping an arbitrary data from Qt into a Houdini's node parameter is undefined, to my knowledge. Native Houdini UI doesn't know how to handle this interaction. Interestingly that you're getting "something" working, I guess Houdini tries its best to read the mime data as text, but it's limited to what it can do.
  8. Drag and drop QtWidget data to a parameter

    Need more information, What kind of "parameter" are you talking about? A Houdini parameter, a QWidget? What is so "weird" in that text? What and whereto are you dragging exactly?
  9. Async Python message listening

    I assume you're using Python 3 build of Houdini-18? Not only it's not official yet but it's far from stable first of all. Second, if you look at the Discord API docs, it says that client.run() is blocking, meaning it's spawning an event loop that blocks the interpreter which runs on the main thread where the Houdini UI runs too. You need to run your Discord client code on a separate thread. It's a big topic and far beyond the scope of Houdini. From a random google page: from threading import Thread import asyncio def start_loop(loop): asyncio.set_event_loop(loop) loop.run_forever() new_loop = asyncio.new_event_loop() t = Thread(target=start_loop, args=(new_loop,)) t.start()
  10. Import Automate with String replace

    For the frame number use $F3, where 3 is padding
  11. switch takes and render

    Usually, ROPs in Houdini have a take parameter, see if Redshift ROP has one and set your take on the ROP in your for loop rather then setting it globally in the scene. Cheers.
  12. Updating the viewport with python to see change in parameters

    As Mark said above, the GeometryViewport.draw() won't update the viewport because your script is running in the main thread and therefore is blocking any updates. What you need to do is to run your script in a separate thread and communicate with Houdini via hdefereval.execute_in_main_thread_with_result(callback) See $HH/python2.7libs/hdefereval.py for more info.
  13. Possible to interact with main menu via script?

    If all you need is just the menu items name, simple read the $HFS/houdini/MainMenuCommon.xml file with Python and you're good to go.
  14. Possible to interact with main menu via script?

    I don't think there's an API to read or trigger default menu items but for some of the menus a Python API exists. (for example - opening the Type Property dialog and others). Last time I needed something like this, there was even no HDK access to the menus.
  15. It seems to me you have a very poor understanding of Houdini/Python basics which is Ok for a beginner. Houdini Docs are pretty good these days, go ahead read it and create a few tools for practice. Then read this on how to tell Houdini where to find your scripts.