Class VisioForgeX
- Namespace
- VisioForge.Core
- Assembly
- VisioForge.Core.dll
Provides static methods for initializing, managing, and destroying the VisioForge SDK. This class serves as the main entry point for setting up the SDK environment and controlling its lifecycle.
public static class VisioForgeXInheritance
Inherited Members
Examples
// Initialize the SDK when your application starts.
VisioForgeX.InitSDK();
// Check if the SDK is initialized.
if (VisioForgeX.IsSDKInitialized)
{
Console.WriteLine("VisioForge SDK is ready.");
}
// Perform media operations...
// Destroy the SDK when your application exits to release resources.
VisioForgeX.DestroySDK();
Remarks
Proper initialization and destruction of the SDK are crucial for resource management and application stability. The SDK relies on GStreamer, and this class handles the underlying GStreamer initialization and cleanup.
Properties
DebugLevel
Gets or sets the debug level for GStreamer messages. This controls the verbosity of logging from the underlying GStreamer framework.
public static DebugLevel DebugLevel { get; set; }Property Value
- DebugLevel
IsSDKInitialized
Gets a value indicating whether the VisioForge SDK is currently initialized.
public static bool IsSDKInitialized { get; }Property Value
Methods
DestroySDK()
Destroys the VisioForge SDK, releasing all allocated resources. This method should be called when the application no longer needs the SDK to prevent resource leaks.
public static bool DestroySDK()Returns
- bool
-
trueif the SDK was successfully destroyed; otherwise,false.
InitSDK(ContextX, bool)
Initializes the VisioForge SDK synchronously. This method performs the necessary setup for the SDK, including GStreamer initialization.
public static void InitSDK(ContextX context = null, bool editing = false)Parameters
contextContextX-
Optional. The VisioForge.Core.GStreamer.ContextX to use for initialization. If
null, a default context is created. editingbool-
Optional. A boolean value indicating whether the SDK is initialized for editing purposes. Defaults to
false.
InitSDKAsync(ContextX, bool)
Initializes the VisioForge SDK asynchronously. This method performs the necessary setup for the SDK, including GStreamer initialization.
public static Task InitSDKAsync(ContextX context = null, bool editing = false)Parameters
contextContextX-
Optional. The VisioForge.Core.GStreamer.ContextX to use for initialization. If
null, a default context is created. editingbool-
Optional. A boolean value indicating whether the SDK is initialized for editing purposes. Defaults to
false.