Project Setup Tool
When developing Play For Dream apps with Unity, there are some project settings that need to be changed (refer to Configure Unity Settings). Play For Dream Unity project setup tool can automatically check the common issues occurred in the project and provide one-click fixes, related documentation and other functions to assist developers quickly configure the project and improve development and porting efficiency. It is recommended that developers ensure no critical issues are reported before making a build.
After importing Unity SDK (version 2.5.0 and above), you can open the panel via menu > YVR > Project Setup Tool. After the project setup is modified, the check items may not be updated in time, you can click the Refresh button to manually update the status of the check items under the current category. The Feedback button allows you to provide feedback on this feature.
Also, in the bottom right corner of the Unity editor, the panel can be opened and viewed the current check status.
Actions
A Configuration Task is regularly checked for its validation status. The user can, however, interact directly with a Task in the following ways:
- Fix: Provide one-click fixes for issues that can be fixed automatically.
- Go To Source: Open the IDE and jump to the appropriate code location.
- Related Documentation: For issues that cannot be fixed directly, provide links to the relevant documentation.
- Ignore: Ignore this issue and do not check it again.
Checklist
The checks are categorized into three main sections: ProjectSetup, PerformanceLint, and Porting.
ProjectSetup
Project Setup checks the following:
- 【Required】BuildTarget if is Android
- 【Required】PlayerSettings.Android.minSdkVersion = AndroidSdkVersions.AndroidApiLevel25
- 【Required】PlayerSettings.Android.targetSdkVersion = AndroidSdkVersions.AndroidApiLevelAuto
- 【Required】PlayerSettings.SetScriptingBackend(buildTargetGroup, ScriptingImplementation.IL2CPP)
- 【Required】PlayerSettings.Android.targetArchitectures = AndroidArchitecture.ARM64
- 【Required】Set Graphics APIs for this build target to OpenGLES3
- 【Required】YVRLoader has been assigned.
- 【Required】PlayerSettings.Android.androidTVCompatibility = false
PerformanceLint
PerformanceLint checks the following:
- 【Recommended】Physics.defaultContactOffset = 0.01f
- 【Recommended】Physics.sleepThreshold = 0.005f
- 【Recommended】Physics.defaultSolverIterations = 8
- 【Recommended】QualitySettings.pixelLightCount = 1
- 【Recommended】QualitySettings.masterTextureLimit = 0
- 【Recommended】QualitySettings.anisotropicFiltering = AnisotropicFiltering.Enable
- 【Recommended】EditorUserBuildSettings.androidBuildSubtarget = MobileTextureSubtarget.ETC2
- 【Recommended】PlayerSettings.colorSpace = ColorSpace.Linear
- 【Recommended】PlayerSettings.graphicsJobs = false
- 【Recommended】PlayerSettings.MTRendering = true and PlayerSettings.SetMobileMTRendering(buildTargetGroup, true)
- 【Recommended】PlayerSettings.use32BitDisplayBuffer = true
- 【Recommended】renderingTier.renderingPath = RenderingPath.Forward
- 【Recommended】For GPU performance, please don't use parallax-mapped materials.
- 【Recommended】For GPU performance, please don't use specular shader on materials.
- 【Recommended】Please use 2 or fewer passes in materials.
- 【Recommended】For GPU performance, please use 4 or fewer CompositeLayers.
- 【Recommended】For visual quality, please use trilinear filtering and mipmap on your VR splash screen.
- 【Recommended】Recommend enabling useRecommendedMSAALevel in YVRManager
- 【Recommended】Render scale above 1.5 is extremely expensive on the GPU, with little if any positive visual benefit.
- 【Recommended】For GPU performance, please don't use Unity's built-in Skybox.
- 【Recommended】For GPU performance, please generate mipmaps or disable trilinear filtering for textures.
- 【Recommended】Please use less than 1GB of vertex and texture memory.
- 【Recommended】Please use less than 100000 triangles or vertices.
- 【Recommended】Please use less than 100 draw calls.
- 【Recommended】All lights in scene have up to date lightmap data
- 【Recommended】For CPU performance, consider disabling shadows on realtime lights.
- 【Recommended】For CPU performance, please disable all but the top 16 AudioSources.
- 【Recommended】For fast loading, please don't use decompress on load for audio clips
- 【Recommended】For fast loading, please don't preload data for audio clips.
- 【Recommended】Please avoid instanced materials on renderers.
- 【Recommended】Please don't use image effects.
- 【Recommended】For GPU performance, please don't use projectors.
- 【Recommended】Please use 2 or fewer camera clears.
- 【Recommended】For GPU performance, please don't enable forceIntoRenderTexture on your camera
- 【Optional】LightmapSettings.lightmapsMode = LightmapsMode.NonDirectional
- 【Optional】Lightmapping.realtimeGI = false
- 【Optional】PlayerSettings.gpuSkinning = true
Porting
Porting checks for common issues in projects ported from Quest/Pico:
- 【Recommended】PXR_Manager not exist in scene
- 【Recommended】OVRManager not exist in scene
- 【Recommended】YVREntitledManager exist in scene