public void Load(SwfStream stream, uint length, byte version) { CharacterID = stream.ReadUShort(); Depth = stream.ReadUShort(); Matrix = stream.ReadMatrix(); CxForm = stream.TagPosition < length ? stream.ReadCxForm(false) : VGCxForm.Identity; }
public ButtonRecord(SwfStream stream, Type defButtonType, out bool ok) { mFlags = stream.ReadByte(); ok = (mFlags != 0); if (!ok) return; bool hasBlend = (mFlags & 0x20) != 0; bool hasFilters = (mFlags & 0x10) != 0; CharacterID = stream.ReadUShort(); CharacterDepth = stream.ReadUShort(); CharacterMatrix = stream.ReadMatrix(); if (defButtonType == typeof(Tags.DefineButton2Tag)) { CxForm = stream.ReadCxForm(true); Filters = hasFilters ? Filter.ReadFilterList(stream) : new Filter[0]; Blending = hasBlend ? (BlendMode)stream.ReadByte() : BlendMode.Normal; } else { CxForm = VGCxForm.Identity; Filters = new Filter[0]; Blending = BlendMode.Normal; } }
public void Load(SwfStream stream, uint length, byte version) { mFlags = stream.ReadByte(); Depth = stream.ReadUShort(); if (HasCharacter) CharacterID = stream.ReadUShort(); if (HasMatrix) Matrix = stream.ReadMatrix(); if (HasCxForm) CxForm = stream.ReadCxForm(true); if (HasRatio) Ratio = stream.ReadUShort(); if (HasName) Name = stream.ReadString(); if (HasClipDepth) ClipDepth = stream.ReadUShort(); if (HasActions) Actions = new ClipActions(stream); }
public void Load(SwfStream stream, uint length, byte version) { CharacterID = stream.ReadUShort(); CxForm = stream.ReadCxForm(false); }
public void Load(SwfStream stream, uint length, byte version) { mFlags = stream.ReadUShort(); Depth = stream.ReadUShort(); if (HasClassName || (HasImage && HasCharacter)) ClassName = stream.ReadString(); if (HasCharacter) CharacterID = stream.ReadUShort(); if (HasMatrix) Matrix = stream.ReadMatrix(); if (HasCxForm) CxForm = stream.ReadCxForm(true); if (HasRatio) Ratio = stream.ReadUShort(); if (HasName) Name = stream.ReadString(); if (HasClipDepth) ClipDepth = stream.ReadUShort(); Filters = HasFilterList ? Filter.ReadFilterList(stream) : new Filter[0]; if (HasBlendMode) BlendMode = (BlendMode)stream.ReadByte(); if (HasCacheAsBitmap) BitmapCache = stream.ReadByte(); if (HasActions) Actions = new ClipActions(stream); }