Model Target Test App User Guide

Use the Model Targets Test App to test and evaluate your Model Target's tracking and performance. Download it as an Android APK package or Unity project from the Tools on the Developer Portal.

The Model Targets Test App lets you:

  • Evaluate the capabilities of the Model Target detection and tracking feature of Vuforia Engine.
  • Evaluate the functionality of Model Targets with multiple objects and/or multiple Guide Views.
  • Test if your custom Model Targets can be tracked and detected with good performance.
  • Test your custom Model Targets with different tracking configuration and settings.

The test app includes a Model Target database containing one Advanced Model Target (NASA Viking Lander), with a 360˚ Advanced Guide View. But you can easily load your own databases of any type stored in the app’s folder.

Test your Model Targets with the physical objects. The sample database uses a 3D printed model of the NASA Viking Lander. See Printing and Assembling the Viking Lander for more information. 

NOTE: it is important that the scale of the 3D-printed object matches the scale of the Model Target. Please do not change the size of the 3D object when 3D printing!

Installing the App

You can install the app vuforia-unity-android-modeltargetstest-X-Y-Z.apk on a device by connecting the device to a PC with a USB cable, and then using the Android Debug Bridge (ADB). Instructions to use adb can be found here: Getting Started with Vuforia Engine for Android Development.

As an alternative approach, you can copy the APK to your device's Download folder and install it from a File Manager application directly on the device.

Testing the Example CAD Object

The Advanced Model Target included in the app does not have a Guide View. It is recognizable from all sides and will initiate tracking as soon as the object is detected.

A Model Target can be set with Guide Views that will appear on the screen as an outline of the object when the Model Target is loaded. Match the outline with the object to initiate tracking.

When Vuforia Engine detects the object, tracking will be visualized by rendering an outline of its features and parts.

Test App Settings

The Model Target Test App lets you thoroughly test your Model Targets with different settings and the tracking visualizations can be adjusted to better contrast the object and scene.

Options

The Options menu lets you test different settings with your Model Target.

  • Toggle the Device Observer to enable or disable the Device Tracking and extended tracking.
  • Toggle the camera’s autofocus. A double tap on the screen is then necessary to focus the camera.
  • Change the Motion Hint of your Model Target to optimize tracking according to your use case. Note that the Tracking Mode, in this case set to DEFAULT, cannot be changed during tracking.
  • Information about the target, its states, motion hint, and tracking mode is displayed in an info-panel. You can toggle this panel on and off.
  • The Static Device Tracker can be enabled if you are testing for a use case where the camera does not move.

Other options include:

  • A button (centered right) to cycle through the Guide Views if the loaded Model Target have them.
  • Reset tracking

On the left side, you may change the Color Schemes of the outline rendering. Choose a color pair that is easier to see under different lighting settings and contrasting better against the material.

Adjust the Outline Width to thicken the outline. Please note that this may lead to performance issue if the 3D model is complex.

Load your Own Model Target onto the Device

If you have a custom Model Target database (generated using the Model Target Generator) that you would like to test, you can transfer it onto your device's storage and activate it at runtime with the test app. A standard Model Target database will show a Guide View. An Advanced Model Target database will not show a Guide View but instead, the app will start searching for recognizable objects.

A Model Target database consists of two files:

  • <YourDatabaseName>.xml
  • <YourDatabaseName>.dat

The databases are available in the database menu and populated by adding Model Target dataset file pairs to the test app’s internal storage.

A Model Target dataset file pair can be copied from your local device storage or other storage apps into the app’s internal directory from within the app.

  1. Open the Database menu and Import.
  2. Select either a .zip containing the dataset files or select the .xml and .dat together.

You can also choose to transfer your Model Target databases manually into a subfolder of the ModelTargetData folder. You may have to first create both folders in the app’s directory, which can look like this.

/sdcard/Android/data/com.vuforia.engine.ModelTargetsTest/files/ModelTargetData/MyDatabase/

Use File Explorer (Windows) or Android File Explorer (Mac) to copy your database folders with the dataset files onto your device and the app’s directory.

Your folder hierarchy should then look like this:

  • /sdcard/Android/data/com.vuforia.engine.ModelTargetsTest/files/
    • ModelTargetData/
      • MyDatabase/
        • YourDatabaseName.dat
        • YourDatabaseName.xml
      • AnotherDatabase/
        • AnotherDatabaseName.dat
        • AnotherDatabaseName.xml

Transfer a database

If your Android device is connected via USB, you can copy the files using adb push. Assuming YourDatabaseName.xml and YourDatabaseName.dat are in a subfolder of the current directory called MyDatabase, you would use the following command:

adb push MyDatabase.* /sdcard/Android/data/com.vuforia.engine.ModelTargetsTest/files/ModelTargetData/