Jump to content

danielsweeney

Members
  • Content count

    26
  • Donations

    0.00 CAD 
  • Joined

  • Last visited

Everything posted by danielsweeney

  1. Hi Everyone, Just wondering if someone could shed some light on this. I'm copying values from one node to another for every Parm. but when using setFromParm(src) on a parm that has keyframes. it seems to copy the values across. but I cant see the keyframes in the timeline or any of the editors? whats gives? is this the proper way to do this or is there an extra step or another method? Any tips would be great thanks so much for your help. Daniel
  2. Hi everyone, Just wanted to ask a question. We run in to this problem a few times a year where a client asks us to visit an old scene. When we have updated redshift. I try to not usually update redshift to something in a point release that will break backward compatibility. usually change on a big release. but unfortunately, I have done this time around. Does anyone know of any scripts that someone might have released that would go through the scene a rebuild - lights materials and cameras, keep all keyframes, expressions, parents etc so its the same scene just built with updated nodes for redshift? if not il just have to look into writing something myself, but just wondered if anyone had come across a script that might work for us. cheers
  3. set absolute reference? python

    Hi Everyone, can anyone give me a heads up on how to do this? if I want to set a relative reference I usually do something like this. node = hou.node('/obj/geo1/') p1 = node.parm('sphere1/scale') p2 = node.parm('sphere2/scale') p2.set(p1) but what if I want the path to be an absolute reference? cheers for your help. D
  4. Houdini 19 Wishlist

    I would defo be up for seeing the code. and I am sure some other people would be too. Scene Callbacks - what do you mean by this? can you elaborate? didn't know you could check if things have been pressed or are active in the interface? cheers for the reply
  5. Houdini 19 Wishlist

    This is cool. any pointer on reading for resources on how to manipulate houdini's interface like this? also did this bit of code ever get released anywhere? cheers Daniel
  6. set absolute reference? python

    ah ok. so just do it manually. just didn't know if there was a more elegant solution. and you can set absolute reference with right-click. thought there might be a function for it. cheers for the help. D
  7. externaldragdrop.py - only works on some machines? not all

    Hi Alex, I did report a bug in the end, but got the bottom of this in with some googling, as support could not solve this. it is unfortunately a Windows problem if you are running the program in administration mode. Drag and drop does not work. cheers
  8. Hi everyone, has anyone come across this problem before? been setting up a custom script for drag and drop via the externaldragdrop.py file. Now the weird thing is. it works on some machines and not others. works on my home machine, a colleagues home machine. one of the machines at work and two other and work is does do anything. Whats seems to be happening is houdini, is not even registering that a file is being attempted to be dropped form an external window. So the .py file cant be called? I can't seem to find any documentation on this either which does not help. all machines at work are running the same environment setup. any ideas?? cheers Daniel Happy new year to all
  9. HDA > obj level > output transforms

    Just wondering how you set the output transform of an HDA at OBJ level from a node inside the HDA. Iv done it before but i can not remember for the life of me? can someone shed some light on this? pulling my hair out here and cant seem to find any info on this at all? cheers daniel
  10. houdini python and mply

    thanks for the heads up malexander. after a bit of tinkering, I did finally get it to work.... few things to look out for. in your list of file paths firstly you have to make sure each string for the file path has a space before. then I ran into the problem where it would not open file paths that had a white space in the whole path. so after a bit of reading, I think because it's a shell operation? I have to have the string encapsulated in " " . (please correct me if I am wrong on this) so a simplified version below import subprocess fileSequenceList = [' "tmp/tmp/box.001.bgeo"', ' "tmp/tmp/box.002.bgeo"', ' "tmp/tmp/box.003.bgeo"'] subprocess.Popen(['gplay', fileSequenceList]) if I run into any other hurdles. il post them up. cheers Daniel
  11. houdini python and mply

    Hi Again Bunker, thanks so much for your help. im still clutching at straws here. the function I'm building is basically being run off a right-click menu in a QT widget window. Don't know if that makes a difference. this is the last part of my function for testing purposes. filePath = filePath.replace("$F4", "*") command = 'gplay ' + filePath subprocess.Popen(command,shell=True) this is the whats my command variable prints like gplay C:\Users\Daniel\Documents\NodeShare\Geometry\moreframes\box.*.bgeo and it's still throwing an error. and yeah I am importing subprocess its at the top of my function. just get this error. hou 18 - python 2.7 cheers Daniel
  12. houdini python and mply

    Hi Bunker, thanks for the help. Nope, I am afraid that didn't seem to work. my evaluated end of the string looked like this when I replace $F4. /geometry/moreframes/box.*.bgeo Googling this I can't seem to find any info on this problem. when picking files manually I noticed it had the frame range in () at the end of the string. like (1-240) but i tried this also adding to the end of the string. but it didnt work. unless it needs to be in a tuple or something. cheers Daniel
  13. return modifier keystroke (ctrl, shift etc) with externaldragdrop.py

    this may make me sound stupid. but I don't know how to print the Kwargs? can you give me an example of how to do this. sounds super useful. cheers
  14. Hi Everyone. Has Anyone got any ideas on how to do this? or point me in the right direction of any further reading. Google searching is not coming up with anything. how can I return if a ctrl or shift keystroke is pressed when dropping files in my externaldragdrop.py so i can define different functions depending on modifier key pressed. I'm using the def dropAccept() does anyone know if this returns any other information other than files. I also cant find any information in the docs on this function. cheers for the help. Daniel
  15. houdini python and mply

    hi guys, is there any reason why this would not be working. i could have scripted it wrong. I'm in hou 18. I cant seem to get it to work with $F4 in the file path. throws an error. can get it to work with single files. anyone got any ideas?
  16. return modifier keystroke (ctrl, shift etc) with externaldragdrop.py

    just so people know. I could not find a way to do this with the build-in functions in python 2.7. I had to download a library to do this. the Keyboard python Library to be exact. cheers
  17. Hi everyone, I am just wondering if Anyone can point me in the right direction for this. (or tell me if it is even possible) currently have a QtreeWidget in a python panel and I want to be able to drag one of the items in the list from the panel into the network view anf drop the file(execute the function needed). main trouble I am having is trying to logic working for the drag and drop events - what functions should I be looking for. - do i need to use Pyside2 events (can manage to get feedback from dragEnterEvent() and dropEvent(), but these only work in the panel it self) - or would it be built in events from houdini that need to be call? im no expert on this. any gurus out there that can throw me a bone? currently on hou18. cheers Daniel
  18. OnInputChanged - event not triggering when input nodes change name

    Hi, thanks for the responses Alex and Thomas. to be honest the opinput() would work for my solution. but only if I could get all inputs going into a multi-connector? and it then Registered it on the Parm so i could run a call back script. But from what I have tested. the callback script does not run when its has an expression in the parm and the output changes when it pulls the new name? I will have to have a proper think about doing it with node event types as I have no experience of this and I am very much on a learning path with python....:S the joys of coding when you dont have a coding brain. ha Daniel
  19. HI everyone. Hope everyone is ok in this current situation. Hope no one is Ill from the virus and not going crazy working from home. I am wondering if someone can point me in the right direction on this. I have a Multi-input HDA - I assumed that the OnInputChange HDA event would trigger when a name change of node that is connected. But for some reason, it does not. What would be the best way to listen for this event happening. The event triggers fine the first time the node in plugged in, but not when the node changes name. Any help would be appreciated. Cheers Daniel
  20. onCopy event in hda

    Thank you so much for this Alex. been banging my head against the wall in a code hole. does not help when I am no Python wizard. Cheers again Daniel
  21. onCopy event in hda

    HI, I know this is an old thread, could anyone shed some light on this? I need to have my custom function track if the HDA has been duplicated? What is the best practice. Cheers Daniel
  22. $JOB dependent hdas and python modules

    It would be cool if this just worked out the box. So we could tick if we wanted houdini to find Job specific HDa/OTLs I am still quite confused how to get this to work. I assume there are multiple way. All of which seem a little complicated. I made a quick test with a small python script thats on a null and when I run the code. it appends to the OTL scan path. But as I am no pro at houdini and I am trying to set this up for a Company enviroment I am still moving slightly blind. Is there a new way to do it with Packages? Dynamically? as when we upgrade to hou 18 (when deadline starts to support it) I would like to step away from the enviroment variable way of doing things and move all to packages. Also, I understand I could write this in a 456.py script. But I have had multiple errors with deadline and both the 123.py and 456.py scripts where it throws errors and I cannot seem to pinpoint the problem and solve it. many errors about its not finding hou. whatever. cheers I might have to contact support to see if i can get a straight answer. Daniel
  23. Hi people. Just wondering if anyone is having this same problem. I am fairly new to python and I am following along with Mix training video on youtube about python panels. https://www.youtube.com/watch?v=jL7jM1bJhxE&list=PLAnSvhIvNZCs4_D1JYZitBEBmf31_2ylL&index=1 and for some reason, I am stumbling at the first hurdle. When trying to import the OS module for python in the python panel window. its does not seem to work. Now if I go in and 'import os' via the python shell it works. Can anyone shed some light on this? or has anyone had this issue before? on 17.5 cheers Daniel
  24. hou.hipFile.save problems - need help

    Hi Everyone, Hope you are all well. We have not been using houdini long. We are long time soft users and we are testing out software to move too and see the strengths of them. Houdini is our first choice for the sheer scope of it, so we have started looking at this first. Anyways, explaination of the problem below. I am trying to script a "simple" saving function through a HDA via Python (I dont know if this is a correct way of doing it, so please If I am going in the wrong direction, shout) it will create a few folders based on some parameters in the HDA interface and save the file with the name specified. I am setting environment variables through this and using that to generate the path for the file save and also will hopefully re-use the Environment variables later for ROP output ETC for the scene. I am running into an error with what I believe is to do with the hou.hipFile.save function. I have not been coding for very long either so please bare with me if my Termanology is off also. I have attached some code snippets. I am basically trying to save the files to a structured job folder system. something like below. $JOB/scene/[WORKCATAGORY]/[SHOTFOLDER]/SHOTNAME.hipnc I have defined some functions in the Python Module in the HDA, and these are being called by the callback script on each parameter. It is really weird, It has worked once or twice. But then I try to save again and it does not work again. I did some debugging and the Error that houdini generates, it definately works when I take out the SHOTFOLDER in the string for the path to save to. If my file path is just saved in the WORKCATAGORY section it saves. My defined functions (sorry code is messy) def shotName(parm): hou.putenv("SHOTNAME", parm) test = parm print test def folderName(parm): fname = "NN_" + parm hou.putenv("FOLDERNAME", fname) test = fname print test def workCatagory(node, parm): a = hou.parm(parm.path()).eval() labelName = hou.parm(parm.path()).menuLabels()[a] testA = parm hou.putenv("WORKCATAGORY", labelName) print labelName def customSave(): #Pull in Enviroment Variables work = hou.getenv("WORKCATAGORY") shot = hou.getenv("SHOTNAME") folder = hou.getenv("FOLDERNAME") # Houdini save path FULL savePath = "$JOB/scene/" + work + "/" + folder + "/" + shot + ".hipnc" # Houdini save path with a job catagory but not job name folder #savePath = "$JOB/scene/" + work + "/" + shot + ".hipnc" exSavePath = hou.expandString(savePath) exSavePath = exSavePath.replace('//', '/') #hou.putenv("SAVEPATH", exSavePath ) hou.hipFile.save(exSavePath, False) print exSavePath the error it generates is Traceback (most recent call last): File "<stdin>", line 1, in <module> File "opdef:/Object/Northforge3_testa?PythonModule", line 40, in customSave File "C:/PROGRA~1/SIDEEF~1/HOUDIN~1.600/houdini/python2.7libs\houpythonportion.py", line 1287, in decorator return func(*args, **kwargs) File "C:/PROGRA~1/SIDEEF~1/HOUDIN~1.600/houdini/python2.7libs\hou.py", line 28330, in save return _hou.hipFile_save(*args, **kwargs) OperationFailed: The attempted operation failed. Error creating file: W:/Work/Development/D00026_Houdini_test/3.3d/D00026_Houdini_test_HOUDINI/scene/rend/NN_test/test.hipnc working enviroment is. Windows 10 Houdini Apprentice 16.0 saving to a NAS drive I hope some of that makes sense. Cheers
  25. hou.hipFile.save problems - need help

    I am only asking as when reloading the scene. Either the variable is not there anymore or it does not reflect the information that is sitting in the HDA. So I need a way for that Data to stay within the HIP file so when it is re opened the Global data for that file in still available. Any ideas?
×