[MUSIC PLAYING]
WAYNE LU: Hello, everyone.
My name is Wayne Lu and I'm a Technical Lead
Manager for Android Developer Relations.
Today I'm going to talk about Google
for Games Android Game Development Kit.
We are taking some questions in this Q&A video,
and I'll be answering all your top questions
regarding the Android Game Development Kit.
Without further ado, let's move on to the questions.
So for question number 1, is there
any specific advice or use cases for early, rising game
developers on how to use these tools?
So the answer is, for game developers
with a small team size, we are working
with popular game engines for you
to integrate your libraries.
You can find out more on our website,
or developers.android.com/games.
This will allow you to focus on building gameplay instead
of the entire technology stack.
On the other hand, if you are using Unreal Engine
and you're targeting multiple platforms such as PC
or for consoles, the Android Game Development Extension,
the AGDE, may be a great addition to your workflow.
On the other hand, alternatively,
if you have more resources and want to have full control
to optimize performance and customize your game,
you should look at our documentation
on developing and customizing your own game engine.
Lastly, for tools, you should use the Android Studio Profiler
to inspect your game, the Android GPU
Inspector, otherwise known as the AGI,
to profile graphics across different GPUS,
and the Android Performance Tuner to optimize frame rates
and loading times.
For question number 2, when signing up for the Android Game
Development Extension, AGDE, for Visual Studio,
is Android Studio a requirement?
The answer is no.
AGDE for Visual Studio works independently
without developers needing to download and install
Android Studio.
Note that, however, you will still
need to download the Android SDK and the NDK.
You can find out more information
about the prerequisites for the AGDE in the link below.
For question number 3, can you elaborate more
about the process and the different tools
on how AGDK can be incorporated with Unity?
So AGDK consists of multiple game libraries--
for example, the Game Activity, Game Controller, Game Text
Input, Oboe audio library, Frame Pacing, and Android Performance
Tuner.
These different game libraries allow you to build or customize
your game engine in C or C++.
When you talk about Unity, it does many of the work in C#.
However, for additional functionality,
you will need to download separate Unity plugins,
or otherwise known as packages, such as the Play Asset Delivery
and Android Performance Tuner.
Please refer to our Unity documentation for more details.
Question number 4, for those who are developing for Android
versions before Android 12, how can the updated game library
be best applied?
So to clarify on this, only the Game Mode API and Interventions
require Android 12.
When we talk about Android 12, this
is equivalent to the Android SDK version of level 31.
For many of the AGDK game libraries,
these do not require Android 12 or the SDK version of 31.
Many libraries require a minimum version, an SDK version, of 16
and NDK version of 17.
These libraries include Game Activity, Game Controller,
Game Text Input, and the Oboe audio framework.
There are two libraries which require a minimum SDK version
of 14 and NDK version of 14.
These are the Android Performance Tuner and the Frame
Pacing library.
This is rather complicated.
So for more information, you can find this in a table format
in our AGDK download page.
For question number 5, when developing Android games
in the C++ environment, how do we check memory access,
similar to how you do it in Windows development
environment?
So firstly, there's a couple of differences
between Windows development and Android-native game
development.
The Android OS uses [INAUDIBLE] memory to warn developers
about low memory usage.
Secondly, when you are budgeting for memory in Android
you need to take note of multiple factors,
such as the size of the physical RAM,
the maximum zRAM on the device, the memory usage of the Android
OS, and the memory usage of other installed apps.
Thirdly, you need to avoid memory trashing.
This is a scenario which occurs on Android devices
when there's very low, but insufficient, memory
to actually kill the game.
You will need to manage memory efficiently
to avoid reaching this stage of memory trashing.
Lastly, you can use our tools, such as the Android Profiler,
to inspect your memory usage.
For all this and more, please refer
to our documentation for more details,
and for links to the tools as well
to help you manage your memory efficiently.
Moving on to question number 6.
When a crash occurs in Android, is there
a way to collect and recreate the stack trace in Visual
Studio?
Yes, there's basically two different methods to follow,
depending on whether the crash occurs in Java or in C++ code.
When the crash occurs in Java, you
can see the stack trace in the Play Console Report,
or on the local device you can see in the [INAUDIBLE] tool.
This stack trace will allow you to look at the call stack
and look at the class, the method, the file, or even
the line number for you to manually trace
this within Visual Studio.
When the crash occurs in C++ code,
there's a few ways to debug this.
Well, for remote crashes, you can generate a native debug
symbols file and upload this to the Google Play Console.
And we will de-obfuscate the crash for you.
For local crashes, you can use our Android Game Development
Extension for Visual Studio to debug your code with LLDB.
Alternatively, you can use the NDK stack tool
to symbolize the stack trace.
On to the question number 7.
How do I use shaders on Android?
Is there any documentation that's
official related to this?
Yes.
Android games use OpenGL ES or Vulkan for rendering.
These are technologies offered by the Khronos Group.
You can find our documentation on OpenGL or Vulkan
for more information.
We also provide different tools for you
to profile and visualize your GPU rendering on Android.
Again, the link is below for you to refer
and to look at all the detailed information on this.
Question number 8, how do I use Vulkan graphics API on Android?
We have many different documentation for you
to set up your Vulkan graphics on Android.
We have samples to get you on basic rendering,
drawing a cube, compiling shaders, setting up
validation layers, white color support, and best practices
for Vulkan.
Please refer to the documentation
to learn more about these different samples
and use cases.
The last question, is there any official forum or community
where developers can meet and discuss,
share feedback on these libraries and tools?
Basically, there is no-- while there
is no official forum or community,
but developers can report bugs and submit your feedback
in the link below.
So we have reached the end of our session.
Thank you for joining us today for our top questions
on Android Game Development Kit.
My name is Wayne Lu, Technical Lead Manager
in Android Developer Relations.
I hope that this session has been useful in answering
your questions.
And I'm looking forward to see you
launch many fun and exciting games on Android and the Google
Play Store.
Thank you.