Table of Contents

Class CVHandDetectedEventArgs

Namespace
VisioForge.Core.Types.Events
Assembly
VisioForge.Core.dll

Provides data for events that indicate the detection of hands in a video frame. This class encapsulates an array of VisioForge.Core.Types.VideoProcessing.CVHand objects, each representing a detected hand.

public class CVHandDetectedEventArgs : EventArgs

Inheritance

Inherited Members

Examples

// Assume an event handler is registered for a hand detection event.
public void OnHandDetected(object sender, CVHandDetectedEventArgs e)
{
    Console.WriteLine($"Hands detected: {e.Hands.Length}");

    foreach (var hand in e.Hands)
    {
        Console.WriteLine($"  Hand: {hand.Rectangle} (Gesture: {hand.Gesture})");
        // Further process hand data, e.g., track hand movements, recognize specific gestures.
    }
}

Remarks

This event argument is typically used in computer vision applications for gesture recognition, human-computer interaction, or activity monitoring. Hand detection uses trained machine learning models (Haar cascades, MediaPipe, or deep learning models) to locate hands in video frames. Each CVHand object contains bounding box coordinates, detected gesture type, and optionally hand landmarks (fingertip positions, palm center). The Hands array may contain multiple hands when both hands are visible or multiple people are in the frame. Gesture recognition enables touchless interaction for gaming, presentations, smart home control, and accessibility applications. Common gestures include open palm, closed fist, pointing, thumbs up/down, and custom gesture configurations. Detection accuracy is affected by hand position, orientation, lighting conditions, skin tone, and background complexity. Hand tracking across frames provides smoother interaction and enables gesture sequences or trajectory-based commands. Applications include virtual reality controllers, sign language recognition, medical applications, and industrial control systems. Consider implementing gesture state machines to recognize complex multi-step gestures and reduce false triggers. Performance optimization may involve region-of-interest processing focused on expected hand locations. Events are raised on background processing threads, requiring thread-safe handling and UI marshaling.

Constructors

CVHandDetectedEventArgs(CVHand[])

Initializes a new instance of the VisioForge.Core.Types.Events.CVHandDetectedEventArgs class.

public CVHandDetectedEventArgs(CVHand[] hands)

Parameters

hands CVHand[]

An array of VisioForge.Core.Types.VideoProcessing.CVHand objects representing the detected hands.

Properties

Hands

Gets an array of VisioForge.Core.Types.VideoProcessing.CVHand objects, each representing a detected hand in the frame.

public CVHand[] Hands { get; }

Property Value

CVHand[]

Methods

ToString()

Returns a string that represents the current VisioForge.Core.Types.Events.CVHandDetectedEventArgs instance. The string includes the number of detected hands and details for each hand.

public override string ToString()

Returns

string

A String that represents this instance.