Search - User list
Full Version: Alembic camera transform data?
Root » Houdini Indie and Apprentice » Alembic camera transform data?
BrianHanke
I'm messing around with camera tracking in Blender and exporting to Houdini as Alembic. It's working well, but I do have one question: where is the camera transform data actually stored? I can't find a single keyframe anywhere, yet somehow the camera is magically moving. Thanks!
jsmack
BrianHanke
It's working well, but I do have one question: where is the camera transform data actually stored?

It's stored in the alembic.
BrianHanke
jsmack
It's stored in the alembic.

Obviously. How do I access it in Houdini?
BrianHanke
Update for anyone who runs into this issue in the future:

Still no clue how to access Alembic camera transform data in Houdini, but it's possible to export it via FBX from Blender. You need to select the tracked camera, go to Object Constraint Properties and click on Constraint to F-Curve. Then, export to FBX using the default settings. Houdini will bring that in as a camera with all the keyframes you'd expect.
old_school
First let's talk /obj based Houdini:

To “see” the camera transform value at the current frame, add an Alembic Xform node pointed to the .abc file and point it to your camera at question. Feed in the correct frame and fps and it returns the transform data.
To see the actual values, you can use the following hscript commands:

vorigin(“”,“/obj/cam1”)
vtorigin(“”,“/obj/cam1”)
vrorigin(“”,“/obj/cam1”)
or
origin(“”,“/obj/cam1”, “TX”) where “TX” can be (“TX”, “TY”, “TZ”, “RX”, “RY”, “RZ”, “SX”, “SY” or “SZ” )

If you want, you can add a Null Object and feed it in these expressions as a visualizer if you wish.

The fast reading of alembic and the fact that there is no parameter updates is one of the built-in features that makes Alembic so fast.
Alembic is a baked format that does not support keyframes or any spline type animation curve. Anything time based is baked as samples. Camera transforms are captured at frame rate defined in the export as transform samples in the .abc file.

Houdini uses the Alembic Xform Object to fetch a specific Alembic Primitives transform sample at the given frame with the correct FPS set.

Alembic is a heavily optimized file format that is designed to read very fast from disk and Houdini's Alembic support is utilizing the best that Houdini has in /obj space to support the format as fast as possible w/o having parameter dependency updates, etc.



For Solaris, to see the camera transform values at the current fraome, you can use the USD framework with it's Alembic schema to bring in the Alembic Camera and inspect the values on the primitives properties.

You can use a SubLayer LOP to load in the .abc file and directly inspect the camera transform data at the current fraome in the Scene Graph Details.
Look at the xformOp:transform subdata on the camera to see the values update as you increment the framerange.

See the attached hip file and don't forget to write out the Alembic from /out/alembic ROP.
old_school
Alembic and USD only support raw values and not keyframes with segments btw.
Not every application interpolates keyframe functions the same so that is why it is all raw values.
The fact you are adding keyframes and segments and perhaps fitting the animation data which FBX can certainly do is you manufacturing data that wasn't there.

All fine as long as you don't use this as Alembic/USD truth, cause it isn't. It would be an FBX bake on top of Alembic/USD.
BrianHanke
old_school
To “see” the camera transform value at the current frame, add an Alembic Xform node pointed to the .abc file and point it to your camera at question. Feed in the correct frame and fps and it returns the transform data.

Thanks for much for the detailed explanation. I gave it a test run in my original setup and it's working great. Always glad to learn something new!
jsmack
BrianHanke
Obviously. How do I access it in Houdini?

As Jeff said, use an alembic xform node to use a transform stored in an alembic. If you need access to the exploded TRS channels, either use chops/constraints referencing an alembic xform node, or use the hom alembic extensions in python to read the matrix directly–then feed the matrix to the desired explode matrix function to extract the required channels: t, r, s.
djfite97
Hello. Does this camera track export out of Blender to Houdini workflow still work? Is ABC the best file format to do this in? thx
Strangeland1
I second the question of if this still works well or not? Been trying to import camera alembic from blender into houdini and it isn't lining up very well even though I have the same frame range / framerate settings.
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