示例#1
0
        protected void Parse(Stream s)
        {
            BinaryStreamWrapper wrapper = new BinaryStreamWrapper(s, ByteOrder.BigEndian);

            this.mVersion = wrapper.ReadUInt16();
            // Initialize Effect Sections
            this.mEffectSectionList = new EffectResource.EffectSectionList(this.OnResourceChanged, s);
            this.InitEffectSectionIndices();
            // Initialize Resource Sections
            this.mResourceSectionList = new EffectResource.ResourceSectionList(this.OnResourceChanged, s);
            this.InitResourceSectionIndices();
            // Initialize Visual Effect Builders
            this.mVisualEffectSection = new EffectResource.VisualEffectSection(0, this.OnResourceChanged, wrapper.ReadUInt16());
            //this.mVisualEffectVersion = wrapper.ReadUInt16();
            //this.mVisualEffectBuilders = new SectionDataList<VisualEffectBuilder>(this.OnResourceChanged, null, s);
            // Initialize Reserved
            this.mReserved = wrapper.ReadBytes(4);
            // Initialize Handle List
            this.mVisualEffectHandleList = new VisualEffectHandleList(this.OnResourceChanged, s);
            // Initialize Visual Effect Builder Properties
            this.InitEffectNames();
            this.InitEffectBuilders();
        }