Search - User list
Full Version: Houdini and PFTrack or MAX
Root » Houdini Indie and Apprentice » Houdini and PFTrack or MAX
joshgrocholski
I'm pretty new to Houdini, but seeing as how I want to get into the visual effects industry, I really want to learn Houdini like I've learned MAX at school. I was wondering if anyone could help me with one of two things:

1 I would like to know how to get PFTrack data to import into houdini

or

2. I would like to know how to properly export simulation data for use in a 3DS MAX scene I already have built based on PFTrack data.

I have already gotten the geometry itself from MAX to Houdini so those objects can affect the simulation. But if I do it that way then I need to know how to either get the PFTrack data into Houdini and render within Houdini, or I need to know how to get that simulation data back into MAX for texturing and rendering there with the PFTrack camera. Any and all information will be appreciated! Thanks in advance!
goldfarb
from what I can remember…
PFTrack supports FBX…so you could try exporting the camera data out that way then bring it into Houdini…
or the old way with CHOPs (.clip file?, chan? I can't remember)

getting geometry out of Houdini is easy…ROP SOP
joshgrocholski
I appreciate your help. Like I said, I am very new to actually working in Houdini (about 1 week now), and I don't quite understand the ROP SOP stuff. The exporting geometry sounds like the easier way to approach it, though. Would you be able to go into more detail about exporting my simulated fluid using an fbx file (I've never worked with those either)? Thank you very much either way for the reply and giving me some kind of direction!
JColdrick
1 I would like to know how to get PFTrack data to import into houdini

PFtrack comes with a houdini export module. You can dump it to a cmd file(which is a scripting language for houdini) and simply open an hscript textport and ‘source’ that file, it should setup the camera, etc for you.

Cheers,

J.C.
joshgrocholski
Is that a new node out in object space I create? I've tired both Houdini geo and cmd option out of pftrack. The geo option pretty much brings in nothing from what I can see. The cmd option you talked about said it couldn't open! Is there something else I have to do besides go up to import and find the file? Thanks again for all the help.
JColdrick
It likely couldn't open because it couldn't find it. Feed source the full path to the file…

J.C.
joshgrocholski
Okay. I know I'm kind of all over the place with this one, but I've finally decided to export everything from MAX as an FBX file and try to import all that into Houdini. Now I'm having a different problem. Does anyone know why when I try to import the FBX file Houdini just closes without a warning or anything? Is there some option I have to check for this to work? I'm making sure to only import the geometry, camera, and animation since the camera is animated. Thanks for all the help guys!
old_school
Post the FBX file.
If it is too large to post, let us know.
joshgrocholski
Alright. Here you go.
old_school
Yes I get a crash as well. Bug submitted.

thank-you
joshgrocholski
Alright, now that I have that cleared up, I would still like to try to get this to work. I there anyway you could walk me through the process of getting the camera from PFTrack into Houdini. There aren't really any tutorials online or anywhere that are helping me with any of this, so I am kind of forced to ask people like this. Thanks for all your help so far! I appreciate all of your time and effort.
JColdrick
It's been explained. Simply saying “it's not working” doesn't give any feedback so it's hard to determine exactly what's wrong. We're running the latest Pftrack here, you export a Camera Exports and use the Houdini exporter - it makes a cmd file. You need to know where it is on disk. Start Houdini, open a Windows/Hscript textport, and in there type:

source /the/path/to/my/camera_file.cmd

and it will generate what you need. If it says ‘not found’, that means you've made a typo!

Obviously the above is a Linux path, you'd need to use Windows if you're on that platform. Also, I would recommend walking before running - getting a track into Houdini is fine, but I'd aim for feeling reasonably comfortable in the package first. It's not what I would call a Houdini tutorial experience.

J.C.
oleg
joshgrocholski
Does anyone know why when I try to import the FBX file Houdini just closes without a warning or anything? Is there some option I have to check for this to work? I'm making sure to only import the geometry, camera, and animation since the camera is animated. Thanks for all the help guys!
Well, this is interesting. I've looked into it, and here's what I found:

1) The crash happens deep in the internal FBX SDK (provided to us by Autodesk), which we have no control over. This happens right in the function which loads the file initially, so there is no way to bypass it.

2) Maya also crashes when trying to import this file. In the light of this, could do an experiment, and try to import this file back into your copy of 3DS MAX to see if it crashes, too?

3) Since this is a crash in the FBX SDK itself, the best solution is probably to notify them of it. They've got a forum at the link below dedicated to these things. I can post it there myself, provided you give me permission to attach this file, or you could do it instead, if you wish. The forum's address is: http://area.autodesk.com/index.php/forums/viewforum/64/ [area.autodesk.com]

At this point it looks like it is a combination of an internal FBX SDK bug and a (possibly) corrupt/invalid FBX file. Did you export it with any special export options set? Could you export it in ASCII (Maya's exporter has this option, and I'm sure 3DS MAX's does, as well), so we can look into the actual file and possibly see what's causing this problem?
joshgrocholski
Here is the file in ASCII format. Max does indeed crash when I try to bring it back in! You have my permission to post the file on Autodesk's forum if need be. I really appreciate you guys helping me out with all this! Hope you hear from you soon.
oleg
joshgrocholski
Here is the file in ASCII format. Max does indeed crash when I try to bring it back in!
Looking at the file in ASCII, it appears to be invalid FBX. For some reason it defines “Model:cene” (the root of the entire FBX scene, which should never be explicitly defined in a file) as if it were a regular null node, and then parents it to other things. This is as wrong as it could be, which is why everything crashes (although there's always a question of what causes the exporter to do this, since other FBX files exported from MAX work fine).

In any case, what you can do for now is this: I've attached a really simple Python script which, given an invalid FBX file like this one, fixes it so it no longer crashes Houdini. The file has to be in ASCII, but hopefully this is not a big deal. You run it as following: python fix_fbx.py bad_file_name.fbx. It will write output to fixed_bad_file_name.fbx, which will work fine.

Also note that in this particular file, when you play back the camera animation, you will get geometry flickering on the screen. This is simply because the near and far clip planes are set improperly (in the FBX). If you try setting them to something like (0.5, 10000) the flickering should be less obvious.

P.S. You're very welcome.
joshgrocholski
You guys are freakin awesome! I can't imagine trying to get this kind of help from anywhere else. Thank You Thank You Thank You Thank You!!
joshgrocholski
I'm sorry, but I must really be a pain. Honestly, I don't know how to run that script. I've tried multiple ways of inputing it in, both in the hscript window and the python shell, but all I get is a syntax error or ‘blank’ not defined. I have to say, though, I am learning a ton and I will never forget any of this when all is said and done.
pclaes
on the note of workflow between houdini and pftrack:

The geo file you import will only have points in it. So make sure you have your points displayed in the viewport (on the right side of the viewport a little buttun with blue a dot on it)

You can run the command generated by pftrack by going in houdini:
File -> run script

Hope this helps.
If you have a lot of tracking markers, the cmd script might take a while as it generates a whole lot of null objects.
- I generally collapse all the nulls in a subnetwork and hide them, as I find it easier to work with the geometry file and the points.
- you can also then use the geometry file to build a rough mesh from the point cloud. - I do say rough mesh
joshgrocholski
I will admit, I'm trying to learn something here in three weeks that will probably take me all summer to grasp, but I didn't think it would be so hard to figure out how to get from one program to another. I'm so used to dragging and dropping that this is quite a chore for me. I appreciate everyone out there who has helped me so far and I hope that I can continue getting help as I need it. I promise it will die down after this coming Tuesday when my school assignment is due. Until then I think there's only one last thing I'm going to have to figure out. How exactly to I run that python script? I've tried multiple ways but I continue to get errors such as a syntax error or something is not defined.
oleg
joshgrocholski
Honestly, I don't know how to run that script. I've tried multiple ways of inputing it in, both in the hscript window and the python shell, but all I get is a syntax error or ‘blank’ not defined.
This script was meant to be launched from a regular command line, not from the Python Shell in Houdini. So, you can follow these steps:

1) Copy the fix_fbx.py script to the directory where your bad FBX files are located (say it is named C:\Oleg\BadFBX).

2) Open up Houdini, in the main menu, go to Windows->Shell. A new shell windows should appear.

3) In the shell, go to the directory where your bad FBX files are located. So, if the files are in C:\Oleg\BadFBX, type “cd C:\Oleg\BadFBX”.

4) Now you can run the script and give it the name of the file you want to fix. Type in “python fix_fbx.py bad_fbx_filename.fbx”, assuming one of the bad FBX files is named bad_fbx_filename.fbx. This should do the trick.

Also, thinking about this yesterday, is it possible that there is an object in your original 3DS MAX scene named “Scene”? If there is, you can also try renaming it to anything else and re-exporting the FBX file.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Powered by DjangoBB