Vuforia helps you make engaging AR apps. Now, I will introduce several nice functions of it. We will explore Cube and Cylinder-Targets, Vumarks, Smart-Terrain and more. Of course, we will not explain these subjects deeply, but it is enough for you to understand and you can start with them.
1. Set up “Vuforia” on Unity
You can skip this section if you are already with preparing a Unity project. Because it reviews for people that used Vuforia in the past.
Firstly, you have to set up the framework by downloading and importing the “Vuforial” package for Unity. After that, in “Vuforia’s License Manager”, you have to create a License Key. You take the key and insert it on “ARCamera” prefab. And now, you can play around with “Vuforia”.
You can consult the example below : Create a Pokémon GO Style Augmented Reality Game With Vuforia.
2. Design an Image-Target
Almost of Augmented-Reality experiences on “Vuforia” base on types of Target which is admit by “Vuforia’s algorithm” to begin the augmentation process. Designing target by yourself, then submit it to “Target-Manager” of “Vuforia”in order to the system identify it. One thing you should remember, this design must apply some tutorials unless you want it cannot recognized at all.
Many types of “Vuforial” targets including a lot of “Image-Targets” are arranged in concrete position and order with a “Multi-Target”. So, you have to have knowledge about designing an “Image-Targets”.
When designing an “Image-Target”, it applies three main rules below:
Detail must be rich.
It must have a nice distinction with bright and dark regions.
There is no repetitious and can be exist.
An arrangement of the image which using its function is created by “Vuforia”, then the algorithm can find sample and track the targets. An image’ function looks like a box corner or the tip of the star, it means that it is a sharpened angle roughly; and the amount of function in image connect directly to its “trackability”
And important more, the “Image-Targets” need level of randomness and chaos to be identified. So, if functions in an image are arranged in a pattern, they will not help.
Therefore, you can create a perfect “Image-Target” if you apply those rules above.
3. Using Multi-Target
The “Multi-Target” is include a series of “Image-Targets” in determinedgeometric disposition. “Vuforia’s algorithm” can track the targets at the same time and make a volumetric reference in this disposition. In marketing strategy, “Multi-Target” is extremely useful to improve interaction of customer with product package.
a. Designing a Multi-Target
The rule of designing of “Multi-Target” is the same as that of “Image-Target”, but adding 2 rules, there are: the box’s depth and its Geometric consistency.
A recommendation shows that the depth of the box should be a half of its width. If it is smaller than that, it will work.
Algorithm of “Vuforia” expects that all parts of the “Multi-Target” have consistency. In other word, all of the sides of the box are expected to be in place. If this cannot happen, it can keep the removable part blank in target creation in “Target-Manager”.
b. Creating a Multi-Target
Firstly, selecting the database, then click Add-Target. Select the “Cuboid” option with Width-Height-Length-Name.
I repeat that a “Multi-Target” is include a series of “Image-Target” in a defined position. So, when the “Multi-Target” was created, select and set “Image-Targets” in it. Each the part of cuboid must have an image, in which, each image apply to the percentage of the cuboid, specified when the target was made.
You would be ready when the Cuboid is installed. Download the database, then, add it in Unity. Drag a “Multi-Target” prefab to the stage, and select Cuboid-Target and database which downloaded in order to use it. Take a look at the documentation.
“Vuforia” documentation shows that Cylinder-Targets allows you to find or track images that rolled into the cylindrical and conical shapes. You can create engagement with product package by using this interaction.
a. Design a Cylinder-Target
As Multi-Target, a Cylinder-Target depend on Image-Target, too. That means it should apply 3 main rules in designing. Both the top and the bottom of the cylinder must be a square, they will be marked by the Target manager system. You should attend to target’s consistency.
b. Create a Cylinder-Target
In first step, select the database in “Vuforial’s Target-Manager”, add a new Target, select the Cylinder choice, set its Dimensions and Name.
In second step, select the Cylinder-Target which you created and upload images to it. You can upload one image for top and one image for bottom. You should know that the image must respect the ratio of cylinder. But don’t worry because “Vuforia” system will give you the exact ratio, so, you can regulate your image percentages accordingly. Your upload will succeed just when the ratio is correct.
You only have to download and import the database to Unity, then, drag a “Vuforia Cylinder-Target” prefab to scene, you can use it.
5. Smart Terrain
The Smart-Terrain is a sole function which allows you to rebuild and improveyour physical environment. The function reconstruct, tracks physical objects,defines and surface. Those objects which are specified can be used as terrain in Unity, and it open up exciting possibilities for games and experiences.
The experience is beginning when the device tracks an Image-Target, a Cylinder-Target or other kind of target. The system will specify objects that distributed around the target, then, set the game stage base on objects tracked. The terrain is projected nearly over the scanned objects, the experience starts.
When objects apply to “Vuforia” standards, Smart Terrain can define them, like boxes or cylinders. It will put those simple objects directly on the game stage and using them like part of the scene.
The Smart-Terrain system calls those types of objects Props. The size can be small like a soup-can or big like a large cereal-box. “Transparent objects” like glass which is not supported.
Smart-Terrain works in 3 stages:
Staging: the user distributes the target and the objects (props).
Scanning: Smart-Terrain tracker captures and rebuilds the stage and props which used in the stalling.
Tracking: the Unity scene that you’ve developed augment the terrain.
In order to create a Smart-Terrain experience, the “Vuforia” team shows us an excellent each step guide. You only allows the guide if you want to try. However, you should remember that Smart-Terrain is limit certainty, especially relative to hardware and system requirement. You can find out more about the system in its documentation.
A “VuMark” is a type of target can be made to order fully and it is defined by “Vuforia” tracking system. It can recount specific design option or a brand personality. “VuMark”can begin “encode data” or“AR experiences”.
The creation process with “VuMark” is not simple. The “Vuforia” team gives us an excellent guide and some helpful tools. But in this post, I will only show you general idea of this process.
a. “VuMark” Design
It is important to understand several construct and design rules for “VuMark”. A “VuMark”consist of 5 parts:
Contour: the contour is specified by the contrast between border and the clear space. It is a part which “Vuforia’s algorithm” finds firstly.
Border: the organizing shape of “VuMark”. It is made by straight lines with at least 4 angles which located at the outermost edge of the design.
Clear space: the empty area that appears adjacent to the border. It is ensure there is enough contrast for the algorithm to find the contour
Code / Elements: shows the target’ ID. Including elements have high contrast, represent 2 stage: dark and light. When create the “VuMark” Template in Illustrators using the tools, the amount of elements is organizing.
Background / Design Area: this area is an empty canvas that will be ignored. You can be free to design in this space.
To find out more about the design requirements, read the VuMarkDesign Guide.
b. Create a “VuMark”
An advise for you, you should design idea and consider all tutorials which Vuforia gives before beginning a VuMark. When completing the design, you should divide it into parts, applying VuMark’s construction.
Firstly, create a new VuMark sample by using the “VuMark-Setup.jsx” illustrated script. Then, you can choose the mark’name, ID type, length in “VuMark-Temple-Setup” The amount of characters which encoded will define how many it contains.
You have to copy design idea and break it by using classes which created by the script when the template is created. Each class shows a part of construction and has its rules. You will the “VuMark-verify.jsx” script to check whether you design is right. This script will have some advises for you about the way to fix you design.
You will export the target after ensuring your design conforms to “VuMark’s standard” and it is broken down. To do this, you have to run the “VuMark-Export.jax” script. It will make a new file in Illustrator, move this content from your “VuMark” sample. It will remind you to save your sample under an SVG file. Now, you can upload the target file to a new database in “Vuforia’s Target Manager”. After that, as other targets, you download database and use it.
7. Explore cool features
In general, Vuforia system has extremely interesting features. Some other features in Vuforia:
User defined targets: like Image-Targets, but addition, user can organize the targets by using the device’s camera.
Cloud recognition: (for firm-accounts) this is kind of target database which lives in cloud. You can upload and synchronize new Image-Targets with the app on fly.
Object recognition: it is an experimental function. This function permits the specification of an object after a special tool scan it.