SMI RED eye tracking plugin 1.0
Defines | Functions | Variables

src/Plugin.cpp File Reference

The file contains the sources for SMI RED Scol plugin and the definition of each function of the DLL. More...

#include "Plugin.h"

Go to the source code of this file.

Defines

#define NbTplPKG   10
 Nb of Scol functions or types.

Functions

int destroySmiObj (mmachine m, int handsys, int eyeTrackingTab)
 Scol CallBack for ObjSmi destruction.
int _OpenSmiDevice (mmachine m)
 _OpenSmiDevice : This function opens a remote connection to SMI RED system
int _CloseSmiDevice (mmachine m)
 _CloseSmiDevice : This function closes a remote connection to SMI RED system
int _CBSmiConnected (mmachine m)
 _CBSmiConnected : This function sets the Callback for a connected event from SMI RED system
int getSmiConnectedCb (mmachine m, HWND h, unsigned msg, UINT id, LONG param, int *ret)
int _CBSmiDisconnected (mmachine m)
 _CBSmiDisconnected : This function sets the Callback for a disconnected event from SMI RED system
int getSmiDisconnectedCb (mmachine m, HWND h, unsigned msg, UINT id, LONG param, int *ret)
int _CBSmiCalibrationDone (mmachine m)
 _CBSmiCalibrationDone : This function sets the Callback for a calibration done event from SMI RED system
int getSmiCalibrationDoneCb (mmachine m, HWND h, unsigned msg, UINT id, LONG param, int *ret)
int _CBSmiNewFixation (mmachine m)
 _CBSmiNewFixation : This function sets the Callback for new fixation data available from SMI RED system
int getSmiNewFixationCb (mmachine m, HWND h, unsigned msg, UINT id, LONG param, int *ret)
int _CBSmiNewSample (mmachine m)
 _CBSmiNewSample : This function sets the Callback for new sample data available from SMI RED system
int getSmiNewSampleCb (mmachine m, HWND h, unsigned msg, UINT id, LONG param, int *ret)
int _StartCalibration (mmachine m)
 _StartCalibration : This function starts the calibration process for SMI RED system
int _ShowEyes (mmachine m)
 _ShowEyes : This function displays/hides eye tracking window for SMI RED system
int LoadSmi (mmachine m)
 \
 __declspec (dllexport) int ScolLoadPlugin(mmachine m
 Starting point of the DLL.
cbmachine w SCOLinitplugin (w)
 LoadSmi (m)

Variables

cbmachine ww
 Scol machine declaration for MM macros.
HWND HScol = NULL
int OBJSMISCOL
 Scol object declaration.
int SCOL_SMI_CONNECTED_CB = 0
 Scol CallBacks declaration.
int SMI_CONNECTED_CB
int SCOL_SMI_DISCONNECTED_CB = 1
int SMI_DISCONNECTED_CB
int SCOL_SMI_CALIBRATION_DONE_CB = 2
int SMI_CALIBRATION_DONE_CB
int SCOL_SMI_NEW_FIXATION_CB = 3
int SMI_NEW_FIXATION_CB
int SCOL_SMI_NEW_SAMPLE_CB = 4
int SMI_NEW_SAMPLE_CB
char * TplName [NbTplPKG]
int(* TplFunc [NbTplPKG])(mmachine m)
int TplNArg [NbTplPKG]
char * TplType [NbTplPKG]
 return

Detailed Description

The file contains the sources for SMI RED Scol plugin and the definition of each function of the DLL.

Definition in file Plugin.cpp.


Define Documentation

#define NbTplPKG   10

Nb of Scol functions or types.

//// DECLARATION OF FUNCTIONS (FOR SCOL) ///

Definition at line 611 of file Plugin.cpp.


Function Documentation

__declspec ( dllexport  )

Starting point of the DLL.

Ending point of the DLL.

Definition at line 747 of file Plugin.cpp.

int LoadSmi ( mmachine  m)

\

//// DLL CALL FUNCTIONS ///

Load the packages in Scol virtual machine

Parameters:
mmachine: the scol machine

Definition at line 699 of file Plugin.cpp.


Variable Documentation

int(* TplFunc[NbTplPKG])(mmachine m)
Initial value:

Pointers to C functions that manipulate the VM for each scol function previously defined

Definition at line 635 of file Plugin.cpp.

char* TplName[NbTplPKG]
Initial value:
{
        "ObjSmi",
  "_OpenSmiDevice",
        "_CloseSmiDevice",
  "_CBSmiConnected",
  "_CBSmiDisconnected",
  "_CBSmiCalibrationDone",
  "_CBSmiNewFixation",
  "_CBSmiNewSample",
  "_StartCalibration",
  "_ShowEyes"
}

Scol function names

Definition at line 617 of file Plugin.cpp.

int TplNArg[NbTplPKG]
Initial value:
{
        TYPTYPE,                                                                                                                                                
  5,                                                                                                                                                                    
        1,                                                                                                                                                                      
  3,                                          
  3,                                          
  3,                                          
  3,                                          
  3,                                          
  9,                                          
  2                                           
}

Nb of arguments of each scol function

Definition at line 653 of file Plugin.cpp.

char* TplType[NbTplPKG]
Initial value:
{
        NULL,                                                                                                                                                                                         
  "fun [Chn S I S I] ObjSmi",                                                                                                       
        "fun [ObjSmi] I",                                                                                                                           
  "fun [ObjSmi fun [ObjSmi u0] u1 u0] ObjSmi",                                    
  "fun [ObjSmi fun [ObjSmi u0] u1 u0] ObjSmi",                                    
  "fun [ObjSmi fun [ObjSmi u0] u1 u0] ObjSmi",                              
  "fun [ObjSmi fun [ObjSmi u0 F I I] u1 u0] ObjSmi",                        
  "fun [ObjSmi fun [ObjSmi u0 [F I I] [F I I]] u1 u0] ObjSmi",              
  "fun [ObjSmi I I I I I I I I] I",                                         
  "fun [ObjSmi I] I"                                                        
}

Prototypes of the scol functions

Definition at line 671 of file Plugin.cpp.