Classes | |
struct | VuLibraryVersionInfo |
Vuforia Engine library version information. More... | |
Typedefs | |
typedef struct VuEngine_ | VuEngine |
Vuforia Engine handle. | |
Enumerations | |
enum | VuEngineCreationError : int32_t { VU_ENGINE_CREATION_ERROR_NONE = 0x0 , VU_ENGINE_CREATION_ERROR_DEVICE_NOT_SUPPORTED = 0x1 , VU_ENGINE_CREATION_ERROR_PERMISSION_ERROR = 0x2 , VU_ENGINE_CREATION_ERROR_LICENSE_ERROR = 0x3 , VU_ENGINE_CREATION_ERROR_INITIALIZATION } |
Vuforia Engine instance creation error codes. More... | |
Functions | |
VuResult | vuEngineCreate (VuEngine **engine, const VuEngineConfigSet *configSet, VuErrorCode *errorCode) |
Create a Vuforia Engine instance. | |
VuResult | vuEngineDestroy (VuEngine *engine) |
Destroy a Vuforia Engine instance. | |
VuResult | vuEngineStart (VuEngine *engine) |
Start a Vuforia Engine instance. | |
VuResult | vuEngineStop (VuEngine *engine) |
Stop a Vuforia Engine instance. | |
VuBool | vuEngineIsRunning (const VuEngine *engine) |
Return VU_TRUE if the given Vuforia Engine instance has been started. | |
VuLibraryVersionInfo | vuEngineGetLibraryVersionInfo () |
Get the Vuforia Engine library version information. | |
Engine is the main entry point for interacting with the Vuforia SDK. It is an instance of the Vuforia Engine.
A Vuforia Engine instance can be created, destroyed and should be coupled with the lifecycle of your application.
A Vuforia Engine instance maintains a list of Observers that are used to observe the real world and report Observations (see Observers section).
A Vuforia Engine instance can be configured with a set of EngineConfig data structures to define the general behavior of the Engine (see EngineConfig section).
enum VuEngineCreationError : int32_t |
Vuforia Engine instance creation error codes.
VuResult vuEngineCreate | ( | VuEngine ** | engine, |
const VuEngineConfigSet * | configSet, | ||
VuErrorCode * | errorCode ) |
Create a Vuforia Engine instance.
engine | Will be set to the created Engine instance on success, otherwise stays unmodified |
configSet | Set of configurations for creating the Engine instance |
errorCode | Optional output error code (can be NULL). The error code will only be set if the call fails, otherwise stays unmodified |
errorCode
provides the specific reason for the error.The parameter errorCode
reports a synchronous error happening during the Engine instance creation process. In order to handle errors that occur asynchronously after the Engine instance has already been created and have a fundamental impact on the Engine lifecycle (e.g. Engine stopped internally due to an invalid license key or run-time camera operation issues), add a VuErrorHandlerConfig configuration to the VuEngineConfigSet used for Engine creation.
The error code for synchronously reported errors has the generic type VuErrorCode (as opposed to the more specific VuEngineCreationError type) because Engine creation may fail for multiple reasons incl. configuration errors. Engine creation error codes fall into 2 main categories:
The error codes for asynchronously reported errors use the type VuEngineError, see details on error conditions and the error handler configuration mechanism in the documentation of the VuErrorHandlerConfig data structure.
Each error code has a unique value across the various error types. You can compare the returned error code with the values of the general VuEngineCreationError type as well as the respective error types for the configurations used when creating the Engine instance, e.g. VuLicenseConfigError or VuEngineError to determine the reason for the failure.
Your App must fulfill platform-specific permission / configuration requirements in order to successfully create an Engine instance. Your App is responsible for executing the following platform-specific actions prior to invoking vuEngineCreate(), otherwise the Engine creation call may fail or Engine may not work properly:
Video capturing and network device capability: Add the following snippet to the <Capabilities> tag in your App's Package.appxmanifest to enable camera capturing and full network capabilities, otherwise Engine will not work properly:
Destroy a Vuforia Engine instance.
This will release all resources used by the Engine instance and implicitly stop the Engine instance if it is still running. It is recommended to explicitly shutdown/free any resources prior to destroying the Engine instance.
Start a Vuforia Engine instance.
This may implicitly start any internal resources of observers and controllers that have been activated or started prior to starting the Engine instance.
Stop a Vuforia Engine instance.
This will also deactivate all observers and stop any running controllers
VuLibraryVersionInfo vuEngineGetLibraryVersionInfo | ( | ) |
Get the Vuforia Engine library version information.