Class ImageSequenceSourceSettings
- Namespace
- VisioForge.Core.Types.X.Sources
- Assembly
- VisioForge.Core.dll
Image sequence source settings for reading image sequences from a folder.
public class ImageSequenceSourceSettings : IVideoCaptureBaseVideoSourceSettings, IVideoMixerSource, IVideoSourceSettings, IMediaBlockSettingsInheritance
Implements
Inherited Members
Constructors
ImageSequenceSourceSettings(string, string)
Initializes a new instance of the VisioForge.Core.Types.X.Sources.ImageSequenceSourceSettings class.
public ImageSequenceSourceSettings(string folderPath, string filePattern = null)Parameters
folderPathstring-
The folder path containing the image sequence.
filePatternstring-
The file pattern, or the name of one file to play once (optional, will auto-detect if not provided).
Properties
FilePattern
Gets or sets the image file pattern (e.g., "image_%05d.jpg"), or the name of one file to play once. A literal percent sign in a pattern is written as "%%". Pass it to the constructor when the folder holds no image with a supported extension: the constructor rejects such a folder otherwise.
public string FilePattern { get; set; }Property Value
FolderPath
Gets or sets the folder path containing the image sequence. Setting it drops the image files of the previous folder, and the new one is read when they are next needed.
public string FolderPath { get; set; }Property Value
FrameRate
Gets or sets the frame rate for the image sequence playback.
public VideoFrameRate FrameRate { get; set; }Property Value
ImageFiles
Gets the image file names found in the folder. Empty when the folder set after construction cannot be read. The list is kept from the first read that finds an image until VisioForge.Core.Types.X.Sources.ImageSequenceSourceSettings.FolderPath is set again.
public string[] ImageFiles { get; }Property Value
- string[]
IsLive
True for a live source: the images are read without a preroll, and a frame decoded too late can be dropped.
public bool IsLive { get; set; }Property Value
NumBuffers
Gets or sets the number of buffers to output before sending Stop call (-1 = unlimited).
The count starts over wherever playback starts: at the start, at every Loop pass, and at every seek, including the one a rate change sends.
public int NumBuffers { get; set; }Property Value
StartIndex
Gets or sets the starting index for the image sequence. When not set, it is detected. With a VisioForge.Core.Types.X.Sources.ImageSequenceSourceSettings.FilePattern holding one %d, %i or %u conversion in its file name, each read looks for the lowest number with a file the pattern names, and gives 0 when it names none. Otherwise it comes from the name of the first of VisioForge.Core.Types.X.Sources.ImageSequenceSourceSettings.ImageFiles.
public int StartIndex { get; set; }Property Value
Methods
CreateBlock()
Creates the media block for this image sequence source.
public MediaBlock CreateBlock()Returns
- MediaBlock
-
MediaBlock.
GetImageCount()
Gets the number of image files detected in the folder.
public int GetImageCount()Returns
- int
-
The count of image files.