Luxand FaceSDK – Library Activation
FaceSDK is a copy-protected library, and must be activated with a license key before its use. You need to pass the license key received from Luxand, Inc. to the FSDK_ActivateLibrary function before initializing Luxand FaceSDK. Almost all FaceSDK functions will return the FSDKE_NOT_ACTIVATED error code in case the library is not activated. To retrieve your license information, call FSDK_GetLicenseInfo. This function returns the name the library is licensed to. You may need to use the FSDK_GetHardware_ID function to obtain your hardware ID if your license is restricted to one machine only. Additionally, you can find out hardware ID by running the hardwareid program (ShowHardwareID.exe for Windows), which is located in the bin directory.
To get a temporary evaluation key from Luxand, Inc., run License Key Wizard from the Start – Luxand – FaceSDK menu. You may also request this key at
http://luxand.com/facesdk/requestkey/.
FSDK_GetHardware_ID Function
Generates a Hardware ID code.
C++ Syntax:
int FSDK_GetHardware_ID(char* HardwareID);
Delphi Syntax:
function FSDK_GetHardware_ID(HardwareID: PChar): integer;
C# Syntax:
int FSDK.GetHardwareID(out string HardwareID);
VB Syntax:
Function FSDKVB_GetHardwareID(ByRef HardwareID As Byte) As Long
Java Syntax:
int GetHardware_ID(String HardwareID[]);
iOS and Android: not implemented.
Parameters:
HardwareID – address of the null-terminated string for receiving the Hardware ID code.
Return Value:
Returns FSDKE_OK if successful.
Python Syntax:
def FSDK.GetHardware_ID() -> str;
Return Value:
A Hardware ID code.
FSDK_ActivateLibrary Function
Activates the FaceSDK library.
C++ Syntax:
int FSDK_ActivateLibrary(char* LicenseKey);
Delphi Syntax:
function FSDK_ActivateLibrary(LicenseKey: PChar): integer;
C# Syntax:
int FSDK.Activate(out string LicenseKey);
VB Syntax:
Function FSDKVB_Activate(ByVal LicenseKey As String) As Long
Java and Android Syntax:
int FSDK.ActivateLibrary(String LicenseKey);
Parameters:
LicenseKey– License key you received from Luxand, Inc.
Return Value:
Returns FSDKE_OK if the registration key is valid and not expired.
Python Syntax:
def FSDK.ActivateLibrary(license_key:str);
Return Value:
None
Exceptions:
FSDK.NotActivated if key is invalid or expired.
This exception is also raised from all FSDK functions if library is not activated.
FSDK_GetLicenseInfo Function
Retrieves license information.
C++ Syntax:
int FSDK_GetLicenseInfo(char* LicenseInfo);
Delphi Syntax:
function FSDK_GetLicenseInfo(LicenseInfo: PChar): integer;
C# Syntax:
int FSDK.GetLicenseInfo(out string LicenseInfo);
VB Syntax:
Function FSDKVB_GetLicenseInfo(ByRef LicenseInfo As Byte) As Long
Java and Android Syntax:
int FSDK.GetLicenseInfo(String LicenseInfo[]);
Parameters:
LicenseInfo – address of the null-terminated string for receiving the license information. This variable should be allocated no less than 256 bytes of memory.
Return Value:
Returns FSDKE_OK if successful.
Python Syntax:
def FSDK.GetLicenseInfo() -> str;
Return Value:
The license information string.