C# Class ProjectWerner.API.Camera3D

Inheritance: ICamera3D
Mostra file Open project: GregorBiswanger/ProjectWerner

Public Methods

Method Description
Camera3D ( ) : System

Set MouthOpeValue to default 30 Check for kinect check for camera Setup camera

OnEventArrived ( object sender, System.Management.EventArrivedEventArgs e ) : void

event is fired when usb device is (dis)connected

OnFaceLost ( object sender, EventArgs e ) : void

fires when face is lost

OnFaceVisible ( object sender, EventArgs e ) : void

fires when face is lost

OnMouthClosed ( object sender, EventArgs e ) : void

fired when mouth is closed sets IsFaceMouthOpen to false

OnMouthOpened ( object sender, EventArgs e ) : void

fired when mouth is opened sets IsFaceMouthOpen to true

Speech ( string message ) : void

output string as speech on speaker german for realsense windows system language for kinect

Private Methods

Method Description
BodyReader_FrameArrived ( object sender, BodyFrameArrivedEventArgs e ) : void

is called when camera sees sth

CallAction ( DetectionResult detectionResult, EventArgs>.Action resultYes, EventArgs>.Action resultNo ) : void

Calls Action depending on DetectionResult

CheckKinect ( ) : void

check if kinect senosr is availble

CheckRealSense ( ) : void

check for Realsense in device manager searches for DeviceId VID_8086&PID_0A66

FaceReader_FrameArrived ( object sender, Microsoft.Kinect.Face.FaceFrameArrivedEventArgs e ) : void

when face is found calls this event

OnNewImageAvailable ( object sender, SharpSenses.ImageEventArgs imageEventArgs ) : void
Sensor_IsAvailableChanged ( object sender, IsAvailableChangedEventArgs e ) : void

Handles the event which the sensor becomes unavailable (E.g. paused, closed, unplugged).

SetupCamera ( ) : void

open kamera and add events preferes kinect if realsense and kinect are both connected

SetupKinect ( ) : void

setup kinect start search for bodies start bodyframereader to add body to facereader start facereader adds faceframereader to track mouth

SetupRealSense ( ) : void

create and open real sense camera uses Capability.FaceTracking, Capability.FacialExpressionTracking

Usb ( ) : void

setup event handler that recognizes ubs device (dis)connected

Method Details

Camera3D() public method

Set MouthOpeValue to default 30 Check for kinect check for camera Setup camera
public Camera3D ( ) : System
return System

OnEventArrived() public method

event is fired when usb device is (dis)connected
public OnEventArrived ( object sender, System.Management.EventArrivedEventArgs e ) : void
sender object
e System.Management.EventArrivedEventArgs
return void

OnFaceLost() public method

fires when face is lost
public OnFaceLost ( object sender, EventArgs e ) : void
sender object
e System.EventArgs
return void

OnFaceVisible() public method

fires when face is lost
public OnFaceVisible ( object sender, EventArgs e ) : void
sender object
e System.EventArgs
return void

OnMouthClosed() public method

fired when mouth is closed sets IsFaceMouthOpen to false
public OnMouthClosed ( object sender, EventArgs e ) : void
sender object
e System.EventArgs
return void

OnMouthOpened() public method

fired when mouth is opened sets IsFaceMouthOpen to true
public OnMouthOpened ( object sender, EventArgs e ) : void
sender object
e System.EventArgs
return void

Speech() public method

output string as speech on speaker german for realsense windows system language for kinect
public Speech ( string message ) : void
message string
return void