Advertisement

header ads

Create and Deploy an Augmented Reality using Vuforia SDK and Unity3D




What is Augmented Reality (AR)?

Augmented Reality (AR) is directly or indirectly showing computer generated sensory inputs such as sounds, video, graphics or GPS data in real environment or physical world.

Now AR field is becoming more popular and advance day by day. So it is a good idea to dive into this field so eventually you'll be able to become great using this future technology.

In this blog post I'm going to give you step by step instructions on how to create an Augmented Reality app Using a SDK called Vuforia and Unity3D application.

So for this tutorial you need the bellow things downloaded and installed in your computer,

Unity3D - Download and install Unity3D personal edition from here
Vuforia SDK - Download vuforia sdk for unity from here.


After downloading and Installing above software and the sdk you are ready to make the augmented reality app.

Follow the bellow step by step instructions

1. go to developer.vuforia.com and login to your vuforia account. If you don't already have one create an account.


2. now go to Develop > License Manager and then click on Add License Key


3. then in Project Type Choose Development - my app is in development and then in Project Details give and App Name and choose Device and then License Key. after that click next.




4. then confirm the license key and click on confirm

5. click on the name of your license key


6.  then copy the license key

7. go to target manager and click on add database.

8.  give a name and type and then click on create.


9.  click on the name of the database and click on add target

 10 . then choose single image from the type and then click on browse and give the location of your image that you are going to take as the base marker image I'm using the bellow image. so if you also want to use that image right click on the image and save it in your computer and then give the location of that image.

after that give the width of the image that you are tracking. the length of the image will generate automatically. then give a name to that image and then click on add button.


11. then the target image will be uploaded to the data base and show up the image and the rating of the image. higher the rating better it'll track the image. so be careful to use a good image. then click on download database (all) button and choose unity editor and then click download and save the file in your computer.


12. Now open up the unity editor and then log into your unity account. if you don't already have one then go and create one. if you are opening the unity editor for the first time then you will be wanted to go through some simple process to open up the editor.


13 then click on new and then give a project name and the location and organization and then click on create project button.



14.after opening up the project window you will find a window like below there you can find the hierarchy window and project window and the inspector window as bellow


15. first of all go and save the project. then go to the project window and right click on the assets window. then choose import package and the custom package. then choose the unity sdk that you downloaded before and click open. then it'll ask you to import the files click import

again do the same right click on assets then import package > custom package and then choose the database that you created and downloaded before and import it.

after that delete the main Camera which is there when you created the project to do that right click one Main Camera and hit delete.

Then got to Assets > Vuforia > Prefab folder. There you'll be able to find ARCamera. drag and drop it into the Scene window. And go to the Inspector window and edit the x,y,z Position coordinates to 0. 




Again drag and drop the ImageTarget from the Assets window to the Scene under the ARCamera. Then Search and import Red Samurai from the Assets Store. Then Go to Assets > Prefab then drag and drop the samurai 3d model to the Scene make it be under ImageTarget.





Then click on the ARCamera from the Hierarchy window and then add the License key and edit the Inspector settings as below image 


 Then click on the ImageTarget and edit the Inspector settings as below image 


Then click on the samurai from the Hierarchy window and edit the Inspector settings as below. 


Then Click on the play button and the web cam will be open up. the hold the image target in front of the camera and you can see the output product as below. 


So now you have your very own Augmented reality app. So this is all for this tutorial more will be added to the site later on so stay touch with the us. 

If you have any questions feel free to comment them below and share this article with others and also don't forget to like out facebook page.

Post a Comment

0 Comments