This repository should serve as a compilation of tests done with Vuforia SDK and Unity3D for Augmented Reality.
To get this working into your machine, you should have Unity installed, with Vuforia module. In order to help you:
- Install Unity hub;
- Install version 2018.4.12f1 with Vuforia module;
- Create your account at Vuforia;
- Log in and create a new license key;
- Open the folder VuforiaTest in Unity project and check if Vuforia augmented reality in PC XR Options (just for tests with a webcam) and Android/Ios XR Options in Edit > Project Settings > Player are selected;
- Create a new object "Ar Camera" and import Vuforia into your project;
- Click in the button in your AR Camera component "Open Vuforia Engine Configuration" and paste your license;
- Get back in Vuforia website and create a new image database and download it (if you choose device option, which I recomend for begginers);
- Import your image database into Unity;
- Create a new Vuforia Image, set your image in the component with your database and your image;
- Create a new model child of the image and then run.
Each scene has its own folder with everything needed to setup the scene. The main reason of this repository is to show what you can do with Augmented Reality
A basic explanation of what is going on each scene:
- InteractionScene
In this scene the two objects should interact with each other. The first one named player should recognize the second one named enemy (just to refer something like an action game) and the on player and enemy active, and the enemy in the search range of the player should go closer to the enemy, and in attack range, the player should hit him. After that, on disabling the enemy and enabling it again, it should 'reset' the action and the player should attack him again.
- JoystickScene
In this scene using a free joystick pack found in the asset store you should be able to move around the model named as player.
- PianoForPcScene
In this scene you should use your mouse to click the models in the scene (they're representing the piano tiles) and the 'response' should be some audio.
- PianoScene
In this scene you should have the same result of the PianoForPcScene, the difference is that in this scene you use touch for phone.
- ReadingEnableTargetScene
In this scene you just identify if a target is enable or not. If enable, just rotate it. The big deal for this scene, is that every frame in Unity is counted, meaning if you rotate an object it'll rotate even if the target has not been read. Basically, you are controlling the target "when to do something" or "do something by activating".
- VirtualButtonScene
In this scene you should do a virtual button get active when your hand or something goes over. The activation is right when the cube rotates.
- ChangingTargetScene
- AugmentedWindow