# 2. Getting Started

Learn how to import SDK Package and do basic testing for your environment. Prerequisites

  • We assume that you have an understanding of what virtual reality is and the terms it uses. If not, check the Unity glossary.
  • Before using the QIYU VR SDK, we highly recommend that you to read Unity’s XR document, then correctly install the Unity Editor and ADB debugging tools.

# Step 1:

Open Unity Editor, and create a new 3D project

img

Fig 2.1 Create a project

# Step 2:

Modify the platform to the Android platform

Fig 2.2 Switch Platform

# Step 3:

  • Import QIYU XR Plugin

Menu -> Window -> PackageManager, Click Add -> Add package from disk,Select package.json, and import the Plugin.

Fig 2.3 Import SDK
  • Import QIYU Platform SDK

If the applications will live on the QIYU store, The QIYU Platform SDK must be imported after importing QIYU XR Plugin. Otherwise, the application will be refused when uploading to QIYU platform. Please refer to the QIYU Platform SDK (opens new window).

# Step 4:

Click "Yes" after import SDK, and Enable "Unity new input System". Then, Unity Editor will restart. Please just wait a moment.

Fig 2.4 Enable Unity new input System

# Step 5:

After Import, "QIYU XR Plugin" and "QIYU Platform SDK" will be displayed in packageManager. If necessary, click "Import Into Project" to import our Sample Project.

Fig 2.5 Import Samples

# Step 6:

Create a new scene, and create a XRRig gameobject. Please refer to the 4.2.1 UnityXR (opens new window).

Fig 2.6 Create XR Rig

# Step 7:

Enable "QIYU" in ProjectSettings—>XRPlug-in Management is required.

img

Fig 2.7 Enable QIYU

# Step 8:

Click "Menu/QIYU/Modify Player Settings", and it can be set to the recommended configuration automatically.

Fig 2.8 Menu Functions
Configuration Recommended Value
GraphicsAPIs OpenGLES3
ApiCompatibilityLevel .NET 4.x
minSdkVersion AndroidApiLevel26
Scripting Backend IL2CPP
Target Architectures ARM64(It is required when uploading the released version to QIYU store)
Default Orientation LandscapeLeft
vSyncCount Every V Blank
Blit Type Always
Table 2.8 Recommended Configuration

# Step 9:

If you need a custom AndroidManifest.xml file, click "QIYU->Tools->Create AndroidManifest" to create a default xml file and modifies it. When not needed, you can click the Delete button to Delete the file.

Fig 2.9 Create AndroidManifest

Note: If your application cannot appear in library of QIYU Device, please adding the following codes into AndroidManifest.

<category android:name="android.intent.category.LAUNCHER" /> 

# Step 10:

Build and Run on QIYU Device. If your application has been already released on QIYU APP store, the Bundle version code of the updated application must higher than the one's in the store, please refer to FAQs (opens new window).