SDK Configuration Properties
Refer various SDK config properties applicable for Unity integration
Last updated
Refer various SDK config properties applicable for Unity integration
Last updated
Unity WebAR sdk package allows user to handle the behavior of the sdk by configuring the different parameters
To customize the sdk properties open blippar settings and go to the inspector tab.
Description
When SDK and unity components with webar-* attributes are loaded, the AR experience starts automatically by default. In case the AR experience has to be started only after an event or user intervention, then auto-init attribute can be set to "false".
Note: If auto-init="false" is assigned, the WEBARSDK.Init() method has to be called to start the WebAR experience. Please note that auto-init is associated with initializing the sdk core whereas auto-start enables the user to control when to start the tracking in the app.
Description
When sdk and unity components with webar-* attributes are loaded, the AR experience starts automatically by default. In case the AR experience has to be started only after an event or user intervention, then the auto-start attribute can be set to "false".
Note: If auto-start="false" is assigned, the WEBARSDK.StartTracking() method has to be called to start the WebAR experience/tracking. Please note that auto-init is associated with initializing the sdk core whereas auto-start enables the user to control when to start the tracking in the app.
Description
By default, sdk assumes Static-Camera-With-A-Moving-Stage i.e. 'static-camera' = 'true'. However, it can be changed to Moving-Camera-With-A-Static-Stage by setting 'static-camera' = 'false'.
Description
Auto Scale is enabled by default. To disable the auto scale, pass boolean 'false' in the argument and call this function after Init(). What is Auto Scaling in context of 'Marker Tracking' & 'Surface Tracking'? Marker Tracking:The scaling is applied in such a way that a (1,1) unit plane fits the width/height of the marker(where unit is meter). Surface Tracking:It scales the AR object based on distance from the camera
Description
It enables auto marker detection so that user doesn't have to manually click the scan button, rather it detects automatically when it recognises a marker.
Note: If auto-marker-detection="true" is assigned, the scan button disappears from the phone screen during marker tracking and it starts scanning automatically.
Description
Capturing screenshots in a Unity web application involves capturing the current state of the application's viewport and saving it as an image file. This can be useful for various purposes, such as sharing gameplay moments, creating documentation, or debugging.
"Enable Photo UI" parameter allows you to show/hide the screenshot button state, to show the button just check the Enable Photo UI button and uncheck for hide.
Description
To enable/disable the rendering of the 3D scene on the desktop without any tracking. When the value is set to "true", the 3D scene is rendered as seen by the default virtual camera on the desktop browser (without tracking). When set to "false", the default qr code page is displayed on the desktop browser. Default value is "false".
Description
To show/hide a "Try on Mobile" button displayed on the desktop browser. On clicking this button, it shows the QR code which can be scaned from the mobile device to load the application. This can be useful when render-scene-on-desktop attribute is set to "true". Default value is "false".
Description
To enable/disable tracking on the desktop browser. This will be useful while developing the marker tracking application on the desktop itself. It also works with the developer console's mobile simulator in Chrome desktop browser. Right now only Marker tracking is supported on the desktop browser. When set to "false", tracking is disabled on the desktop browser and the default qr code page is seen. When set to "true", tracking is enabled on the desktop browser and the camera view is seen. Default value is "false". Also by default the camera view displayed is a mirrored image of the real world. To enable/disable this mirroring see enable-mirroring-on-desktop attribute for more details.
Description
To enable/disable mirroring of the camera view displayed on the desktop browser when enable-tracking-on-desktop is set to "true". When set to "false", mirroring of the camera view is disabled on the desktop browser. When set to "true", mirroring of the camera view is enabled on the desktop browser. Default value is "true".
WebAR SDK loading screen can be configured to customize the logo, style of the splash screen, UI screens (shown by SDK) etc using the following SDK configuration parameters.
Blippar Unity SDK package allows you to customize your API. There are several SDK attributes that you can define for customization. This API can be applied for customizing the loading screen animation to display any logo image, size, colour, progress ring, ring colour instead of displaying the default loading screen. For example: and many more.
To customize the loading screen animation follow the steps below:
Click on the 'Blippar' Menu tab and from the drop-down, select the option 'Loading Screen'.
The loading screen tab will be displayed on the screen
A default template will be selected as the template that would be used for generating the build.
You can use the default template as a base and modify to create new templates. You can also choose to create as many templates as required.
Provide the name of the logo and store the required assets into the Assets/WEBGLTemplates/Blippar/images. This is the folder location in which the image files must be stored in order to effectively trigger the customized animation.
Enter the details of customization for logo width, height, progress dot ring scale, ring colour, alert border colour etc based on your requirement.
Click on 'Save Template' to save the modified as the default. You can alternatively select the option to 'Save as new Template'. Refer image below:
Description
Changes the circular logo in the loading splash screen.
Description
Changes the width and height of the circular logo in the loading splash screen.
Description
Changes the size/scale of the dotted loading ring which runs indefinitely until the splash screen disappears.
Description
Changes the color of the dotted loading ring which runs indefinitely until the splash screen disappears.
Description
Changes the size of the loading progress update ring.
Descriptiona
Changes the color of the loading progress update ring.
Description
Changes the thickness of the loading progress update ring.
Description
"default" or "circular" - Default loading screen, loads the experience and shows in numeric format. Circular progress bar shows a loading circular ring.
Description
On iOS Safari browser, a Camera permission request notice is displayed before asking the user to allow access to the Camera. This attribute changes the border color of the notice alert dialog.
Description
On iOS Safari browser, a Camera permission request notice is displayed before asking the user to allow access to the Camera. This attribute changes the border thickness of the notice alert dialog.
Description
On iOS Safari browser, a Camera permission request notice is displayed before asking the user to allow access to the Camera. This attribute changes the border radius of the notice alert dialog.
Description
On iOS Safari browser, a Camera permission request notice is displayed before asking the user to allow access to the Camera. This attribute changes the background color of the notice alert dialog.
Description
On iOS Safari browser, a Camera permission request notice is displayed before asking the user to allow access to the Camera. This attribute changes the text color in the notice alert dialog.
Description
On iOS Safari browser, a Camera permission request notice is displayed before asking the user to allow access to the Camera. This attribute changes the button color in the notice alert dialog.
Description
On iOS Safari browser, a Camera permission request notice is displayed before asking the user to allow access to the Camera. This attribute changes the button text color in the notice alert dialog.
Description
On iOS Safari browser, a Camera permission request notice is displayed before asking the user to allow access to the Camera. This attribute changes the button height in the notice alert dialog.
Description
On iOS Safari browser, a Camera permission request notice is displayed before asking the user to allow access to the Camera. This attribute changes the border radius of the OK button in the notice alert dialog.
Description
On iOS Safari browser, a Camera permission request notice is displayed before asking the user to allow access to the Camera. This attribute changes the camera permission text in the notice alert dialog.
Description
On iOS Safari browser, a Camera permission request notice is displayed before asking the user to allow access to the Camera. This attribute changes the camera permission button text in the notice alert dialog.
Description
On iOS Safari browser, a Camera permission request notice is displayed before asking the user to allow access to the Camera. This attribute changes the motion sensor permission text in the notice alert dialog.
Description
On iOS Safari browser, a Camera permission request notice is displayed before asking the user to allow access to the Camera. This attribute changes the motion sensor permission button text in the notice alert dialog.
Description
Changes the background color of the loading splash screen, landscape warning screen or any device/server communication error.
Description
Changes the text color of the landscape warning screen, or any device/server communication error.
Description
Changes the logo image displayed in a desktop browser where the user is asked to scan the QR code or type the url in Android or iOS mobile browsers.
Description
Changes the width and height of the logo image displayed in a desktop browser where the user is asked to scan the QR code or type the url in Android or iOS mobile browsers.
Description
Changes the warning symbol image displayed in the landscape warning screen, or any device/server communication error.
Description
Changes the width and height of the warning symbol image displayed in the landscape warning screen, or any device/server communication error.
Description
Navigate to the 'Tracking Animation URL' field and provide the animation url https://lottiefiles.com/. If url is empty then sdk will play default animation for tracking
Description
User can change the default scan instruction for auto marker detection, i.e. when_auto-marker-detection_ sets to 'true'.
Default text for scan instruction is_"Look for a marker to scan..."_
Description
User can change the default scan instruction when marker is detecting i.e. recognises a marker image.
Default text for scan instruction while detection is_"Detecting..."_
Description
User can change the default scan instruction when phone is idle
Default text for scan instruction is_"Shake your phone to start detection"_
Description
Changes the css style of scan instruction text element.
Description
User can change the display style of auto scan html element
Description
User can change css style of scan instruction html element.
Description
Changes the css display property of the scan button displayed during marker tracking i.e. when webar-mode="marker-tracking". To make it invisible set it to"none"else"block".
Description
Changes the height and width of the scan button displayed during marker tracking i.e. when webar-mode="marker-tracking".
Description
Sets the height and width of the image displayed in the scan button displayed during marker tracking i.e. when webar-mode="marker-tracking".
Description
Sets the image of the scan button displayed during marker tracking i.e. when webar-mode="marker-tracking".
Description
Sets the SVG transform property (e.g. translate(), rotate() etc.) of the image displayed in the scan button displayed during marker tracking i.e. when webar-mode="marker-tracking".
Description
Sets the x and y coordinates of the image displayed in the scan button during marker tracking i.e. when webar-mode="marker-tracking". The x and y position of the image is the top left position, relative to the viewport of the origin of the element i.e the scan button. Use scan-btn-img-transform attribute's translate() method to position the image to the centre.
Description
Changes the text below the scan button displayed during marker tracking i.e. when webar-mode="marker-tracking".
Description
Changes the css style of the text below the scan button displayed during marker tracking i.e. when webar-mode="marker-tracking".
Description
Sets the color of the progress foreground circular bar displayed around the scan button during marker tracking i.e. when webar-mode="marker-tracking".
Description
Sets the x and y coordinates of the centre of the progress foreground circular bar displayed around the scan button during marker tracking i.e. when webar-mode="marker-tracking".
Description
Sets the radius of the progress foreground circular bar displayed around the scan button during marker tracking i.e. when webar-mode="marker-tracking".
Description
Sets the SVG transform property (e.g. translate(), rotate() etc.) of the progress foreground circular bar displayed around the scan button during marker tracking i.e. when webar-mode="marker-tracking".
Description
Sets the x and y coordinates of the centre point of the progress background circle displayed around the scan button during marker tracking i.e. when webar-mode="marker-tracking".
Description
Sets the radius of the progress background circle displayed around the scan button during marker tracking i.e. when webar-mode="marker-tracking".
Description
Sets the SVG style of the progress background circle displayed around the scan button during marker tracking i.e. when webar-mode="marker-tracking".
Description
To enable/disable the camera permission alert dialog(generated by the sdk) on iPhone devices before showing the iOS system request to access the camera. When set to "false", A Camera and Motion permission alert is shown only during the first time the application is loaded on the browser. When set to "true", A Camera and Motion permission alert is shown during the first time the application is loaded on the browser. After that for every load, only the Camera alert is shown. The advantage of showing the camera permission alert during every load is to start the auto playback of the video(if any) in the AR experience. In iOS Safari browser, a video cannot be played automatically when the scene is loaded. Instead it has to be played only after a user interaction. With this camera alert interaction, the app can start and pause the AR scene videos (using the callback from SetCameraAlertCallback() API) and also starts the iOS system alert to access the camera. Once the tracking has started, the paused videos can be played programatically to look like it is auto-played. The default value of this attribute is "true".
Description
User can change the default scan instruction when desktop camera view is idle i.e no valid marker is detected. If no valid marker is detected within 5 minutes, user has to reload the page to start detection to work again.
Note: Default text for idle instruction is "Reload to detect a marker"