danylyon Posted January 2, 2013 Share Posted January 2, 2013 Hi I have a POP network with a collision. Now I would like to trigger a Python script (Function) whenever a Particle collides. Ideally with the informations of the Particle. How can I do that? If it's Possible? Oddly there's no Python Operator Type for POP, or am I missing something. Still quite new to Houdini. Quote Link to comment Share on other sites More sharing options...
anim Posted January 2, 2013 Share Posted January 2, 2013 dopends on what are you trying to do with that script you can use python script on any POP node any parameter, for your case some node which evaluates per particle for example attribute POP, and when you limit that node just for just collided particles, it will run that script just on them, but it's always safer to check inside of that script if that particle has collided and then run main body of the script or if you don't need this data for next frame evaluation, you can just make python SOP and process your cached particles, they will have all information about collisions baked in or you can run your particle sim in dops using popsolver for popsim and sopsolver for python geo processing Quote Link to comment Share on other sites More sharing options...
Netvudu Posted January 2, 2013 Share Posted January 2, 2013 It certainly sounds like you are trying to use Python for something you wouldn´t need in Houdini. If you are coming from some other package there´s a tendency to try to use script for something like this while it is perfectly doable with the regular tools. Quote Link to comment Share on other sites More sharing options...
danylyon Posted January 2, 2013 Author Share Posted January 2, 2013 Thanks for quick answers. Tomas, yes that clicked, but I was'nt able to get the point data into a python script. So I tried it differently. Javiar.. hehe, yes I guess you're right. If you have a hammer, everything looks like a nail ;-) I'm triing to build it in a SOP Solver context now. What I want to do is: On collision, I want the particles to deform a geometry. Basically taking their velocity and add it to the geometrys points. My problem now is. How do I get the POP network into the SOP Solver Context? Or into a VOP SOP? Quote Link to comment Share on other sites More sharing options...
mawi Posted January 2, 2013 Share Posted January 2, 2013 Thanks for quick answers. Tomas, yes that clicked, but I was'nt able to get the point data into a python script. So I tried it differently. Javiar.. hehe, yes I guess you're right. If you have a hammer, everything looks like a nail ;-) I'm triing to build it in a SOP Solver context now. What I want to do is: On collision, I want the particles to deform a geometry. Basically taking their velocity and add it to the geometrys points. My problem now is. How do I get the POP network into the SOP Solver Context? Or into a VOP SOP? There is a example file for this using the popsolver in DOPS called dentingWithPops. Maybe you can get a idea there. Quote Link to comment Share on other sites More sharing options...
anim Posted January 2, 2013 Share Posted January 2, 2013 (edited) have a look at example for from help called DentingWithPops (it's for SOP Solver) EDIT: too late Edited January 2, 2013 by anim Quote Link to comment Share on other sites More sharing options...
danylyon Posted January 3, 2013 Author Share Posted January 3, 2013 Ah perfect. Thanks alot! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.