Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
52 commits
Select commit Hold shift + click to select a range
6e974a5
Update 1-setup.md
V3x-0E Nov 18, 2025
ec63881
Update 3-test-on-android.md
V3x-0E Nov 18, 2025
de114f0
Update 3-test-on-android.md
V3x-0E Nov 18, 2025
33179fd
Add files via upload
V3x-0E Nov 18, 2025
5a3d4ef
Update 3-test-on-android.md
V3x-0E Nov 18, 2025
a369ecf
Add files via upload
V3x-0E Nov 18, 2025
cf6256a
Update 3-test-on-android.md
V3x-0E Nov 18, 2025
eab0ac8
Update 3-test-on-android.md
V3x-0E Nov 18, 2025
ba8e954
Add files via upload
V3x-0E Nov 18, 2025
30872da
Update 3-test-on-android.md
V3x-0E Nov 18, 2025
ed5b6bf
Update 3-test-on-android.md
V3x-0E Nov 18, 2025
29a910d
Update 3-test-on-android.md
V3x-0E Nov 18, 2025
c26dcfe
Update 3-test-on-android.md
V3x-0E Nov 18, 2025
bb44e41
Update 1-setup.md
V3x-0E Nov 18, 2025
505d9a6
Update 1-setup.md
V3x-0E Nov 18, 2025
318894f
Update 1-setup.md
V3x-0E Nov 18, 2025
be0d876
Update 1-setup.md
V3x-0E Nov 18, 2025
aa94297
Update 5-profile-on-android.md
V3x-0E Nov 18, 2025
d1ae77d
Add files via upload
V3x-0E Nov 18, 2025
2f72c6c
Update 1-setup.md
V3x-0E Nov 18, 2025
6345d13
Update 1-setup.md
V3x-0E Nov 18, 2025
5a8058f
Update 1-setup.md
V3x-0E Nov 18, 2025
fa881eb
Update instructions for selecting project template
V3x-0E Dec 3, 2025
51ac2e7
Revise Unity project preparation steps for Android
V3x-0E Dec 5, 2025
92a9407
Add files via upload
V3x-0E Dec 5, 2025
680929d
6.3 lts uupdate
V3x-0E Dec 5, 2025
5c36daf
Update image reference for Android build support setup
V3x-0E Dec 8, 2025
2f31a83
final image for 6.3
V3x-0E Dec 8, 2025
00a3799
Add files via upload
V3x-0E Dec 8, 2025
c378293
Add files via upload
V3x-0E Dec 8, 2025
115d370
Update image path for Android settings in preferences
V3x-0E Dec 8, 2025
8c54e66
Add files via upload
V3x-0E Dec 8, 2025
decafb4
Update 2-preparation.md
V3x-0E Dec 8, 2025
cdfb698
Add files via upload
V3x-0E Dec 11, 2025
5916073
Update 2-preparation.md
V3x-0E Dec 11, 2025
3085722
Update 2-preparation.md
V3x-0E Dec 11, 2025
2ac4085
Update 2-preparation.md
V3x-0E Dec 11, 2025
3625cce
Add files via upload
V3x-0E Dec 11, 2025
8933827
Update 2-preparation.md
V3x-0E Dec 11, 2025
8559efe
Update 2-preparation.md
V3x-0E Dec 11, 2025
7fc8c05
Update 2-preparation.md
V3x-0E Dec 11, 2025
53a12e3
Update 2-preparation.md
V3x-0E Dec 11, 2025
c97b413
Add files via upload
V3x-0E Dec 11, 2025
7910ec9
Update 4-profiling.md
V3x-0E Dec 11, 2025
1312a35
Add files via upload
V3x-0E Dec 11, 2025
8f68c1f
Update 5-collect.md
V3x-0E Dec 11, 2025
f54a395
Update 6-unity-analyzer.md
V3x-0E Dec 11, 2025
1d95afd
Add files via upload
V3x-0E Dec 11, 2025
f3a5a90
Update _index.md
V3x-0E Dec 11, 2025
d8acc5b
Update _index.md
V3x-0E Dec 11, 2025
8937334
Update 5-collect.md
V3x-0E Dec 11, 2025
df72997
Update 6-unity-analyzer.md
V3x-0E Dec 11, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -26,19 +26,19 @@ First off, if you haven't already got Unity, we recommend following their steps

- Once logged in, if you don't already have any editor versions installed, Unity may recommend the latest Long-Term Support version.

![Unity LTS suggested installation#center](images/unity-auto-suggested-install.png "Figure 1. Long Term Support version suggested by Unity Hub")
![Unity LTS suggested installation#center](images/unity-auto-suggested-install.png "Figure 1. Long Term Support version suggested by Unity Hub")

- Go ahead and install the editor they suggest. If you don't see the above screen, you can always install a version of Unity manually. Click on the _Installs_ tab on the left to see the list of installed editors (which will likely be empty):

![Empty installs windows#center](images/unity-no-installs.png "Figure 2. Unity Hub installation list (empty)")
![Empty installs windows#center](images/unity-no-installs.png "Figure 2. Unity Hub installation list (empty)")

- Click on the recommended version. On the next screen we will add the Android module:

![Recommended editor version#center](images/unity-install-lts.png "Figure 3. Install recommended LTS version")
![Recommended editor version#center](images/install-6.3.png "Figure 3. Install recommended LTS version")

You should see a list of optional features to install with your editor. You can install Android build support now. In the list, click on "Android Build Support".

![Install Android Build Support module#center](images/unity-install-modules.png "Figure 4. Add Android Build Support module")
![Install Android Build Support module#center](images/install-android6.3.png "Figure 4. Add Android Build Support module")

You now have Unity and Android support. If you forgot to tick Android Build Support or you already had a version of Unity without it, follow the next section to download Android support separately.

Expand All @@ -48,7 +48,7 @@ Follow these steps if you already have a version of Unity and just need to add t

- Click on the _Installs_ tab on the left to see your list of editor installations. Then click on the _cog_ button and select _Add Modules_:

![Add Modules option#center](images/unity-add-modules-option.png "Figure 5. Select Add Modules on the editor for which you wish to add Android support")
![Add Modules option#center](images/6.3-add.png "Figure 5. Select Add Modules on the editor for which you wish to add Android support")

- You will be presented with the module list. Select _Android Build Support_ and any other modules you wish to install. Then click _Continue_.

Expand All @@ -58,25 +58,28 @@ Follow these steps if you already have a version of Unity and just need to add t

Android Build Support installs and manages the Android SDK and Android NDK for you. If you ever need to access the SDK or NDK directly, you can find them in the _External Tools_ tab of Unity Editor Preferences (menu option _Edit->Preferences_).

![Android settings in preferences#center](images/unity-prefs-external-tools.png "Figure 6. Android settings in Preferences")
![Android settings in preferences#center](images/external-tools6.3.png "Figure 6. Android settings in Preferences")

_Note that this will be within a project not the hub_

## 3. Extract and open the Unity project

We have provided a simple project to accompany this learning path. To open it in Unity, please follow these instructions:

- Unzip the [simple profiling example](supporting-files/simple-profiling-example.zip) to your computer
- Unzip the [simple profiling example](supporting-files/simple-profiling-example.zip) to your computer.
Important to make sure you save this to your local disk and NOT a cloud storage like OneDrive as that may result in errors further down the road

- In Unity Hub, from the _Projects_ tab, select _Add project from disk_ from the drop-down menu:

![Add project from disk#center](images/unity-add-project-from-disk.png "Figure 7. Add the sample project to Unity Hub")
![Add project from disk#center](images/Add-disk.png "Figure 7. Add the sample project to Unity Hub")

- Navigate to your unzipped project directory and click "Add project"

You will see your project listed in the _Projects_ tab in Unity Hub.

- You can now click on the project to open it. We used Unity 2022.3.18f1 to create the sample; if you use a different version, you will get a warning. The project is very simple and should be safe to convert. However, if in doubt, we recommend installing 2022.3.18f1 via the Unity Hub as we have already showed.

- The project will now open in Unity. Once loaded (the first time can take a while), click on the _Play_ button to run the sample. This will run the project inside the editor. You will see a spinning cube.
- The project will now open in Unity. Once loaded (the first time can take a while) find the scene folder and open the sample scene then click on the _Play_ button to run the sample. This will run the project inside the editor. You will see a spinning cube.

![Spinning cube sample#center](images/app-running-slowly.png "Figure 8. The spinning cube sample running in the editor")

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,21 +14,20 @@ We're going to build the sample for Android. To do so takes just a few steps and

1. First off, we need to switch the project to _Android_.

1. Select _File->Build Settings_ to show the Build Settings window:
1. Select _File->Build Profile_ to show the Build Profile window:

![Build Settings window#center](images/build-settings.png "Figure 1. Build Settings window")
![Build Profiles window#center](images/build-profiles-android.png "Figure 1. Build Profiles window")

1. Notice how the project is currently in "Windows, Mac, Linux" mode. We need to switch to Android.
1. In your project the platofrm labelled _Active_ will be your machine's operating systems (Windows, Mac or Linux). Since we are developing an android app we must rebuild for android.

1. Select _Android_ on the left and then click on _Switch Platform_. This will take a few moments as it re-builds the assets for the Android mode (this step can take longer the first time it is done for any project).
1. Select _Android_ on the left and then click on _Switch Platform_ at the bottom of the build profiles screen. This will take a few moments as it re-builds the assets for the Android mode (this step can take longer the first time it is done for any project).

![Switch platform to Android#center](images/build-settings-switch-platform.png "Figure 2. Switch platform to Android")
![List of scenes#center](images/scene-list.png "Figure 2. Scene list")

1. We must now tell Unity which scene to open when the app runs. This affects all platforms. Click on _Add Open Scenes_ to add the opened sample scene to the _Scenes in Build_ list. We will only need to do this once.

![Scenes in Build#center](images/build-settings-scenes-in-build.png "Figure 3. Scenes in Build list")

That's all we need to do to simply run the app. There are a couple more steps required to run the profiler but we'll cover those later.
1. In the screenshot, you can see that our SampleScene is already included in the build and preselected as the first scene to load.
This list shows all the scenes that will be packaged into the final build.
The top scene in the list is the one Unity will load first when the game starts.
If your project contains multiple scenes, this is where you would select which ones to include and set your startup scene.

## Prepare your Android device for development

Expand All @@ -48,9 +47,9 @@ Connect your Android device to your computer using a USB cable. Unity may take a

Android may ask for confirmation before enabling the connection.

In the _Build Settings_ window:
In the _Build Profile_ window:

1. Ensure your device appears in the _Run Device_ menu and select it.
1. Ensure your device appears in the _Run Device_ menu and select it, if the device doesn't appear make sure to press the "Refresh" button then your device should appear in the drop down menu

1. Select _Build and Run_. Choose a location to save your build.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ You should always check the performance of your app on a device comparable to th

1. To activate profiling, we will enable the _Development Build_ and _Autoconnect Profiler_ options.

![Enable profiling options](images/build-settings-enable-profiling.png "Figure 1. Enable options for profiling")
![Enable profiling options#center](images/build-profiles-android.png "Figure 1. Build Profiles window")

3. You should already have the Android platform selected, so connect your device and click on _Build and Run_.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ prerequisites:
- Recent Android device, such as a mobile phone or tablet
- Desktop computer capable of running Unity

author: visualSilicon
author: Joshua Marshall-Law

### Tags
skilllevels: Introductory
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,9 @@ Although the sample application is a project, you will still need to create a bl

1. Select _New Project_

1. Select the _3D (URP) Core_ template
1. Select the _3D (URP) Core_ template

![Display URP Template#center](images/URP.png "Figure 1. URP 3D template")

1. Enter project name (this will be used as the name of the project folder)

Expand Down Expand Up @@ -57,6 +59,8 @@ Once Unity has loaded, you will be presented with a template project. You can ig
e. Select _Open Unity Editor_

1. The Unity Editor will bring itself to the front and show the _Package Manager_

![Open Project manager#center](images/PM.png "Figure 2. Packet Manager with asset showing.")

1. You will see the sample project listed and highlighted. Select _Download_.

Expand All @@ -68,36 +72,39 @@ Once Unity has loaded, you will be presented with a template project. You can ig

1. The Import Unity Package window will appear. It allows individual files and folders to be imported or ignored. You will need all of the files in the project. Leave all items ticked and select _Next_.

![Import sample project#center](images/Import-window-step-1.PNG "Figure 1. Import the sample project using the Package Manager.")
![Import sample project#center](images/Import-window-step-1.PNG "Figure 3. Import the sample project using the Package Manager.")

1. A second window will open that lists the project settings that will be overwritten. We want the settings from the sample code so leave all items ticked. Select _Import_.

![Overwrite project settings#center](images/import-window-step-2.png "Figure 2. Overwrite project settings with the settings from the imported sample project.")
![Overwrite project settings#center](images/import-window-step-2.png "Figure 4. Overwrite project settings with the settings from the imported sample project.")

## Set up the project
Once the sample project has been imported, you will see some errors and warnings.

1. Open _File_ menu and select _Build Settings_
1. Open _File_ menu and select _Build Profiles_

1. Select _Android_ from the Platform list

1. Select _Switch Platform_
1. Select _Switch Platform_as you have done in the [previous learning path](https://learn.arm.com/learning-paths/mobile-graphics-and-gaming/get-started-with-unity-on-android/3-test-on-android/)

![Build-Profile-Menu#center](images/BP-menu.png "Figure 5. Build profile menu .")

Unity will take a moment to build the assets for the Android platform.

The errors will disappear but some warnings regarding unreachable code will appear. These will be explained later but can be safely ignored for now.

Your scene view will look something like this:

![Scene view#center](images/sample-project-default-scene-view.PNG "Figure 3. Default scene view of sample project.")
![Scene view#center](images/sample-project-default-scene-view.PNG "Figure 6. Default scene view of sample project.")

if it doesn't then follow the steps below
## Run the project inside the editor

It is worth checking that everything has imported and been built correctly.

1. Close the _Build Settings_ window
1. Close the _Build profiles_ window

1. In the Project tab (usually at the bottom in default configurations) you will see the list of asset files.
1. In the Project tab (usually at the bottom in default configurations) you will see the list of asset files. - add photo "bad load"

1. Open the _BurstNeonCollisions_ folder

Expand All @@ -109,29 +116,29 @@ It is worth checking that everything has imported and been built correctly.

The game will launch and you will see an empty environment begin to fill with more and more characters (capsules) over time. It will look something like this:

![Screenshot at runtime#center](images/game-view.PNG "Figure 4. Sample running in Game view.")
![Screenshot at runtime#center](images/game-view.PNG "Figure 7. Sample running in Game view.")

## Deploy to Android
You will now deploy the sample to your Android device. Your device must already be set up for development. For detailed instructions, read the learning path [Get started with Unity on Android](/learning-paths/mobile-graphics-and-gaming/get-started-with-unity-on-android).

1. Open _Build Settings_ from the File menu
1. Open _Build profile_ from the File menu

1. Tick the _Development Build_ option

![Import sample project#center](images/BP-Menu-Build.png "Figure 8. Development Build .")

1. Select _Add Open Scenes_ to add the demo scene to your _Scenes in Build_ list
1. Select _Add Open Scenes_ to add the demo scene to your _Scenes in Build_ list

1. Plug your Android device into your computer

1. Once recognized, your device will be listed in the drop-down menu next to _Run Device_

1. The screenshot below shows the settings with a _Samsung S8_ selected as the _Run Device_
1. The screenshot above shows the settings with a our demo device selected as the _Run Device_ you will see you own device in this box

1. Select _Build and Run_

![Build settings#center](images/android-build-settings.PNG "Figure 5. Android build settings showing selected Android device.")

1. Enter a name for the APK (the Android package) and select _Save_

Unity will take a moment to build the Android version and then automatically deploy it to your connected Android device. Depending on your setup, the build and deployment might take several minutes.

![Running on Android#center](images/android-plain-mode.webp "Figure 6. Sample application running on Android.")
![Running on Android#center](images/android-plain-mode.webp "Figure 9. Sample application running on Android.")
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,11 @@ On the other hand, if the performance issues happen later in the app's lifetime,

In our sample, the performance issues will be apparent soon after launch. To profile directly on an Android device:

1. Open the _Build Settings_
1. Open the _Build Profile_

1. Ensure _Autoconnect Profiler_ is ticked

![Build settings to autoconnect profiler#center](images/android-build-settings-autoconnect-profiler.PNG "Figure 1. Build settings with connected Android device and Autoconnect Profiler enabled.")
![Build settings to autoconnect profiler#center](images/AC.png "Figure 1. Build settings with connected Android device and Autoconnect Profiler enabled.")

1. Select _Build and Run_

Expand All @@ -51,6 +51,8 @@ In our sample, the performance issues will be apparent soon after launch. To pro

If you forget to tick the auto-connect option or you want to wait before you connect the Profiler, you can connect the Profiler while the app is running:

Whilst inside the unity editor

1. Select _Window_ menu, then _Analysis_, then _Profiler_

1. A round record button is present in the top-left
Expand All @@ -69,7 +71,7 @@ The Profiler window contains a lot of information spread over two main scrollabl
### CPU Usage graph and frame-rate labels
The CPU Usage graph captures profiling data every frame while it is active.

![Profiler CPU usage#center](images/profiler-samsung-s8-plain.PNG "Figure 2. The CPU Usage graph with data from the sample collision code app collected from a Samsung S8.")
![Profiler CPU usage#center](images/profiler-samsung-s8-plain.PNG "Figure 2. The CPU Usage graph with data from the sample collision code app collected.")

If you have a performance issue that worsens over time (as with the case of the collision sample), you will see the graph gradually (or quickly) fill over time. Watch the frame rate labels on the left of the graph. These labels mark the Y-axis at set intervals. They show you what CPU Usage would be required to achieve given frame rates. For example, if your CPU Usage remained under 16 milliseconds then as far as the CPU is concerned, a frame rate of 60 frames-per-second (FPS) would be achievable. If the CPU Usage is under 16ms but your frame rate is still lower than expected, that is an indication that the app has performance issues elsewhere, e.g., in the GPU.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ You will now collect some data from the unoptimized version of the code. To do t

1. Build and deploy to your Android device:

- Open _File/Build Settings_
- Open _File/Build profiles_

- Ensure the following options are ticked:

Expand All @@ -50,7 +50,7 @@ You will now collect some data from the unoptimized version of the code. To do t

- Select the disk icon in the top right of the Profiler window

- Enter filename
- Enter filename by clicking on the name in the file list on the left of the screen

```
plain.data
Expand All @@ -72,7 +72,7 @@ Let's repeat the above process but this time build and deploy the optimized vers

- Build and deploy to your Android device:

1. Open _File/Build Settings_
1. Open _File/Build Profiles_

1. Ensure the following options are ticked:

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@ layout: learningpathall
## Set up the Analyzer
Before you can use the Analyzer tool, you need to install the related package it comes in. Follow these steps with the Package Manager:

1. Select menu option _Window/Package Manager_
1. Select menu option _Window/Package Management/PacketManager_

1. Switch Packages option to _Packages: Unity Registry_

1. Select _Profile Analyzer_

![Package Manager showing Analyzer#center](images/package-manager-install-profile-analyzer.PNG "Figure 1. Profile Analyzer package in Package Manager.")
![Package Manager showing Analyzer#center](images/PA.png "Figure 1. Profile Analyzer package in Package Manager.")

1. Select _Install_

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ prerequisites:
- Basic knowledge of Unity and programming concepts
- Learning path [Get started with Unity on Android](/learning-paths/mobile-graphics-and-gaming/get-started-with-unity-on-android)

author: Arm
author: Joshua Marshall-Law

### Tags
skilllevels: Introductory
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.