Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

My discoveries on the AEP format #4

Open
mbasaglia opened this issue Mar 26, 2023 · 12 comments
Open

My discoveries on the AEP format #4

mbasaglia opened this issue Mar 26, 2023 · 12 comments

Comments

@mbasaglia
Copy link

Just in case someone's interested, I've been trying to figure out more details on the AEP format. I've documented my discoveries in here: https://lottiefiles.github.io/lottie-docs/aep/

I've also written a script that export the contents of an aep file into yaml, destructuring all the binary chunks into more useful data: https://gitlab.com/mattbas/python-lottie/-/blob/master/bin/aep_dump.py

I haven't been able to figure out everything, but I managed to extract information about a lot of different layer types, shapes, keyframes, etc.

@tinogithub
Copy link

I have struggled the last days to figure out how the After Effects version is encoded in the head block. Unfortunately I wasn't successfull. But I can tell that at offset(h): 27 the byte is the hex value for the build number. The build number is written in the splash window "About After Effects".

Offset 26 seems to contain the last digit from i.e. version 23.2.1. However it is not consistend.
Most of the time for X.X.0 it is 0x06, but in the case of version 22.5.0 it is 0x86.
0x0E seems to be stand for X.X.1.

Moreover I am thinking that offset 20 to 22 don't play a role at all because these change almost never.
For 15x it is: 00 5C 00
For 16x up to 22x it is: 00 5D 00
Just the current 23x has: 00 5E 00

It is just some surface analysis. But for error handling it is nice to determine which version was used to save a project.

@mbasaglia
Copy link
Author

Regarding AE version number: you can extract that data from the xmp metadata (it's after the RIFF data, at the bottom of the file)

<xmp:CreatorTool>Adobe After Effects CC 2017 (Windows)</xmp:CreatorTool>

On some versions of AE it seems to also expose the internal version number, but I've been unable to map it to the head / svap values

@knlandes
Copy link

Unfortunately the CreatorTool field of the xmp metadata is unreliable in modern versions of After Effects, at a minimum on macOS. See this bug for additional details: https://community.adobe.com/t5/after-effects-bugs/creatortool-field-of-project-metadata-isn-t-accurate-in-after-effects-2022-and-2023/idc-p/13651472

@tinogithub
Copy link

Regarding AE version number: you can extract that data from the xmp metadata (it's after the RIFF data, at the bottom of the file)

<xmp:CreatorTool>Adobe After Effects CC 2017 (Windows)</xmp:CreatorTool>

On some versions of AE it seems to also expose the internal version number, but I've been unable to map it to the head / svap values

The xmp information at the end of the file is unfortunately not of value. I have some project files to compare with and the metadata is most of the time the following from 15x up to CC 2023:

<xmp:CreatorTool>Adobe After Effects CC 2017 (Macintosh)</xmp:CreatorTool>

And as post of @knlandes points out, even Photoshop is named. In CC 2022 22.5.0 build 53 is says

<xmp:CreatorTool>Adobe Photoshop 23.2 (20220118.orig.521 930aa48) (Windows)</xmp:CreatorTool>

@ariestav
Copy link

ariestav commented Oct 4, 2023

Thank you for sharing this information. Has anybody figured out a way to get the After Effects version number for any given .aep file? Or is this not possible?

@tinogithub
Copy link

tinogithub commented Oct 4, 2023

I have started an open project with a different approach.
It is a Python script that checks some bytes in the header of the project file.
However it stills needs a growing database of all the different After Effects Versions.
I have already implemented those that I have on my system but there are still many missing. I'd be happy to get more.

https://github.com/tinogithub/aftereffects-version-check/tree/main

@ariestav
Copy link

ariestav commented Oct 4, 2023

Thank you for sharing your code! Does the method work for AEPs created both on Windows and macOS?

@tinogithub
Copy link

Yes.

@mbasaglia
Copy link
Author

I have started an open project with a different approach. It is a Python script that checks some bytes in the header of the project file. However it stills needs a growing database of all the different After Effects Versions. I have already implemented those that I have on my system but there are still many missing. I'd be happy to get more.

https://github.com/tinogithub/aftereffects-version-check/tree/main

If you need them I have a couple values I found listed here: https://lottiefiles.github.io/lottie-docs/aep/#head

@tinogithub
Copy link

Thank you @mbasaglia , during my research I had come across your information which I have already added.
Thanks again

@blakmarkit
Copy link

I have started an open project with a different approach. It is a Python script that checks some bytes in the header of the project file. However it stills needs a growing database of all the different After Effects Versions. I have already implemented those that I have on my system but there are still many missing. I'd be happy to get more.
https://github.com/tinogithub/aftereffects-version-check/tree/main

If you need them I have a couple values I found listed here: https://lottiefiles.github.io/lottie-docs/aep/#head

@mbasaglia I've added all of the 2022, 2023, and 2024 hex values (sans Beta builds) to @tinogithub's repo, if you want them for your docs. It looks like your values might be skipping 00 bytes before and after the first one, and have the extra "build" byte at the end.

https://github.com/tinogithub/aftereffects-version-check/blob/main/ae-builds.json

@inlife
Copy link

inlife commented Feb 29, 2024

Howdy folks,

I wanted to confirm that those are, indeed, the correct bytes. Furthermore, changing the 005F to 005E allowed me to open the project file in the earlier version (24 -> 23) without warning. (I was fortunate enough not to have any problems within the project)

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants