All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
Loading...
Searching...
No Matches
Rendering-related Engine Configuration
enum  VuRenderConfigError : int32_t {
  VU_ENGINE_CREATION_ERROR_RENDER_CONFIG_UNSUPPORTED_BACKEND = 0x300 ,
  VU_ENGINE_CREATION_ERROR_RENDER_CONFIG_FAILED_TO_SET_VIDEO_BG_VIEWPORT = 0x301
}
 Rendering configuration error code type for errors occurring when creating a Vuforia Engine instance. More...
 
enum  VuRenderVBBackendType : int32_t {
  VU_RENDER_VB_BACKEND_DEFAULT = 0x1 ,
  VU_RENDER_VB_BACKEND_HEADLESS = 0x2 ,
  VU_RENDER_VB_BACKEND_GLES3 = 0x4 ,
  VU_RENDER_VB_BACKEND_DX11 = 0x5 ,
  VU_RENDER_VB_BACKEND_METAL = 0x6
}
 Render video background backend configuration. More...
 
enum  VuVideoBackgroundViewportMode : int32_t {
  VU_VIDEOBG_VIEWPORT_MODE_SCALE_TO_FILL = 0x1 ,
  VU_VIDEOBG_VIEWPORT_MODE_SCALE_TO_FIT = 0x2 ,
  VU_VIDEOBG_VIEWPORT_MODE_NATIVE_VIDEO
}
 Supported video background viewport modes. More...
 
VuRenderConfig vuRenderConfigDefault ()
 Default render configuration.
 
VuResult vuEngineConfigSetAddRenderConfig (VuEngineConfigSet *configSet, const VuRenderConfig *config)
 Add a render configuration to the engine config.
 

Detailed Description

Enumeration Type Documentation

◆ VuRenderConfigError

enum VuRenderConfigError : int32_t

Rendering configuration error code type for errors occurring when creating a Vuforia Engine instance.

Note
The error code is reported via the errorCode parameter of the vuEngineCreate() function if an error related to the rendering configuration occurs while initializing the new Engine instance.
Enumerator
VU_ENGINE_CREATION_ERROR_RENDER_CONFIG_UNSUPPORTED_BACKEND 

Unsupported render backend.

VU_ENGINE_CREATION_ERROR_RENDER_CONFIG_FAILED_TO_SET_VIDEO_BG_VIEWPORT 

Failed to set video background viewport. This is currently never reported.

◆ VuRenderVBBackendType

enum VuRenderVBBackendType : int32_t

Render video background backend configuration.

Enumerator
VU_RENDER_VB_BACKEND_DEFAULT 

Select default rendering backend for each platform. Currently: Android: OpenGL ES 3.x iOS: Metal UWP: DirectX 11 This is the default video background configuration.

VU_RENDER_VB_BACKEND_HEADLESS 

Deactivate usage of video background rendering support. Supported on all platforms.

VU_RENDER_VB_BACKEND_GLES3 

OpenGL ES 3.x. Supported on Android and iOS.

VU_RENDER_VB_BACKEND_DX11 

DirectX 11. Supported on UWP.

VU_RENDER_VB_BACKEND_METAL 

Metal. Supported on iOS.

◆ VuVideoBackgroundViewportMode

Supported video background viewport modes.

If the aspect ratio and resolution of the native video frames (see VuCameraVideoMode) and the render view (see VuRenderViewConfig) differ, Vuforia needs to know how it should adjust the video background image rendering with respect to the render view. The different modes control if and how Vuforia should scale the video background image and adjust the video background viewport inside the render view. The video background image will thereby always be centered.

Note
The aspect ratio of the video image is always preserved, only adjustments to the video background image scale and viewport are applied.
If the aspect ratio of the render view is the same as the aspect ratio of the native video then the modes VU_VIDEOBG_VIEWPORT_MODE_SCALE_TO_FILL and VU_VIDEOBG_VIEWPORT_MODE_SCALE_TO_FIT will have the same result.
If the aspect ratio of the render view is the same as the aspect ratio of the native video and additionally also the resolutions are the same then all three modes will have the same result.
Enumerator
VU_VIDEOBG_VIEWPORT_MODE_SCALE_TO_FILL 

Scales the video background to fill the whole render view. This can crop the video background image (either top and bottom or left and right). This is the default.

VU_VIDEOBG_VIEWPORT_MODE_SCALE_TO_FIT 

Scales the video background to show the full video image in the render view. The video background viewport is adjusted accordingly to the size of the video image in the render view which might show a letter box around the image.

VU_VIDEOBG_VIEWPORT_MODE_NATIVE_VIDEO 

No scaling will be applied to the video background image, it has the same resolution as the native video image. If the render view has a lower resolution than the native video, only the fraction of the image that fits into the render view will be visible. If the render view resolution is larger than the native video the whole video will be visible and the video background viewport inside the render view will be adjusted accordingly to cover the video image.

Function Documentation

◆ vuRenderConfigDefault()

VuRenderConfig vuRenderConfigDefault ( )

Default render configuration.

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