Class VideoView
- Namespace
- VisioForge.Core.UI.Avalonia
- Assembly
- VisioForge.Core.UI.Avalonia.dll
VideoView control for Avalonia UI framework that provides cross-platform video rendering capabilities. This control serves as a container for native video rendering on different platforms (Windows, Android, iOS).
public class VideoView : Panel, INotifyPropertyChanged, IDataContextProvider, ILogical, IThemeVariantHost, IResourceHost, IResourceNode, IStyleHost, ISetLogicalParent, ISetInheritanceParent, ISupportInitialize, INamed, IInputElement, IDataTemplateHost, ISetterValue, IChildIndexProvider, IVideoView, IDisposable, IVideoViewPushFrame, IVideoViewNativeRenderingInheritance
-
AvaloniaObjectAnimatableStyledElementVisualLayoutableInteractiveInputElementControlPanel
Implements
-
IDataContextProviderILogicalIThemeVariantHostIResourceHostIResourceNodeIStyleHostISetLogicalParentISetInheritanceParentINamedIInputElementIDataTemplateHostISetterValueIChildIndexProviderIVideoViewIVideoViewPushFrameIVideoViewNativeRendering
Inherited Members
-
Panel.BackgroundPropertyPanel.Render(DrawingContext)Panel.AffectsParentArrange<TPanel>(params AvaloniaProperty[])Panel.AffectsParentMeasure<TPanel>(params AvaloniaProperty[])Panel.ChildrenChanged(object?, NotifyCollectionChangedEventArgs)Panel.IChildIndexProvider.GetChildIndex(ILogical)Panel.IChildIndexProvider.TryGetTotalCount(out int)Panel.ChildrenPanel.BackgroundPanel.IsItemsHostPanel.IChildIndexProvider.ChildIndexChangedControl.FocusAdornerPropertyControl.TagPropertyControl.ContextMenuPropertyControl.ContextFlyoutPropertyControl.RequestBringIntoViewEventControl.LoadedEventControl.UnloadedEventControl.SizeChangedEventControl.ISetterValue.Initialize(SetterBase)Control.GetTemplateFocusTarget()Control.OnLoaded(RoutedEventArgs)Control.OnUnloaded(RoutedEventArgs)Control.OnSizeChanged(SizeChangedEventArgs)Control.OnAttachedToVisualTreeCore(VisualTreeAttachmentEventArgs)Control.OnDetachedFromVisualTreeCore(VisualTreeAttachmentEventArgs)Control.OnGotFocus(FocusChangedEventArgs)Control.OnLostFocus(FocusChangedEventArgs)Control.OnCreateAutomationPeer()Control.OnPointerReleased(PointerReleasedEventArgs)Control.OnKeyUp(KeyEventArgs)Control.OnPropertyChanged(AvaloniaPropertyChangedEventArgs)Control.UpdateDataValidation(AvaloniaProperty, BindingValueType, Exception?)Control.FocusAdornerControl.DataTemplatesControl.ContextMenuControl.ContextFlyoutControl.IsLoadedControl.TagControl.IDataTemplateHost.IsDataTemplatesInitializedControl.LoadedControl.UnloadedControl.SizeChangedInputElement.FocusablePropertyInputElement.IsEnabledPropertyInputElement.IsEffectivelyEnabledPropertyInputElement.CursorPropertyInputElement.IsKeyboardFocusWithinPropertyInputElement.IsFocusedPropertyInputElement.IsHitTestVisiblePropertyInputElement.IsPointerOverPropertyInputElement.IsTabStopPropertyInputElement.GotFocusEventInputElement.GettingFocusEventInputElement.LostFocusEventInputElement.LosingFocusEventInputElement.KeyDownEventInputElement.KeyUpEventInputElement.TabIndexPropertyInputElement.TextInputEventInputElement.TextInputMethodClientRequestedEventInputElement.PointerEnteredEventInputElement.PointerExitedEventInputElement.PointerMovedEventInputElement.PointerPressedEventInputElement.PointerReleasedEventInputElement.PointerCaptureLostEventInputElement.PointerWheelChangedEventInputElement.ContextRequestedEventInputElement.ContextCanceledEventInputElement.IsHoldingEnabledPropertyInputElement.IsHoldWithMouseEnabledPropertyInputElement.PinchEventInputElement.PinchEndedEventInputElement.PullGestureEventInputElement.PullGestureEndedEventInputElement.SwipeGestureEventInputElement.SwipeGestureEndedEventInputElement.ScrollGestureEventInputElement.ScrollGestureInertiaStartingEventInputElement.ScrollGestureEndedEventInputElement.PointerTouchPadGestureMagnifyEventInputElement.PointerTouchPadGestureRotateEventInputElement.PointerTouchPadGestureSwipeEventInputElement.TappedEventInputElement.RightTappedEventInputElement.HoldingEventInputElement.DoubleTappedEventInputElement.Focus(NavigationMethod, KeyModifiers)InputElement.OnDetachedFromVisualTreeCore(VisualTreeAttachmentEventArgs)InputElement.OnAccessKey(RoutedEventArgs)InputElement.OnAttachedToVisualTreeCore(VisualTreeAttachmentEventArgs)InputElement.OnGettingFocus(FocusChangingEventArgs)InputElement.OnLosingFocus(FocusChangingEventArgs)InputElement.OnGotFocus(FocusChangedEventArgs)InputElement.OnLostFocus(FocusChangedEventArgs)InputElement.OnKeyDown(KeyEventArgs)InputElement.OnKeyUp(KeyEventArgs)InputElement.OnTextInput(TextInputEventArgs)InputElement.OnPointerEntered(PointerEventArgs)InputElement.OnPointerExited(PointerEventArgs)InputElement.OnPointerMoved(PointerEventArgs)InputElement.OnPointerPressed(PointerPressedEventArgs)InputElement.OnPointerReleased(PointerReleasedEventArgs)InputElement.GetNextTabStopOverride()InputElement.GetPreviousTabStopOverride()InputElement.GetFirstFocusableElementOverride()InputElement.GetLastFocusableElementOverride()InputElement.OnPointerCaptureLost(PointerCaptureLostEventArgs)InputElement.ProcessTabStopOverride(IInputElement?, IInputElement?, bool, bool, ref IInputElement?)InputElement.ProcessCandidateTabStopOverride(IInputElement?, IInputElement?, IInputElement?, bool, ref IInputElement?)InputElement.OnPointerWheelChanged(PointerWheelEventArgs)InputElement.OnTapped(TappedEventArgs)InputElement.OnRightTapped(TappedEventArgs)InputElement.OnDoubleTapped(TappedEventArgs)InputElement.OnHolding(HoldingRoutedEventArgs)InputElement.OnPropertyChanged(AvaloniaPropertyChangedEventArgs)InputElement.UpdateIsEffectivelyEnabled()InputElement.GetIsHoldingEnabled(StyledElement)InputElement.SetIsHoldingEnabled(StyledElement, bool)InputElement.GetIsHoldWithMouseEnabled(StyledElement)InputElement.SetIsHoldWithMouseEnabled(StyledElement, bool)InputElement.FocusableInputElement.IsEnabledInputElement.CursorInputElement.IsKeyboardFocusWithinInputElement.IsFocusedInputElement.IsHitTestVisibleInputElement.IsPointerOverInputElement.IsTabStopInputElement.IsEffectivelyEnabledInputElement.TabIndexInputElement.KeyBindingsInputElement.IsEnabledCoreInputElement.GestureRecognizersInputElement.GotFocusInputElement.GettingFocusInputElement.LostFocusInputElement.LosingFocusInputElement.KeyDownInputElement.KeyUpInputElement.TextInputInputElement.TextInputMethodClientRequestedInputElement.PointerEnteredInputElement.PointerExitedInputElement.PointerMovedInputElement.PointerPressedInputElement.PointerReleasedInputElement.PointerCaptureLostInputElement.PointerWheelChangedInputElement.ContextRequestedInputElement.ContextCanceledInputElement.PinchInputElement.PinchEndedInputElement.PullGestureInputElement.PullGestureEndedInputElement.ScrollGestureInputElement.ScrollGestureInertiaStartingInputElement.ScrollGestureEndedInputElement.PointerTouchPadGestureMagnifyInputElement.PointerTouchPadGestureRotateInputElement.SwipeGestureInputElement.SwipeGestureEndedInputElement.PointerTouchPadGestureSwipeInputElement.TappedInputElement.RightTappedInputElement.HoldingInputElement.DoubleTappedInteractive.AddHandler(RoutedEvent, Delegate, RoutingStrategies, bool)Interactive.AddHandler<TEventArgs>(RoutedEvent<TEventArgs>, EventHandler<TEventArgs>?, RoutingStrategies, bool)Interactive.RemoveHandler(RoutedEvent, Delegate)Interactive.RemoveHandler<TEventArgs>(RoutedEvent<TEventArgs>, EventHandler<TEventArgs>?)Interactive.RaiseEvent(RoutedEventArgs)Interactive.BuildEventRoute(RoutedEvent)Layoutable.DesiredSizePropertyLayoutable.WidthPropertyLayoutable.HeightPropertyLayoutable.MinWidthPropertyLayoutable.MaxWidthPropertyLayoutable.MinHeightPropertyLayoutable.MaxHeightPropertyLayoutable.MarginPropertyLayoutable.HorizontalAlignmentPropertyLayoutable.VerticalAlignmentPropertyLayoutable.UseLayoutRoundingPropertyLayoutable.UpdateLayout()Layoutable.ApplyTemplate()Layoutable.Measure(Size)Layoutable.Arrange(Rect)Layoutable.InvalidateMeasure()Layoutable.InvalidateArrange()Layoutable.AffectsMeasure<T>(params AvaloniaProperty[])Layoutable.AffectsArrange<T>(params AvaloniaProperty[])Layoutable.MeasureCore(Size)Layoutable.MeasureOverride(Size)Layoutable.ArrangeCore(Rect)Layoutable.ArrangeOverride(Size)Layoutable.OnAttachedToVisualTreeCore(VisualTreeAttachmentEventArgs)Layoutable.OnDetachedFromVisualTreeCore(VisualTreeAttachmentEventArgs)Layoutable.OnMeasureInvalidated()Layoutable.OnPropertyChanged(AvaloniaPropertyChangedEventArgs)Layoutable.OnVisualParentChanged(Visual?, Visual?)Layoutable.WidthLayoutable.HeightLayoutable.MinWidthLayoutable.MaxWidthLayoutable.MinHeightLayoutable.MaxHeightLayoutable.MarginLayoutable.HorizontalAlignmentLayoutable.VerticalAlignmentLayoutable.DesiredSizeLayoutable.IsMeasureValidLayoutable.IsArrangeValidLayoutable.UseLayoutRoundingLayoutable.EffectiveViewportChangedLayoutable.LayoutUpdatedVisual.BoundsPropertyVisual.ClipToBoundsPropertyVisual.ClipPropertyVisual.IsVisiblePropertyVisual.OpacityPropertyVisual.OpacityMaskPropertyVisual.CacheModePropertyVisual.EffectPropertyVisual.HasMirrorTransformPropertyVisual.RenderTransformPropertyVisual.RenderTransformOriginPropertyVisual.FlowDirectionPropertyVisual.VisualParentPropertyVisual.ZIndexPropertyVisual.GetFlowDirection(Visual)Visual.SetFlowDirection(Visual, FlowDirection)Visual.InvalidateVisual()Visual.Render(DrawingContext)Visual.AffectsRender<T>(params AvaloniaProperty[])Visual.OnPropertyChanged(AvaloniaPropertyChangedEventArgs)Visual.LogicalChildrenCollectionChanged(object?, NotifyCollectionChangedEventArgs)Visual.OnAttachedToVisualTreeCore(VisualTreeAttachmentEventArgs)Visual.OnDetachedFromVisualTreeCore(VisualTreeAttachmentEventArgs)Visual.OnAttachedToVisualTree(VisualTreeAttachmentEventArgs)Visual.OnDetachedFromVisualTree(VisualTreeAttachmentEventArgs)Visual.OnVisualParentChanged(Visual?, Visual?)Visual.InvalidateMirrorTransform()Visual.BoundsVisual.ClipToBoundsVisual.ClipVisual.IsEffectivelyVisibleVisual.IsVisibleVisual.OpacityVisual.OpacityMaskVisual.CacheModeVisual.EffectVisual.HasMirrorTransformVisual.RenderTransformVisual.RenderTransformOriginVisual.FlowDirectionVisual.ZIndexVisual.VisualChildrenVisual.VisualRootVisual.BypassFlowDirectionPoliciesVisual.AttachedToVisualTreeVisual.DetachedFromVisualTreeStyledElement.DataContextPropertyStyledElement.NamePropertyStyledElement.ParentPropertyStyledElement.TemplatedParentPropertyStyledElement.ThemePropertyStyledElement.BeginInit()StyledElement.EndInit()StyledElement.ApplyStyling()StyledElement.InitializeIfNeeded()StyledElement.ILogical.NotifyAttachedToLogicalTree(LogicalTreeAttachmentEventArgs)StyledElement.ILogical.NotifyDetachedFromLogicalTree(LogicalTreeAttachmentEventArgs)StyledElement.ILogical.NotifyResourcesChanged(ResourcesChangedEventArgs)StyledElement.IResourceHost.NotifyHostedResourcesChanged(ResourcesChangedEventArgs)StyledElement.TryGetResource(object, ThemeVariant?, out object?)StyledElement.ISetLogicalParent.SetParent(ILogical?)StyledElement.ISetInheritanceParent.SetParent(AvaloniaObject?)StyledElement.IStyleHost.StylesAdded(IReadOnlyList<IStyle>)StyledElement.IStyleHost.StylesRemoved(IReadOnlyList<IStyle>)StyledElement.LogicalChildrenCollectionChanged(object?, NotifyCollectionChangedEventArgs)StyledElement.OnAttachedToLogicalTree(LogicalTreeAttachmentEventArgs)StyledElement.OnDetachedFromLogicalTree(LogicalTreeAttachmentEventArgs)StyledElement.OnDataContextChanged(EventArgs)StyledElement.OnDataContextBeginUpdate()StyledElement.OnDataContextEndUpdate()StyledElement.OnInitialized()StyledElement.OnPropertyChanged(AvaloniaPropertyChangedEventArgs)StyledElement.NameStyledElement.ClassesStyledElement.DataContextStyledElement.IsInitializedStyledElement.StylesStyledElement.StyleKeyStyledElement.ResourcesStyledElement.TemplatedParentStyledElement.ThemeStyledElement.LogicalChildrenStyledElement.PseudoClassesStyledElement.StyleKeyOverrideStyledElement.ILogical.IsAttachedToLogicalTreeStyledElement.ParentStyledElement.ActualThemeVariantStyledElement.ILogical.LogicalParentStyledElement.ILogical.LogicalChildrenStyledElement.IResourceNode.HasResourcesStyledElement.IStyleHost.IsStylesInitializedStyledElement.IStyleHost.StylingParentStyledElement.AttachedToLogicalTreeStyledElement.DetachedFromLogicalTreeStyledElement.DataContextChangedStyledElement.InitializedStyledElement.ResourcesChangedStyledElement.ActualThemeVariantChangedAnimatable.TransitionsPropertyAnimatable.OnPropertyChangedCore(AvaloniaPropertyChangedEventArgs)Animatable.TransitionsAvaloniaObject.CheckAccess()AvaloniaObject.VerifyAccess()AvaloniaObject.ClearValue(AvaloniaProperty)AvaloniaObject.ClearValue<T>(AvaloniaProperty<T>)AvaloniaObject.ClearValue<T>(StyledProperty<T>)AvaloniaObject.ClearValue<T>(DirectPropertyBase<T>)AvaloniaObject.Equals(object?)AvaloniaObject.GetHashCode()AvaloniaObject.GetValue(AvaloniaProperty)AvaloniaObject.GetValue<T>(StyledProperty<T>)AvaloniaObject.GetValue<T>(DirectPropertyBase<T>)AvaloniaObject.GetBaseValue<T>(StyledProperty<T>)AvaloniaObject.IsAnimating(AvaloniaProperty)AvaloniaObject.IsSet(AvaloniaProperty)AvaloniaObject.SetValue(AvaloniaProperty, object?, BindingPriority)AvaloniaObject.SetValue<T>(StyledProperty<T>, T, BindingPriority)AvaloniaObject.SetValue<T>(DirectPropertyBase<T>, T)AvaloniaObject.SetCurrentValue(AvaloniaProperty, object?)AvaloniaObject.SetCurrentValue<T>(StyledProperty<T>, T)AvaloniaObject.Bind(AvaloniaProperty, BindingBase)AvaloniaObject.Bind(AvaloniaProperty, IObservable<object?>, BindingPriority)AvaloniaObject.Bind<T>(StyledProperty<T>, IObservable<object?>, BindingPriority)AvaloniaObject.Bind<T>(StyledProperty<T>, IObservable<T>, BindingPriority)AvaloniaObject.Bind<T>(StyledProperty<T>, IObservable<BindingValue<T>>, BindingPriority)AvaloniaObject.Bind<T>(DirectPropertyBase<T>, IObservable<object?>)AvaloniaObject.Bind<T>(DirectPropertyBase<T>, IObservable<T>)AvaloniaObject.Bind<T>(DirectPropertyBase<T>, IObservable<BindingValue<T>>)AvaloniaObject.CoerceValue(AvaloniaProperty)AvaloniaObject.UpdateDataValidation(AvaloniaProperty, BindingValueType, Exception?)AvaloniaObject.OnPropertyChangedCore(AvaloniaPropertyChangedEventArgs)AvaloniaObject.OnPropertyChanged(AvaloniaPropertyChangedEventArgs)AvaloniaObject.RaisePropertyChanged<T>(DirectPropertyBase<T>, T, T)AvaloniaObject.SetAndRaise<T>(DirectPropertyBase<T>, ref T, T)AvaloniaObject.InheritanceParentAvaloniaObject.this[AvaloniaProperty]AvaloniaObject.this[IndexerDescriptor]AvaloniaObject.DispatcherAvaloniaObject.PropertyChangedAvaloniaObject.INotifyPropertyChanged.PropertyChanged
Constructors
VideoView()
Initializes a new instance of the VisioForge.Core.UI.Avalonia.VideoView class. Sets up the native control host, default size, and background color for video rendering.
public VideoView()Properties
Context
SDK logging context. Set by the engine via VisioForge.Core.Helpers.ContextPropagator when the view is attached. When null, lifecycle exceptions fall back to Trace.
public BaseContext Context { get; set; }Property Value
- BaseContext
Methods
Attach(IMPVCVECore)
Attaches the video view to a parent media player core engine (Windows only). Subscribes to error and stop events from the parent engine.
public void Attach(IMPVCVECore parent)Parameters
parentIMPVCVECore-
The parent media player core engine to attach to.
AttachPipeline(MediaBlocksPipeline)
Attaches a media blocks pipeline to the video view for processing. This method is not implemented in the current version.
public void AttachPipeline(MediaBlocksPipeline pipeline)Parameters
pipelineMediaBlocksPipeline-
The media blocks pipeline to attach.
CallInvoke(Delegate, params object[])
Invokes a delegate method with optional arguments. This method is provided for API compatibility but has no implementation in Avalonia.
public void CallInvoke(Delegate method, params object[] args)Parameters
methodDelegate-
The delegate method to invoke.
argsobject[]-
Optional arguments to pass to the method.
CallRefresh()
Calls a refresh operation on the video view. This method is provided for API compatibility but has no implementation in Avalonia.
public void CallRefresh()ClearUI()
Clears the user interface elements of the video view. This method is provided for API compatibility but has no implementation.
public void ClearUI()Detach(IMPVCVECore)
Detaches the video view from the specified parent media core engine (Windows only). Unsubscribes from parent events and cleans up references.
public void Detach(IMPVCVECore parent)Parameters
parentIMPVCVECore-
The parent media core engine to detach from.
DetachPipeline()
Detaches the currently attached media blocks pipeline from the video view. This method is not implemented in the current version.
public void DetachPipeline()Dispose(bool)
Releases unmanaged and optionally managed resources.
protected virtual void Dispose(bool disposing)Parameters
disposingbool-
Set to
trueto release both managed and unmanaged resources;falseto release only unmanaged resources.
Dispose()
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. Implements the IDisposable pattern for proper cleanup.
public void Dispose()~VideoView()
Finalizes an instance of the VisioForge.Core.UI.Avalonia.VideoView class.
protected ~VideoView()GetBackgroundColor()
Gets the background color of the video view as an SKColor.
public SKColor GetBackgroundColor()Returns
- SKColor
-
The background SkiaSharp.SKColor, or black if no background is set.
GetHandle()
Gets the native window handle if available for the current platform. On Android and iOS, this returns IntPtr.Zero as those platforms don't expose window handles.
public nint GetHandle()Returns
GetInvokeRequired()
Gets a value indicating whether the caller must use Invoke when calling methods on the control. In Avalonia, this always returns false as thread marshaling is handled differently.
public bool GetInvokeRequired()Returns
- bool
-
Always returns
falsein Avalonia.
GetIsHandleCreated()
Gets a value indicating whether the native window handle has been created.
public bool GetIsHandleCreated()Returns
- bool
-
trueif the handle is created and valid; otherwise,false.
GetSize()
Gets the actual size of the video view control in device-independent pixels. On Windows, this accounts for DPI scaling to return the physical size.
public Size GetSize()Returns
- Size
-
A VisioForge.Core.Types.Size structure containing the width and height.
GetUIEngine()
Gets the UI engine type used for video rendering. Returns platform-specific engine: Android_TextureView on Android, Apple_Metal on iOS, or Avalonia on other platforms.
public VideoViewUIEngine GetUIEngine()Returns
- VideoViewUIEngine
-
The VisioForge.Core.Types.VideoViewUIEngine enum value indicating the rendering engine in use.
InvokeStart()
Invokes the start operation by adding the native control host to the visual tree. Called when video playback or capture is about to begin.
public void InvokeStart()InvokeStartComplete()
Invokes operations to complete the start process. This method is intentionally left empty as no additional operations are required.
public void InvokeStartComplete()InvokeStop()
Invokes the stop operation by removing the native control host from the visual tree. Called when video playback or capture is stopping.
public void InvokeStop()InvokeVideoRendererUpdate()
Invokes a video renderer update operation. This method is intentionally left empty as the Avalonia implementation handles updates automatically.
public void InvokeVideoRendererUpdate()LogDialogClear()
Clears the contents of the log dialog. This method is provided for API compatibility but has no implementation in Avalonia.
public void LogDialogClear()LogDialogClose()
Closes the log dialog window. This method is provided for API compatibility but has no implementation in Avalonia.
public void LogDialogClose()LogDialogError(string)
Logs an error message to the dialog. This method is provided for API compatibility but has no implementation in Avalonia.
public void LogDialogError(string msg)Parameters
msgstring-
The error message to log.
PictureBoxCreate(int, int)
Creates a picture box for snapshot display with the specified dimensions (Windows only). This method is provided for API compatibility but has no implementation in Avalonia.
public void PictureBoxCreate(int width, int height)Parameters
widthint-
The width of the picture box in pixels.
heightint-
The height of the picture box in pixels.
PictureBoxDestroy()
Destroys the picture box and releases its resources (Windows only). This method is provided for API compatibility but has no implementation in Avalonia.
public void PictureBoxDestroy()PictureBoxExists()
Determines whether the picture box exists and is available (Windows only). This method is provided for API compatibility but always returns false in Avalonia.
public bool PictureBoxExists()Returns
- bool
-
Always returns
falsein Avalonia.
PictureBoxGetImage()
Gets the image currently displayed in the picture box (Windows only). This method is provided for API compatibility but always returns null in Avalonia.
public Bitmap PictureBoxGetImage()Returns
- Bitmap
-
Always returns null in Avalonia.
PictureBoxSetImage(Bitmap)
Sets the image displayed in the picture box (Windows only). This method is provided for API compatibility; Avalonia does not show the image and disposes it.
public void PictureBoxSetImage(Bitmap image)Parameters
imageBitmap-
The bitmap image to display.
PushFrame(VideoFrame)
Pushes a video frame to the software presenter for rendering. Native-embedding mode ignores pushed frames — in that mode the pipeline renders straight into the child window.
public void PushFrame(VideoFrame frame)Parameters
frameVideoFrame-
The video frame to render.
PushFrame(VideoFrameX)
Pushes an extended video frame to the software presenter for rendering. Called on a pipeline streaming thread; the frame bytes are copied here (the source buffer is owned by the pipeline and reused) and the blit is posted to the UI thread.
public void PushFrame(VideoFrameX frame)Parameters
frameVideoFrameX-
The extended video frame to render.
PushMouseButtonDown(int, int, MouseButton)
Raises the OnMouseButtonDown event with the specified coordinates and button.
public void PushMouseButtonDown(int x, int y, MouseButton button)Parameters
xint-
The X coordinate of the mouse pointer in pixels.
yint-
The Y coordinate of the mouse pointer in pixels.
buttonMouseButton-
The mouse button that was pressed.
PushMouseButtonUp(int, int, MouseButton)
Raises the OnMouseButtonUp event with the specified coordinates and button.
public void PushMouseButtonUp(int x, int y, MouseButton button)Parameters
xint-
The X coordinate of the mouse pointer in pixels.
yint-
The Y coordinate of the mouse pointer in pixels.
buttonMouseButton-
The mouse button that was released.
PushMouseMove(int, int)
Raises the OnMouseMoved event with the specified mouse coordinates.
public void PushMouseMove(int x, int y)Parameters
xint-
The X coordinate of the mouse pointer in pixels.
yint-
The Y coordinate of the mouse pointer in pixels.
Refresh()
Refreshes the control's visual state. This method is provided for API compatibility but has no implementation in the Avalonia version.
public void Refresh()ResizeRoundTo(int)
Resizes the video view to be a multiple of the specified value. This method is provided for API compatibility but has no implementation in Avalonia.
public void ResizeRoundTo(int round)Parameters
roundint-
The value to round the dimensions to.
SetHandle(nint)
Sets the native window handle for the video view. This method is not implemented in the Avalonia version as handles are managed internally.
public void SetHandle(nint handle)Parameters
handlenint-
The native window handle to set.
Exceptions
- NotImplementedException
-
Always thrown as this operation is not supported.
SetNativeRendering(bool)
Enables or disables native rendering for the video view.
Native rendering (the default) embeds a platform child window through
Avalonia.Controls.NativeControlHost; the video then has airspace behavior — it always draws
on top of Avalonia content and is not clipped by it. Passing false switches to
software rendering: frames are blitted into a WriteableBitmap that is part of the
Avalonia visual tree, so overlays, clipping and scrolling work like with any other
control, at the cost of a CPU copy per frame. Call before starting the pipeline.
public void SetNativeRendering(bool native)Parameters
nativebool-
Set to
truefor native window embedding,falsefor software rendering.
ShowMessage(string)
Shows a message dialog to the user. In the current implementation, this always returns OK without displaying a dialog.
public MessageBoxResult ShowMessage(string message)Parameters
messagestring-
The message text to display.
Returns
- MessageBoxResult
-
Always returns VisioForge.Core.Types.MessageBoxResult.OK.
ShowMessageEx(string, string, MessageBoxDialogButtons)
Shows an extended message dialog with custom caption and button configuration.
public MessageBoxResult ShowMessageEx(string message, string caption, MessageBoxDialogButtons buttons)Parameters
messagestring-
The message text to display.
captionstring-
The dialog window caption/title.
buttonsMessageBoxDialogButtons-
The button configuration to display in the dialog.
Returns
- MessageBoxResult
-
The VisioForge.Core.Types.MessageBoxResult indicating which button was clicked.
Remarks
On desktop the dialog opens modal to the window hosting this view; when the view is not attached (or its window is hidden) it falls back to the application's main window, and shows modeless if no visible main window exists either. In multi-window apps note the fallback targets the main window, not the logical parent of a hidden host. MsBox.Avalonia has no Retry/TryAgain/Ignore buttons, so some button configurations are substituted: AbortRetryIgnore renders YesNoAbort, CancelTryContinue renders YesNoCancel and RetryCancel renders OkCancel (#996). As a result VisioForge.Core.Types.MessageBoxResult.Retry, VisioForge.Core.Types.MessageBoxResult.Ignore, VisioForge.Core.Types.MessageBoxResult.Continue and VisioForge.Core.Types.MessageBoxResult.TryAgain are never returned by this method on Avalonia. (#877)
ShowMessageExAsync(string, string, MessageBoxDialogButtons)
Async variant of VisioForge.Core.UI.Avalonia.VideoView.ShowMessageEx(System.String,System.String,VisioForge.Core.Types.MessageBoxDialogButtons). Prefer this overload from async callers; unlike the synchronous version it does not require nested message pumping, so it also works on single-view Android and iOS apps.
public Task<MessageBoxResult> ShowMessageExAsync(string message, string caption, MessageBoxDialogButtons buttons)Parameters
messagestring-
The message text to display.
captionstring-
The dialog window caption/title.
buttonsMessageBoxDialogButtons-
The button configuration to display in the dialog.
Returns
- Task<MessageBoxResult>
-
The VisioForge.Core.Types.MessageBoxResult indicating which button was clicked.
Remarks
The same button substitution and dialog-ownership behavior apply as in VisioForge.Core.UI.Avalonia.VideoView.ShowMessageEx(System.String,System.String,VisioForge.Core.Types.MessageBoxDialogButtons).
OnMouseButtonDown
Occurs when a mouse button is pressed down over the video view.
public event EventHandler<MouseButtonEventArgs> OnMouseButtonDownEvent Type
- EventHandler<MouseButtonEventArgs>
OnMouseButtonUp
Occurs when a mouse button is released over the video view.
public event EventHandler<MouseButtonEventArgs> OnMouseButtonUpEvent Type
- EventHandler<MouseButtonEventArgs>
OnMouseMoved
Occurs when the mouse pointer moves over the video view.
public event EventHandler<MouseMoveEventArgs> OnMouseMovedEvent Type
- EventHandler<MouseMoveEventArgs>