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, IDisposableInheritance
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
locationstring-
The URL to display.
xint-
The X position.
yint-
The Y position.
widthint-
The width.
heightint-
The height.
Properties
Adapter
Gets or sets the DXGI adapter index (-1 for any device).
public int Adapter { get; set; }Property Value
Cache
Gets or sets the cache.
public object Cache { get; set; }Property Value
Enabled
Gets or sets a value indicating whether this VisioForge.Core.Types.X.VideoEffects.IOverlayManagerElement is enabled.
public bool Enabled { get; set; }Property Value
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
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
JavaScript
Gets or sets JavaScript to run on navigation completed.
public string JavaScript { get; set; }Property Value
Location
Gets or sets the URL to display.
public string Location { get; set; }Property Value
Lock
Gets the lock object for thread synchronization.
public object Lock { get; }Property Value
Name
Gets or sets the name.
public string Name { get; set; }Property Value
Opacity
Gets or sets the opacity (0.0 to 1.0).
public double Opacity { get; set; }Property Value
Rotation
Gets or sets the rotation angle in degrees (0-360).
public double Rotation { get; set; }Property Value
Shadow
Gets or sets the shadow settings.
public OverlayManagerShadowSettings Shadow { get; set; }Property Value
StartTime
Gets or sets the start time (optional). The element is not drawn before it.
public TimeSpan StartTime { get; set; }Property Value
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
UserDataFolder
Gets or sets the absolute path to WebView2 user data folder location.
public string UserDataFolder { get; set; }Property Value
VideoRendererSettings
Gets or sets the video renderer settings.
public VideoRendererSettingsX VideoRendererSettings { get; set; }Property Value
VideoView
Gets or sets the video view for optional video rendering.
public IVideoView VideoView { get; set; }Property Value
Width
Gets or sets the width of the overlay.
public int Width { get; set; }Property Value
X
Gets or sets the X position of the overlay.
public int X { get; set; }Property Value
Y
Gets or sets the Y position of the overlay.
public int Y { get; set; }Property Value
ZIndex
Gets or sets the Z-Index (drawing order). Higher values are drawn on top.
public int ZIndex { get; set; }Property Value
Methods
Dispose(bool)
protected virtual void Dispose(bool disposing)Parameters
disposingbool
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
autoStartbool-
If true, starts rendering immediately. If false, only preloads.
Returns
- bool
-
trueif 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
locationstring-
The new URL to display.