All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
Loading...
Searching...
No Matches
Engine Log Handler Configuration
enum  VuLogLevel : int32_t {
  VU_LOG_LEVEL_ERROR = 0x0 ,
  VU_LOG_LEVEL_WARNING = 0x1 ,
  VU_LOG_LEVEL_INFO = 0x2 ,
  VU_LOG_LEVEL_VERBOSE = 0x3
}
 Vuforia Engine log level values. More...
 
typedef void VuLogHandler(VuLogEvent logEvent, void *clientData)
 Handler for receiving Engine log events.
 
VuLogHandlerConfig vuLogHandlerConfigDefault ()
 Default error handler configuration.
 
VuResult vuEngineConfigSetAddLogHandlerConfig (VuEngineConfigSet *configSet, const VuLogHandlerConfig *config)
 Add log handler configuration to the engine configuration to handle log events from Engine.
 

Detailed Description

Typedef Documentation

◆ VuLogHandler

typedef void VuLogHandler(VuLogEvent logEvent, void *clientData)

Handler for receiving Engine log events.

Parameters
logEventThe log event
clientDataCustom data provided by the client.

Enumeration Type Documentation

◆ VuLogLevel

enum VuLogLevel : int32_t

Vuforia Engine log level values.

Enumerator
VU_LOG_LEVEL_ERROR 

Error log message. Logged in situations that caused an operation to fail or abort.

VU_LOG_LEVEL_WARNING 

Warning log message. Logged in situations where the operation continued despite an error or unexpected condition.

VU_LOG_LEVEL_INFO 

Info log message. Information that might be useful to the user or developer but does not indicate any error or problem.

VU_LOG_LEVEL_VERBOSE 

Verbose log message. Used for very detailed information or very frequently logged information.

Function Documentation

◆ vuLogHandlerConfigDefault()

VuLogHandlerConfig vuLogHandlerConfigDefault ( )

Default error handler configuration.

Note
Use this function to initialize the VuLogHandlerConfig data structure with default values.

◆ vuEngineConfigSetAddLogHandlerConfig()

VuResult vuEngineConfigSetAddLogHandlerConfig ( VuEngineConfigSet * configSet,
const VuLogHandlerConfig * config )

Add log handler configuration to the engine configuration to handle log events from Engine.

The registered callback handler function will be invoked for every message that is logged internally by Vuforia Engine.

Note
Messages might be truncated if they exceed the internal length limits.
The handler function will be invoked on a dedicated internal Vuforia Engine thread. Clients are responsible for synchronizing their callback implementation with other threads in the client code.
Logging to the standard platform logging system will be done directly from the respective thread on which the logging calls are invoked, e.g. logging for an API call on a client thread or logging from an internal Vuforia Engine thread. As a consequence, there might be a small delay for the events delivered on the dedicated log callback thread compared to the messages logged to the standard platform logging system.
Clients should only do the minimum amount of work in the callback handler and return control as soon as possible back to Vuforia Engine. Blocking the callback thread might lead to increased memory usage and to log messages being dropped and not delivered to the callback handler.
Clients should NOT do any reentrant calls to Vuforia Engine API functions from the callback handler. Calling Vuforia APIs from the callback handler might lead to undefined behavior including crashes, instability and deadlocks. In particular, these function calls might trigger additional log events which could potentially lead to an infinite cycle.
See also the general Vuforia Engine API documentation on "Multi-threading and thread safety" as well as "Callbacks and reentrancy".
As the log messages contain largely the same information as is logged by Vuforia Engine to the platform logging system the same considerations apply regarding any sensitive information contained in the logs.