Class GifGraphicsControlBlock
Namespace: Aspose.Imaging.FileFormats.Gif.Blocks
Assembly: Aspose.Imaging.dll (25.8.0)
Gif graphics control block.
[JsonObject(MemberSerialization.OptIn)]
public class GifGraphicsControlBlock : GifBlock, IGifBlockInheritance
object ← GifBlock ← GifGraphicsControlBlock
Implements
Inherited Members
GifBlock.ExtensionIntroducer , GifBlock.Save(Stream) , GifBlock.IsChanged , object.GetType() , object.MemberwiseClone() , object.ToString() , object.Equals(object?) , object.Equals(object?, object?) , object.ReferenceEquals(object?, object?) , object.GetHashCode()
Constructors
GifGraphicsControlBlock()
Initializes a new instance of the Aspose.Imaging.FileFormats.Gif.Blocks.GifGraphicsControlBlock class.
public GifGraphicsControlBlock()GifGraphicsControlBlock(byte, ushort, byte)
Initializes a new instance of the Aspose.Imaging.FileFormats.Gif.Blocks.GifGraphicsControlBlock class.
public GifGraphicsControlBlock(byte flags, ushort delayTime, byte transparentColorIndex)Parameters
flags byte
The flags.
delayTime ushort
The delay time expressed in 1/100 seconds.
transparentColorIndex byte
The transparent color index.
GifGraphicsControlBlock(ushort, bool, byte, bool, DisposalMethod)
Initializes a new instance of the Aspose.Imaging.FileFormats.Gif.Blocks.GifGraphicsControlBlock class.
public GifGraphicsControlBlock(ushort delayTime, bool hasTransparentColor, byte transparentColorIndex, bool requiresUserInput, DisposalMethod disposalMethod)Parameters
delayTime ushort
The delay time expressed in 1/100 seconds.
hasTransparentColor bool
if set to true the transparentColorIndex is valid.
transparentColorIndex byte
The transparent color index.
requiresUserInput bool
if set to true the user input is expected.
disposalMethod DisposalMethod
The disposal method.
Fields
BlockHeaderSize
Specifies the block header size.
public const int BlockHeaderSize = 8Field Value
ExtensionLabel
Extension label.
public const byte ExtensionLabel = 249Field Value
SubBlockSize
Gets the sub-block size.
public const byte SubBlockSize = 4Field Value
Properties
DelayTime
Gets or sets the frame delay time expressed in 1/100 seconds.
public ushort DelayTime { get; set; }Property Value
DisposalMethod
Gets or sets the disposal method.
public DisposalMethod DisposalMethod { get; set; }Property Value
Flags
Gets or sets the flags.
public byte Flags { get; set; }Property Value
HasTransparentColor
Gets or sets a value indicating whether graphics control block has transparent color.
public bool HasTransparentColor { get; set; }Property Value
TransparentColorIndex
Gets or sets the transparent color index.
public byte TransparentColorIndex { get; set; }Property Value
UserInputExpected
Gets or sets a value indicating whether user input is expected.
public bool UserInputExpected { get; set; }Property Value
Methods
CreateFlags(bool, bool, DisposalMethod)
Creates the flags.
public static byte CreateFlags(bool hasTransparentColor, bool requiresUserInput, DisposalMethod disposalMethod)Parameters
hasTransparentColor bool
if set to true the Aspose.Imaging.FileFormats.Gif.Blocks.GifGraphicsControlBlock has valid transparent color index.
requiresUserInput bool
if set to true the user input is expected.
disposalMethod DisposalMethod
The disposal method.
Returns
The generated flags.
Save(Stream)
Saves the block to the specified stream.
public override void Save(Stream stream)Parameters
stream Stream
The stream to save data to.