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

Cannot parse mxf style aaf #53

Closed
emcodemall opened this issue Jun 19, 2019 · 2 comments
Closed

Cannot parse mxf style aaf #53

emcodemall opened this issue Jun 19, 2019 · 2 comments

Comments

@emcodemall
Copy link

Hi, thanks for this great library!
To be honest i don't know why there exist 2 totally different aaf file styles, one MS Compound file type and the other more like MXF style. However, the AAF C++ API seems to support both. Should pyaaf2 also support both? ..example file attached.

aaf_mxf_style.zip

@markreidvfx
Copy link
Owner

I've never heard of it either! Could you point me to were C++ SDK has support for it or the docs about it? What application is generating it? Looks like just MXF file header to me. If this is a thing, read support could be added rather easily with the existing MXF parser.

@emcodemall
Copy link
Author

Hey Mark, thanks for the reply!
The example mxf style type i uploaded was created using Avid Media Toolkit AMT.
I still don't understand the reasons why they implemented the different storage formats in the original AAF SDK; but it looks like they support 3 different types (mxf, ms compound and xml) and they were prepared to use a different "default" format in possible future versions.
It looks like references to this can be found throughout the whole code, whenever a file is opened.
Example: ref-impl/src/com-api/CAAFModule.CPP
Whenever you find a variable containing the term pFileKind.

Another example:
ref-impl\include\AAFFileKinds.h


// AAF file encoded using the default encoding for the particular SDK
// release.
const aafUID_t kAAFFileKind_DontCare =
{0,0,0,{0,0,0,0,0,0,0,0}};


// AAF files encoded as structured storage with a 512 bytes sector size
const aafUID_t kAAFFileKind_Aaf512Binary =
{ 0x42464141, 0x000d, 0x4d4f, {0x06, 0x0e, 0x2b, 0x34, 0x01, 0x01, 0x01, 0xff } };

// AAF files structured storage with a 4096 bytes sector size
const aafUID_t kAAFFileKind_Aaf4KBinary =
{0x92b02efb, 0xaf40, 0x4896, {0xa5, 0x8e, 0xd1, 0x57, 0x2f, 0x42, 0x2b, 0x58 } };

// AAF files encoded as XML (text)
const aafUID_t kAAFFileKind_AafXmlText =
{ 0xfe0d0101, 0x60e1, 0x4e78, { 0xb2, 0xcd, 0x2b, 0x03, 0xdb, 0xb0, 0xfa, 0x87 } };

// AAF files encoded as KLV (binary) (MXF)
//
const aafUID_t kAAFFileKind_AafKlvBinary =
{0x4b464141, 0x000d, 0x4d4f, {0x06, 0x0e, 0x2b, 0x34, 0x01, 0x01, 0x01, 0xff } };


But it looks like the example project aaffmtconv can be used to translate between the storage types, so from my perspective it is not needed for pyaaf2 to support more than one type.

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

2 participants