Class ImageSequenceSourceBlock
- Namespace
- VisioForge.Core.MediaBlocks.Sources
- Assembly
- VisioForge.Core.dll
Image sequence source block for generating video streams from image sequences in a folder. Provides image sequence playback functionality using GStreamer's imagesequencesrc element, supporting various image formats with configurable frame rates and looping options for slideshow creation, timelapse playback, and video sequence processing in video productions. Implements the VisioForge.Core.MediaBlocks.Sources.SourceMediaBlock. Implements the VisioForge.Core.MediaBlocks.IMediaBlockInternals. Implements the IDisposable.
public class ImageSequenceSourceBlock : SourceMediaBlock, IMediaBlock, IDisposable, IMediaBlockInternalsInheritance
Implements
Inherited Members
Extension Methods
Constructors
ImageSequenceSourceBlock(ImageSequenceSourceSettings)
Initializes a new instance of the VisioForge.Core.MediaBlocks.Sources.ImageSequenceSourceBlock class with custom image sequence settings. Configures the image sequence source for folder-based image playback with specified parameters.
public ImageSequenceSourceBlock(ImageSequenceSourceSettings settings)Parameters
settingsImageSequenceSourceSettings-
The image sequence settings controlling folder path, frame rate, and format parameters.
Properties
Input
Gets the primary input pad (none for source blocks that read from image folders).
public override MediaBlockPad Input { get; }Property Value
Inputs
Gets all input pads available on this block (none for source blocks).
public override MediaBlockPad[] Inputs { get; }Property Value
Output
Gets the primary video output pad for the generated video stream.
public override MediaBlockPad Output { get; }Property Value
Outputs
Gets all output pads available on this block (single video output).
public override MediaBlockPad[] Outputs { get; }Property Value
Settings
Gets or sets the image sequence configuration settings that control folder scanning and video generation.
public ImageSequenceSourceSettings Settings { get; set; }Property Value
Type
Gets the media block type identifier for image sequence source operations.
public override MediaBlockType Type { get; }Property Value
Methods
Build()
Builds and initializes the image sequence source within the pipeline context. Scans image folder, configures video generation, and prepares output for downstream processing.
public override bool Build()Returns
- bool
-
trueif the image sequence source was successfully built and configured; otherwise,false.
CleanUp()
Cleans up all resources associated with the image sequence operations, including element disposal and buffers.
public void CleanUp()Dispose(bool)
Releases unmanaged and managed resources used by the image sequence source. Properly closes image resources and disposes of GStreamer elements and video generation components.
protected override void Dispose(bool disposing)Parameters
disposingbool-
trueto release both managed and unmanaged resources;falseto release only unmanaged resources.
GetCore()
Gets the core GStreamer element wrapper for advanced configuration and monitoring.
public BaseElement GetCore()Returns
- BaseElement
-
The ImageSequenceSource wrapper element for advanced configuration options.
GetElement()
Gets the native GStreamer element for direct GStreamer pipeline integration.
public Element GetElement()Returns
- Element
-
The image sequence source GStreamer element.
IsAvailable(ImageSequenceSourceSettings)
Determines whether image sequence support is available for the specified settings. Checks for required imagesequencesrc element and format support based on the image types.
public static bool IsAvailable(ImageSequenceSourceSettings settings)Parameters
settingsImageSequenceSourceSettings-
The image sequence settings to check for compatibility and element availability.
Returns
- bool
-
trueif image sequence support is available for the specified settings; otherwise,false.
IMediaBlockInternals.SetContext(MediaBlocksPipeline)
Sets the pipeline context for this image sequence source, providing access to the parent pipeline and logging context.
void IMediaBlockInternals.SetContext(MediaBlocksPipeline pipeline)Parameters
pipelineMediaBlocksPipeline-
The parent MediaBlocks pipeline containing this image sequence source.