Library loading and initialization
Before using EasyAR Sense features, initialization is required. During initialization, EasyAR Sense establishes necessary environments and verifies the License Key.
Non-android platforms
For iOS/macOS/visionOS/Windows platforms, library loading is generally achieved through dynamic linking during compilation. Reference the EasyAR library as shown in examples, and add the EasyAR library header files when needed.
Initialization only requires calling initialize and passing the license key.
Android platform
For the Android platform, library loading is typically done through java.lang.System.loadLibrary.
Initialization only requires calling initialize and passing the current Activity and License Key. This will automatically call java.lang.System.loadLibrary.
If you need to place libEasyAR.so in a non-default location (e.g., requiring dynamic download during runtime), you should instead call initialize and pass the current Activity, License Key, and the storage path of libEasyAR.so.
For more complex requirements, you can separate the three steps of loading libEasyAR.so, setting the Activity, and verifying the License Key. You can first call loadLibraries, then call setupActivity, followed by calling initializeKey.