Table of Contents

Class OverlayManagerWebView2Video

Namespace
VisioForge.Core.Types.X.VideoEffects
Assembly
VisioForge.Core.dll

WebView2 video overlay element that renders web pages in the overlay manager. Windows-only.

public class OverlayManagerWebView2Video : IOverlayManagerElement, IDisposable

Inheritance

Implements

Inherited Members

Constructors

OverlayManagerWebView2Video(string, int, int, int, int)

Initializes a new instance of the VisioForge.Core.Types.X.VideoEffects.OverlayManagerWebView2Video class.

public OverlayManagerWebView2Video(string location, int x, int y, int width, int height)

Parameters

location string

The URL to display.

x int

The X position.

y int

The Y position.

width int

The width.

height int

The height.

Properties

Adapter

Gets or sets the DXGI adapter index (-1 for any device).

public int Adapter { get; set; }

Property Value

int

Cache

Gets or sets the cache.

public object Cache { get; set; }

Property Value

object

Enabled

Gets or sets a value indicating whether this VisioForge.Core.Types.X.VideoEffects.IOverlayManagerElement is enabled.

public bool Enabled { get; set; }

Property Value

bool

EndTime

Gets or sets the end time (optional). The element is not drawn after it. Zero means the element has no end and stays visible from VisioForge.Core.Types.X.VideoEffects.IOverlayManagerElement.StartTime onwards.

public TimeSpan EndTime { get; set; }

Property Value

TimeSpan

Remarks

Compared against the frame timestamp, which is the buffer presentation time counted from the pipeline start - not the wall clock.

Height

Gets or sets the height of the overlay.

public int Height { get; set; }

Property Value

int

JavaScript

Gets or sets JavaScript to run on navigation completed.

public string JavaScript { get; set; }

Property Value

string

Location

Gets or sets the URL to display.

public string Location { get; set; }

Property Value

string

Lock

Gets the lock object for thread synchronization.

public object Lock { get; }

Property Value

object

Name

Gets or sets the name.

public string Name { get; set; }

Property Value

string

Opacity

Gets or sets the opacity (0.0 to 1.0).

public double Opacity { get; set; }

Property Value

double

Rotation

Gets or sets the rotation angle in degrees (0-360).

public double Rotation { get; set; }

Property Value

double

Shadow

Gets or sets the shadow settings.

public OverlayManagerShadowSettings Shadow { get; set; }

Property Value

OverlayManagerShadowSettings

StartTime

Gets or sets the start time (optional). The element is not drawn before it.

public TimeSpan StartTime { get; set; }

Property Value

TimeSpan

Remarks

Compared against the frame timestamp, which is the buffer presentation time counted from the pipeline start - not the wall clock. Leave both this and VisioForge.Core.Types.X.VideoEffects.IOverlayManagerElement.EndTime at Zero to draw the element for the whole session.

StretchMode

Gets or sets the stretch mode for the video.

public OverlayManagerImageStretchMode StretchMode { get; set; }

Property Value

OverlayManagerImageStretchMode

UserDataFolder

Gets or sets the absolute path to WebView2 user data folder location.

public string UserDataFolder { get; set; }

Property Value

string

VideoRendererSettings

Gets or sets the video renderer settings.

public VideoRendererSettingsX VideoRendererSettings { get; set; }

Property Value

VideoRendererSettingsX

VideoView

Gets or sets the video view for optional video rendering.

public IVideoView VideoView { get; set; }

Property Value

IVideoView

Width

Gets or sets the width of the overlay.

public int Width { get; set; }

Property Value

int

X

Gets or sets the X position of the overlay.

public int X { get; set; }

Property Value

int

Y

Gets or sets the Y position of the overlay.

public int Y { get; set; }

Property Value

int

ZIndex

Gets or sets the Z-Index (drawing order). Higher values are drawn on top.

public int ZIndex { get; set; }

Property Value

int

Methods

Dispose(bool)

protected virtual void Dispose(bool disposing)

Parameters

disposing bool

Dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

public void Dispose()

Initialize(bool)

Initializes the WebView2 video overlay and starts rendering.

public bool Initialize(bool autoStart = true)

Parameters

autoStart bool

If true, starts rendering immediately. If false, only preloads.

Returns

bool

true if successful; otherwise, false.

Pause()

Pauses web page rendering.

public void Pause()

Play()

Starts or resumes web page rendering.

public void Play()

Stop()

Stops web page rendering.

public void Stop()

UpdateLocation(string)

Updates the URL being displayed.

public void UpdateLocation(string location)

Parameters

location string

The new URL to display.