A-frame
Refer custom HTML attributes that can be utilized
Last updated
Refer custom HTML attributes that can be utilized
Last updated
These are Blippar WebAR SDK’s custom HTML attributes that are used with A-Frame’s Entity and Scene. They are available to use after the WebAR SDK script has been loaded.
Usage
or
Description
When A-Frame’s <a-entity camera> or <a-camera> is added with the webar-camera attribute, it becomes the WebAR camera for surface tracking.
Example
Usage
Used by the entities that are loading an asset.
Description
Monitors the loaded state of an asset in an A-Frame entity. The initial loading progress bar will be displayed until all of these assets are loaded and after the camera video appears on screen.
For faster loading times and to ensure entities have been fully loaded before showing the scene the elType property should be defined, default value is 'none'. Values are shown in the table below.
Properties
elType:
<one of the elType enum values>
Enum Values
glb
model-loaded
obj
model-loaded
asset
loaded
texture
materialtextureloaded
video
materialvideoloadeddata
none
Waits for 500 ms
Example
Usage
To be used with a parent entity of the 3D model entities that have to be displayed on a marker image.
Description
When an A-Frame’s topmost parent a-entity in a scene is added with the webar-marker attribute, it becomes the placeholder for the 3D models that have to be displayed over the image of the corresponding marker id specified as the value of the id: property.
Up to 10 markers can be uploaded per WebAR SDK Project (or license) in the Blippar Marker Manager. Each marker image can be linked to an AFrame's <a-entity webar-marker="id: <marker_id>"> by replacing <marker_id> with a valid marker id obtained from the Blippar Marker manager after uploading an image.
The number of <a-entity webar-marker="id: <marker_id>"> elements should match with the number of marker images uploaded in the Blippar Marker Manager. Each <a-entity webar-marker="id: <marker_id>"> should have a unique <marker_id> obtained for each uploaded image in the Blippar Marker Manager.
id:
Marker id value obtained from the Blippar Manager after uploading an image.
Example
Usage
Description
When A-Frame’s a-scene is added with the webar-scene attribute, it becomes the WebAR scene for surface tracking.
Properties
Key:
<License key purchased from Blippar>
Example
Usage
To be used once with a parent entity of all of the 3D model entities that have to be displayed on the surface tracking scene.
Description
When an A-Frame’s topmost parent a-entity in a scene is added with the webar-stage attribute, it becomes a stage for the 3D models that have to be displayed on the surface tracking WebAR scene. In other words, all the 3D model entities have to be added as children to this <a-entity webar-stage> element.
Note
Only one <a-entity webar-stage> is supported.
Example
The license key can only be used on a HTTPS server that has the same public domain name for which the license was purchased or for a local HTTPS server that has the same private IP address as the domain name. Please see the for more details.