freeMXF.org
http://www.freemxf.org/forum/

Mxfsplit from mxf avid files...
http://www.freemxf.org/forum/viewtopic.php?f=2&t=150
Page 1 of 1

Author:  madjarian [ Fri May 09, 2008 2:25 pm ]
Post subject:  Mxfsplit from mxf avid files...

hello,
i'am new to this forum and i have downloaded the sources files on cvs.
first, i whish to thank the freeMXF team for this work.

i'have compiled the beta version mxflib-beta-1.0.1 with visual c++ 2008 express.

i can unwrap video essence from avid mxf,
but when I try to unwrap mxf audio file from avid mxf with -s options the result stream file is not in wave format.
the file appears to be raw data.

in dict.xml i'seen
"Oliver Added extra properties for Avid MXF (extract later)"

is there a sample to extract wav audio from avid mxf ?

and my last question:
there is somes options in source that are commented like

//fprintf( stderr," [-i] Split Index Table Segments \n" );
//fprintf( stderr," [-g] Split Generic Containers into Elements \n" );
fprintf( stderr," [-w:n] Split AESBWF Elements into n-channel wave files \n" );
//fprintf( stderr," [-m] Subdivide AESBWF Elements into mono wave files \n" );
//fprintf( stderr," [-s] Subdivide AESBWF Elements into stereo wave files \n" );
//fprintf( stderr," [-p] Split Partitions \n");

but the command line parser seems to use this options, Why ??

thank you

ps if anyone want some mxf files from avid i can publish the files on our ftp.

Author:  Pardus [ Tue May 13, 2008 8:26 am ]
Post subject: 

The -s flag (SplitStereo) isn't used in mxfsplit, the -w flag (SplitWave) however is.

Apart from that, the header in an AVID WAV file contains some extra chunks which may prevent the essence from being recognized. (I'd have to check how this translates into a WAV file wrapped inside an mxf file, but I don't have a suitable mxf file available)

An optional solution could be to prepend a WAV header to the RAW PCM essence yourself.
The structure is very simple:

Code:
      fourcc      fRIFF;            // 0
      LEUInt32   RIFF_len;         // 4
      fourcc      fWAVE;            // 8

      fourcc      ffmt_;            // 12
      LEUInt32   fmt__len;         // 16

      LEUInt16   format;            // 20
      LEUInt16   nchannels;         // 22
      LEUInt32   samplespersec;      // 24
      LEUInt32   avgbps;            // 28
      LEUInt16   blockalign;         // 32
      LEUInt16   bitspersample;      // 34

      fourcc      data;            // 36
      LEUInt32   data_len;         // 40
                              // 44


and the code to fill out the fields can be copied fom the mxfsplit application.

Code:
void WriteWaveHeader(FileHandle File, Int16 Channels, UInt32 SamplesPerSec, UInt16 BitsPerSample, UInt32 DataSize /*=0*/)

Page 1 of 1 All times are UTC
Powered by phpBB® Forum Software © phpBB Group
https://www.phpbb.com/