Table of Contents

Interface IVideoProcessor

Namespace
VisioForge.Core.Types.VideoProcessing
Assembly
VisioForge.Core.dll

Defines the contract for a video processing component. This interface provides methods for processing individual video frames and querying supported formats.

public interface IVideoProcessor

Examples

// Assume 'customProcessor' is an instance of a class implementing IVideoProcessor.
IVideoProcessor customProcessor = GetCustomVideoProcessor();

// Check supported formats
VideoFormatX[] supportedFormats = customProcessor.GetSupportedFrameFormats();
Console.WriteLine("Supported video formats:");
foreach (var format in supportedFormats)
{
    Console.WriteLine($"- {format}");
}

// Process a video frame (conceptual)
// VideoFrameX frameX = GetNextVideoFrameX();
// customProcessor.ProcessFrame(frameX);

// VideoFrame frame = GetNextVideoFrame();
// customProcessor.ProcessFrame(frame);

// Set a context if required by the processor
// customProcessor.SetContext(myApplicationContext);

Remarks

Implementations of this interface can perform various video manipulations, such as applying effects, analyzing content, or transforming frames. It supports processing both legacy VisioForge.Core.Types.VideoFrame and modern VisioForge.Core.Types.X.VideoFrameX types.

Methods

GetSupportedFrameFormats()

Retrieves an array of VisioForge.Core.Types.X.VideoFormatX that are supported by this video processor.

VideoFormatX[] GetSupportedFrameFormats()

Returns

VideoFormatX[]

An array of supported video formats.

ProcessFrame(VideoFrameX)

Processes a video frame of type VisioForge.Core.Types.X.VideoFrameX. This method is typically used for processing frames from the MediaBlocks engine.

void ProcessFrame(VideoFrameX frame)

Parameters

frame VideoFrameX

The VisioForge.Core.Types.X.VideoFrameX to process.

ProcessFrame(VideoFrame)

Processes a video frame of type VisioForge.Core.Types.VideoFrame. This method is typically used for processing frames from legacy video sources.

void ProcessFrame(VideoFrame frame)

Parameters

frame VideoFrame

The VisioForge.Core.Types.VideoFrame to process.

SetContext(BaseContext)

Sets the operational context for the video processor. This can be used to provide necessary dependencies or shared resources to the processor.

void SetContext(BaseContext context)

Parameters

context BaseContext

The VisioForge.Core.BaseContext to set.