示例#1
0
        void SyncWriteFileHeader()
        {
            riffChunk = new RiffChunk(this.stream);
              riffChunk.WriteFourCC(RiffAviFourCCCode.Avi);

              RiffChunk listHdrl = riffChunk.AddChild(RiffAviFourCCCode.List);
              listHdrl.WriteFourCC(RiffAviFourCCCode.Hdrl);

              RiffChunk avihChunk = listHdrl.AddChild(RiffAviFourCCCode.Avih);
              WriteAvihHeaderStructure(avihChunk);
              avihChunk.Close();

              RiffChunk listStrl = listHdrl.AddChild(RiffAviFourCCCode.List);
              listStrl.WriteFourCC(RiffAviFourCCCode.Strl);

              RiffChunk strhChunk = listStrl.AddChild(RiffAviFourCCCode.Strh);
              WriteStrhHeaderStructure(strhChunk);
              strhChunk.Close();

              RiffChunk strfChunk = listStrl.AddChild(RiffAviFourCCCode.Strf);
              WriteStrfHeaderStructure(strfChunk);
              strfChunk.Close();

              listStrl.Close();

              listHdrl.Close();

              listMovi = riffChunk.AddChild(RiffAviFourCCCode.List);
              listMovi.WriteFourCC(RiffAviFourCCCode.Movi);
        }