Unknown error code from IAAFEssenceData

Developers
2005-08-24
2013-04-29
  • Thomas Estrade

    Thomas Estrade - 2005-08-24

    I have used the method: IAAFEssenceData::Read.

    HRESULT res = S_OK;
    IAAFEssenceData *data; (has been initialized)
    size_t size_req = 144000;
    uint8_t *buffer = new uint8_t[144000];
    aafUInt32 nb_bytes_read;

    res = data->Read((aafUInt32)size_req, buffer, &nb_bytes_read);

    then res == 0x0004
    nb_bytes_read == 768

    and there are some differences between buffer and the same segment of the real data embedded in the AAF file.

    What's have happened? Is there a solution to this problem?

     
    • Thomas Estrade

      Thomas Estrade - 2005-08-24

      Sometimes I have :

                           res == 0x0004
                           nb_bytes_read == 768

      and the data has not been totaly read.

       
      • Thomas Estrade

        Thomas Estrade - 2005-08-24

        Sorry for the last comment, it should have been :

        Sometimes I have : 

        res == 0x0004 
        nb_bytes_read == 0

        and the data has not been totaly read.

         
        • John Emmas

          John Emmas - 2005-08-24

          Someone might correct me - but as far as I know, 0x0004 isn't a valid return code. Does this happen repeatedly with the same AAF files or is it random?

          Also, what kind of essence? Pictures or sound?

           
    • Thomas Estrade

      Thomas Estrade - 2005-08-24

      Yes, I' did not found this error code in the AAFResult.h; and that's why I've done a such title to this thread.

      The essence kinds are DV SMPTE for video (PAL 50i 25Mbps 4/3), BWF for audio.
      There is 1 DV media (video + 2 audio tracks ".dif"), and 4 BWF medias in the AAF file. The error don't occured everytime, but it seems that's especially bug on the DV.
      In fact, I copy a buffer of DV, then complete with the 4 BWF, and make this recursive until the end of essence.

      It appears after the first frame, here and there in the stream. Sometimes essences are correctly transfered.

       
      • John Emmas

        John Emmas - 2005-08-24

        This is a total guess - but check that your code (and the AAF library modules) are being compiled with compatible settings.

        e.g. If you're compiling under Windows, check that the structure alignment settings are the same for every moduile (8 byte / 1 byte or whatever). Some modules (specifically in the OM code branch) specifically require 8 byte alignment under Windows. Also, check that some modules aren't being compiled as single threaded, whereas others might be mutli-threaded.

        The fact that it sometimes happens and sometimes doesn't is a bit strange though.

         
        • Thomas Estrade

          Thomas Estrade - 2005-08-24

          Contrary to VS6, VS7 doesn't allow to set the byte alignment.

          For the single or multi-threaded mode, I don't have touch any project of the AAF-SDK. I think there is no problem with that.

           
          • John Emmas

            John Emmas - 2005-08-24

            Well, that's me out of ideas.... :-(

             
    • Thomas Estrade

      Thomas Estrade - 2005-08-24

      When an error occured on the DV, an another will on different audio tracks...

       

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks