PROGRAMMING GUIDE
You must first initialize the HOOPS Exchange libraries before making any function calls. This is a three step process:
To minimize memory, HOOPS Exchange explicit loads libraries only as needed. This requires you to make the following function calls to load the Exchange DLLs:
#ifdef _WIN64 const TCHAR *pcLibPath=_T("..\\..\\..\\..\\bin\\win64\\"); #else const TCHAR *pcLibPath=_T("..\\..\\..\\..\\bin\\win32\\"); #endif if (!A3DSDKLoadLibrary(pcLibPath)) { printf("Failed to load A3DLIBS.dll!"); return false; }
After loading the libraries, you need to register your license. You can get license keys from the release download page on the Developer Zone. You should copy these keys into the A3DSDKLicenseKey.h file and then make the following API call:
A3DLicPutLicense(A3DLicPutLicenseFile, pcCustomerKey, pcVariableKey);
Verify that your application is compatible the Exchange libraries by comparing the version of the libraries that you compiled with and the version of the libraries that was loaded. Obtain the version identifiers for the currently installed HOOPS Exchange Library by invoking the A3DDllGetVersion function. Evaluate the returned values as follows:
A3DInt32 iMajorVersion=5,iMinorVersion=0; A3DDllGetVersion(&iMajorVersion,&iMinorVersion);
Initialize the Exchange API using these version identifiers.
if (A3DDllInitialize(A3D_DLL_MAJORVERSION, A3D_DLL_MINORVERSION) != A3D_SUCCESS) { A3DSDKUnloadLibrary(); return false; }