|
Emotiv EPOC plugin 1.0
|
00001 00019 #ifndef EMOSTATE_DLL_H 00020 #define EMOSTATE_DLL_H 00021 #include <sys/types.h> 00022 00023 #if !defined(EDK_STATIC_LIB) && !defined(EDK_UTILS_ONLY) 00024 00025 #ifdef _WIN32 00026 #ifdef EMOSTATE_DLL_EXPORTS 00027 #define EMOSTATE_DLL_API __declspec(dllexport) 00028 #else 00029 #define EMOSTATE_DLL_API __declspec(dllimport) 00030 #endif 00031 #else 00032 #define EMOSTATE_DLL_API 00033 #endif 00034 00035 #else 00036 #define EMOSTATE_DLL_API extern 00037 #endif 00038 00042 typedef void* EmoStateHandle; 00043 00044 extern "C" 00045 { 00049 typedef enum EE_EmotivSuite_enum { 00050 00051 EE_EXPRESSIV = 0, EE_AFFECTIV, EE_COGNITIV 00052 00053 } EE_EmotivSuite_t; 00054 00058 typedef enum EE_ExpressivAlgo_enum { 00059 00060 EXP_NEUTRAL = 0x0001, 00061 EXP_BLINK = 0x0002, 00062 EXP_WINK_LEFT = 0x0004, 00063 EXP_WINK_RIGHT = 0x0008, 00064 EXP_HORIEYE = 0x0010, 00065 EXP_EYEBROW = 0x0020, 00066 EXP_FURROW = 0x0040, 00067 EXP_SMILE = 0x0080, 00068 EXP_CLENCH = 0x0100, 00069 EXP_LAUGH = 0x0200, 00070 EXP_SMIRK_LEFT = 0x0400, 00071 EXP_SMIRK_RIGHT = 0x0800 00072 00073 } EE_ExpressivAlgo_t; 00074 00078 typedef enum EE_AffectivAlgo_enum { 00079 00080 AFF_EXCITEMENT = 0x0001, 00081 AFF_MEDITATION = 0x0002, 00082 AFF_FRUSTRATION = 0x0004, 00083 AFF_ENGAGEMENT_BOREDOM = 0x0008 00084 00085 } EE_AffectivAlgo_t; 00086 00090 typedef enum EE_CognitivAction_enum { 00091 00092 COG_NEUTRAL = 0x0001, 00093 COG_PUSH = 0x0002, 00094 COG_PULL = 0x0004, 00095 COG_LIFT = 0x0008, 00096 COG_DROP = 0x0010, 00097 COG_LEFT = 0x0020, 00098 COG_RIGHT = 0x0040, 00099 COG_ROTATE_LEFT = 0x0080, 00100 COG_ROTATE_RIGHT = 0x0100, 00101 COG_ROTATE_CLOCKWISE = 0x0200, 00102 COG_ROTATE_COUNTER_CLOCKWISE = 0x0400, 00103 COG_ROTATE_FORWARDS = 0x0800, 00104 COG_ROTATE_REVERSE = 0x1000, 00105 COG_DISAPPEAR = 0x2000 00106 00107 } EE_CognitivAction_t; 00108 00112 typedef enum EE_SignalStrength_enum { 00113 00114 NO_SIGNAL = 0, BAD_SIGNAL, GOOD_SIGNAL 00115 00116 } EE_SignalStrength_t; 00117 00119 00123 typedef enum EE_InputChannels_enum { 00124 EE_CHAN_CMS = 0, EE_CHAN_DRL, EE_CHAN_FP1, EE_CHAN_AF3, EE_CHAN_F7, 00125 EE_CHAN_F3, EE_CHAN_FC5, EE_CHAN_T7, EE_CHAN_P7, EE_CHAN_O1, 00126 EE_CHAN_O2, EE_CHAN_P8, EE_CHAN_T8, EE_CHAN_FC6, EE_CHAN_F4, 00127 EE_CHAN_F8, EE_CHAN_AF4, EE_CHAN_FP2 00128 } EE_InputChannels_t; 00129 00131 00136 typedef enum EE_EEG_ContactQuality_enum { 00137 EEG_CQ_NO_SIGNAL, EEG_CQ_VERY_BAD, EEG_CQ_POOR, 00138 EEG_CQ_FAIR, EEG_CQ_GOOD } EE_EEG_ContactQuality_t; 00139 00141 00151 EMOSTATE_DLL_API EmoStateHandle ES_Create(); 00152 00154 00161 EMOSTATE_DLL_API void ES_Free(EmoStateHandle state); 00162 00164 00169 EMOSTATE_DLL_API void ES_Init(EmoStateHandle state); 00170 00172 00181 EMOSTATE_DLL_API float ES_GetTimeFromStart(EmoStateHandle state); 00182 00184 00192 EMOSTATE_DLL_API int ES_GetHeadsetOn(EmoStateHandle state); 00193 00195 00201 EMOSTATE_DLL_API int ES_GetNumContactQualityChannels(EmoStateHandle state); 00202 00204 00212 EMOSTATE_DLL_API EE_EEG_ContactQuality_t ES_GetContactQuality(EmoStateHandle state, int electroIdx); 00213 00215 00232 EMOSTATE_DLL_API int ES_GetContactQualityFromAllChannels(EmoStateHandle state, EE_EEG_ContactQuality_t* contactQuality, size_t numChannels); 00233 00235 00241 EMOSTATE_DLL_API int ES_ExpressivIsBlink(EmoStateHandle state); 00242 00244 00251 EMOSTATE_DLL_API int ES_ExpressivIsLeftWink(EmoStateHandle state); 00252 00254 00261 EMOSTATE_DLL_API int ES_ExpressivIsRightWink(EmoStateHandle state); 00262 00264 00270 EMOSTATE_DLL_API int ES_ExpressivIsEyesOpen(EmoStateHandle state); 00271 00273 00280 EMOSTATE_DLL_API int ES_ExpressivIsLookingUp(EmoStateHandle state); 00281 00283 00290 EMOSTATE_DLL_API int ES_ExpressivIsLookingDown(EmoStateHandle state); 00291 00293 00300 EMOSTATE_DLL_API int ES_ExpressivIsLookingLeft(EmoStateHandle state); 00301 00303 00310 EMOSTATE_DLL_API int ES_ExpressivIsLookingRight(EmoStateHandle state); 00311 00313 00324 EMOSTATE_DLL_API void ES_ExpressivGetEyelidState(EmoStateHandle state, float* leftEye, float* rightEye); 00325 00327 00345 EMOSTATE_DLL_API void ES_ExpressivGetEyeLocation(EmoStateHandle state, float* x, float* y); 00346 00348 00355 EMOSTATE_DLL_API float ES_ExpressivGetEyebrowExtent(EmoStateHandle state); 00356 00358 00365 EMOSTATE_DLL_API float ES_ExpressivGetSmileExtent(EmoStateHandle state); 00366 00368 00375 EMOSTATE_DLL_API float ES_ExpressivGetClenchExtent(EmoStateHandle state); 00376 00377 00379 00386 EMOSTATE_DLL_API EE_ExpressivAlgo_t ES_ExpressivGetUpperFaceAction(EmoStateHandle state); 00387 00389 00396 EMOSTATE_DLL_API float ES_ExpressivGetUpperFaceActionPower(EmoStateHandle state); 00397 00399 00406 EMOSTATE_DLL_API EE_ExpressivAlgo_t ES_ExpressivGetLowerFaceAction(EmoStateHandle state); 00407 00409 00416 EMOSTATE_DLL_API float ES_ExpressivGetLowerFaceActionPower(EmoStateHandle state); 00417 00419 00427 EMOSTATE_DLL_API int ES_ExpressivIsActive(EmoStateHandle state, EE_ExpressivAlgo_t type); 00428 00430 00437 EMOSTATE_DLL_API float ES_AffectivGetExcitementLongTermScore(EmoStateHandle state); 00438 00440 00447 EMOSTATE_DLL_API float ES_AffectivGetExcitementShortTermScore(EmoStateHandle state); 00448 00450 00458 EMOSTATE_DLL_API int ES_AffectivIsActive(EmoStateHandle state, EE_AffectivAlgo_t type); 00459 00461 00466 EMOSTATE_DLL_API float ES_AffectivGetMeditationScore(EmoStateHandle state); 00467 00469 00474 EMOSTATE_DLL_API float ES_AffectivGetFrustrationScore(EmoStateHandle state); 00475 00477 00482 EMOSTATE_DLL_API float ES_AffectivGetEngagementBoredomScore(EmoStateHandle state); 00483 00485 00492 EMOSTATE_DLL_API EE_CognitivAction_t ES_CognitivGetCurrentAction(EmoStateHandle state); 00493 00495 00502 EMOSTATE_DLL_API float ES_CognitivGetCurrentActionPower(EmoStateHandle state); 00503 00505 00510 EMOSTATE_DLL_API int ES_CognitivIsActive(EmoStateHandle state); 00511 00512 00514 00521 EMOSTATE_DLL_API EE_SignalStrength_t ES_GetWirelessSignalStatus(EmoStateHandle state); 00522 00524 00530 EMOSTATE_DLL_API void ES_Copy(EmoStateHandle a, EmoStateHandle b); 00531 00533 00541 EMOSTATE_DLL_API int ES_AffectivEqual(EmoStateHandle a, EmoStateHandle b); 00542 00544 00552 EMOSTATE_DLL_API int ES_ExpressivEqual(EmoStateHandle a, EmoStateHandle b); 00553 00555 00563 EMOSTATE_DLL_API int ES_CognitivEqual(EmoStateHandle a, EmoStateHandle b); 00564 00566 00577 EMOSTATE_DLL_API int ES_EmoEngineEqual(EmoStateHandle a, EmoStateHandle b); 00578 00580 00588 EMOSTATE_DLL_API int ES_Equal(EmoStateHandle a, EmoStateHandle b); 00589 00591 00597 EMOSTATE_DLL_API void ES_GetBatteryChargeLevel(EmoStateHandle state, int* chargeLevel, int* maxChargeLevel); 00598 }; 00599 00600 #endif // EMOSTATE_DLL_H 00601
1.7.3