Hello! I spent all day to try export camera data and layer orientaion from AE to blender… but…
I export selected data but your script does not convert it properly.
I can see some commented lines in your script like //var temp_yrot = layerCopy.orientation.valueAtTime(t, false)[1];
I had a small breakthrough with understanding the Matrix math for export objects. I am offering up a new revision to the is script with this new math code in place. I threw out all the old math code and put new code in place. The camera does seem to animate and move the correct way. However I make no claims that this implementation is pixel perfect or will work for tracking or with animated lenses. For basic motion graphics usage it should allow you to export the camera from After Effects to Blender.
You can also include font objects and footage layers for export as well. Any text layer in After Effects will become a font object in Blender. Any footage layer will become an image mapped plane. But there seems to be a bug in the After Effects API that prevents me from detecting if a layer is scaling in After Effects so any layers with scaling animations will not be transferred. I found a bug in the AE API where the Anchor Point is not reported correctly either. So any layer with animated anchor points will probably not transfer correctly. Also the API bug that prevents After Effects from writing a LF/CR on OSX still exists (I reported this seven years ago…nice job Adobe) which effectively makes the exporter useless on OSX unless you know how to repair the text file output (I don’t).
This version does work with CS6 as far as my testing goes.
I offer this up for people to play with but with the number of bugs in the After Effects API I can no longer spend time developing this.
Give it a try and feel free to report bugs but be aware that some might be un-fixable at this time.
Hey Atom, this Script is awesome, just discovered it now, wish I had sooner.
I just did a quick test with the latest AE CC 2014.
Animated Camera with a parent Null also Animated (Great)
Dimensions, FPS all correct.
type came across too but was slightly off it’s position (note: not animated) could be the Adobe API anchor point bug. (Still useful though).
Images imported all textured, only had to switch MIP map off to make it clearer.
Wouldn’t bring animation on an image directly, but to work around it I just parented the image to a null, animated the null and it came across perfectly.
It does what you said it does, and is extremely useful for Motion GFX work, I usually work from blender to AE, but occasionally I’ve wanted to go the other way and this does the job even though it’s unfinished, thanks for you work on this, much appreciated. You’re Rad!
I’m not sure how to make this reply - please bear with me. I have been using the AE CC camera tracker and find it very efficient and accurate in most cases. I have not yet tried the referenced script to see if I can export the AE cam data. The work around I have developed, however, does work quite well in my opinion. Specifically, I track the footage in AE. Then, I create multiple solid layers sized about 50 X 50 pixels and lock them to selected track markers in the field of view, always maintaining at least 8 properly spaced in position and depth. When played, the solids track the live footage perfectly. I then render and save the comp as an image sequence. This is then input to Blender and tracked with its 3D tracker. This results in Blender camera movement that enables solid lock-down of 3D objects. A bonafide exporter would be perfect and perhaps the referenced script will do it. In the meanwhile, though requiring two steps, the workaround is quite effective. Hope this idea is of some use.
Please keep on working on this script! I am using After Effects CC, and it seems to be a little off, maybe it works better with cs6? Its just a little to fast in blender compared to the real one, i am trying to change frame rates and such to get it fully working. Anyone having the same problems?
Don’t mean to beat a dead horse by accident, but using CC 2014 doesn’t work for me. The .py file, upon importing shows up all in 1 line across the screen, not in multiple succeeding lines. Running the script doesn’t work, which I suspect is because all the code is smashed together into one giant, long line.
Then copying the nicely laid out script into Blender.
Before running the script you should also delete the default camera and cube. I kept thinking my import wasn’t working at first because the imported AE camera was hidden inside the default cube.
Hello and thanks for continuing to work on this script. I see in the May 30,2014 post that you were offering an updated script, but I don’t see a link. Can you repost it or tell me what I am missing?
Hi Chris, the link is in the first post (it’s amazing that it’s still working with CC) :
/uploads/default/original/3X/d/f/df5a900dd1eb548c3c0dc2130f6d154da9d67f8d.zipd=1401456824