To integrate Augumenta AIP with Unity3D project that uses Vuforia plugin you need to be able to pass camera preview frames from Vuforia to Augumenta AIP. There is a prefab in Augumenta AIP Unity3D Vuforia package that makes this integration possible.
- Unity3D project, new or existing
- Vuforia SDK 6.2 or newer for Unity3D
- Vuforia Core Samples (From Assets Store)
- Augumenta AIP for Unity3D
NOTE: Augumenta AIP works with older Vuforia SDK versions, except in
Assets/Augumenta/Scripts/VuforiaCameraHandler.cs all mentions of
VuforiaARController needs to be changed to
Add Augumenta AIP to Vuforia project
First you need to create a Vuforia Unity3D project. Follow instructions from Vuforia on how to create a Unity3D project with Vuforia.
- Import Augumenta AIP Unity3D SDK package
- Copy Augumenta license file in to
- Import Augumenta AIP Unity3D Vuforia package
- Remove the
MainCameraand replace it with
- Start using Augumenta AIP
To test Augumenta AIP, add a
3D Object -> Cube to the scene and attach the
Assets/Augumenta/Scripts/FollowPoseHandler.cs to that object. As a default the
FollowPoseHandler will make the game object follow open hand pose (P001). Change scale of the object to
0.05, this ensures that the cube fits on the screen when it's following pose. The
FollowPoseHandler script will transform the game objects position relative to the main camera.
This script handles the integration between Augumenta and Vuforia by requesting camera frames from Vuforia and passing them to Augumenta AIP for detection.
Settings available in inspector:
- Webcam Fov Vertical/Horizontal, defines the field-of-view of the camera.
- Flipped frame, sometimes the frames provided from the Vuforia are flipped.
- Force Pixel Format, forces the Vuforia pixel format to use. If
UNKNOWN_FORMATis set then the first supported pixel format is used. On some platforms it might be necessary to force the pixel format.
Note on Examples project
If you use the AIP SDK example project as your starting project, you will need to do the steps described above (Remove the
MainCamera and replace it with
AIPVuforiaARCamera) for each of the
Scenes in the project, not only for the