DAN GALPIN: In the early days of Android,
we made the first SDK available as a preview to developers.
The vibrant developer ecosystem and open platform
have been important keys to our success, which
is why I'm excited that we're once again giving developers
a very early preview of some of what's in store in the upcoming
version of Android--
Android P. Your early feedback is crucial to our efforts
to push the boundaries of mobile development.
In Android P, JobScheduler has been
improved to let it better handle network-related jobs.
Jobs can now declare their estimated data size,
signal prefetching and specify detailed network requirements.
For example, when a network is reported by the carrier
as being congested, JobScheduler might defer large network
requests while it can take advantage of surplus meter
capacity to run a prefetch job that returns content that
will substantially improve the app's user
experience, such as prefetching top headlines.
Android P brings performance and efficiency improvements
to ART, Android's runtime.
We've expanded ART's use of execution profiles
to optimize apps and reduce the in-memory footprint
of compiled app code.
ART now uses profile information for on-device rewriting
of DEX files with reductions of up to 11%
across a range of popular apps.
These correlate closely with reductions in system DEX memory
usage and faster startup times.
Kotlin is seeing massive growth in the developer community.
We have heard so much Kotlin love from developers,
and we are deepening our Kotlin investments.
In P, you'll see the first results of our platform work
with new optimizations in ART.
Apps written with Kotlin will run faster on P
than on previous versions of Android.
We're continuing to work with JetBrains to optimize
the Kotlin compiler.
And we are also improving our brand new D8 dexer
to make sure generated code from Kotlin
can run as fast as possible.
Also, make sure to check out our ongoing preview of Android
KTX, which is a set of extensions designed
to make Android Kotlin development even more
concise and pleasant.
Android introduces an easier way to decode images
to either Bitmaps or Drawables with ImageDecoder, which
replaces BitmapFactory.
ImageDecoder lets you create a Bitmap or Drawable
from a ByteBuffer, file, or URI.
It offers several advantages over BitmapFactory including
support for exact scaling, single-step decoding
to hardware memory, support for post-processing and decode,
and decoding of animated images.
ImageDecoder allows you to supply a callback that
is called after the header is decoded where you
can alter the output rather than having
to decode the header twice.
Decode Drawable allows you to create Drawables directly.
If the encoded image is an animated GIF or WebP,
the Drawable will be an instance of the new animated image
Drawable.
To help deliver the highest quality viewing experience,
Android P adds built-in support for HDR VP9 Profile
2 enabling the delivery of HDR-enabled movies.
We also added support for substantially improved image
compression with HEVC compressed HEIF images,
which means smaller downloads and less on-device storage.
And we're in the process of enhancing and refactoring
the media APIs, so stay tuned.
You can access streams simultaneously
from devices that have logical cameras
consisting of multiple physical devices,
such as dual front or dual rear cameras,
enabling new app possibilities.
Other improvements in camera include new session parameters
to reduce delays during initial capture
and surface sharing, reducing the need for camera clients
to stop and start camera streaming.
We've also added APIs for display-based flash support
and access to OIS timestamps to allow
apps to perform image stabilization
or use this data for special effects.
Android P adds an API for the IEEE 802.11 MC Wi-Fi protocol,
also known as Wi-Fi Round Trip Time RTT,
to let you take advantage of indoor positioning
in your apps.
Android P devices with hardware support
can use RTT to measure the distance
to a nearby Wi-Fi access point that supports the protocol.
The device doesn't need to connect to the AP to use RTT.
And to maintain privacy, only the phone
is able to determine the distance.
By measuring distances to three or more access points,
apps can calculate their position
with an accuracy of 1 to 2 meters.
Android P adds an implementation of the GlobalPlatform Open
Mobile API to Android.
On supported devices, apps can use
OMAPI to access NFC secure elements on Android devices
to enable smart card payments and other secure services.
The Neural Networks API was introduced in Android 8.1
to provide support for accelerated on-device machine
learning.
In Android P, we're expanding and improving the API,
adding support for nine new Ops.
On Pixel 2, the DP1 build includes an accelerated
driver for quantized models.
Android P is part of our longer-term initiative
to modernize the foundations of the platform and the apps
that run on it.
We announced recently that Google Play
will require all app updates to at least target
Android Oreo by November 2018 and require
apps with an NDK library to provide 64-bit support in 2019.
In line with these changes, Android P
will warn users with a dialog when
they install an app that targets an Android platform earlier
than Android 4.2, and future versions
will continue to increment that limit.
Every Android developer should start
planning to migrate to target at least API 26 now.
And we've built a checklist of resources
to help and support this effort.
We're always looking for ways to improve the user and developer
experience.
In this spirit, we're working to ensure
that apps don't use non-SDK interfaces,
since doing so risks crashes for users and emergency rollouts
for developers.
In Android N, we restricted the set of symbols
that NDK code could use.
And with Android P, we're further increasing stability
by expanding these restrictions to cover the SDK interfaces as
well.
In the preview, you'll see a warning
when you use a non-SDK interface that we plan to restrict.
If you feel that you'll need the SDK API expanded
to stop using non-SDK [? 1s, ?] please let
us know as soon as you can via our bug tracker.
In Android P, we're providing a standard system
dialog to prompt the user to touch the fingerprint
sensor managing text and placement as appropriate
for the device.
Apps can trigger the system FingerprintDialog using
a new FingerprintDialog API.
We recommend switching to the new system dialog as soon
as possible, as the previous API may not
be compatible with new devices.
As part of a larger effort to move all network traffic away
from clear text, unencrypted HTTP to TLS,
we're also changing the defaults for network security
configuration to block all clear text traffic.
On Android P and higher, apps with a network security
configuration must make connections over TLS
unless they explicitly opt into clear text
for specific domains.
To better ensure user privacy, Android P
restricts all access to microphones, cameras,
and sensors from idle apps.
When an app is idle, the mic will report empty audio,
and the sensors will stop reporting events,
while cameras used by the app will
be disconnected and generate errors
if the app tries to use them.
Android P gives the user control over access to the Build.SERIAL
identifier by putting it under the read phone state
permission.
Direct access to this identifier has been
deprecated since Android 8.0.
Android P adds platform support for edge-to-edge displays
with cutouts.
The status bar will adapt its height automatically.
Apps with critical immersive content
can use a new platform API and window insets
to get the cutout bounds and a new API
in the Window Manager LayoutParams
to request layout in the cutout area.
The updated MessagingStyle notification
makes it easier to display notifications involving
people or groups of people.
It provides a standardized way to handle images and handle
suggested replies.
Give your users a seamless transition to Android P.
Just download a device or emulator system image,
install your app, and test.
The Android P Developer Preview includes an updated SDK
with system images for testing on the official Android
Emulator and on Pixel, Pixel XL, Pixel 2, and Pixel
2 XL devices.
Speaking of the Emulator, it's a great place
to test or develop on Android P. It's
incredibly fast and convenient to use,
and you can even model long screens and screens
with a display cutout for cameras and sensors.
After you've tested, handle any P behavior changes,
make any necessary updates, and publish to Google Play
without changing the platform target.
Then, change your app's targeting to P,
and run it with the full Android P experience.
Explore the many new features and APIs
you can take advantage of in your app.
Take a look at the API Diff Report
along with the Android P API reference.
You can start building with P by downloading
the Developer Preview SDK in tools in the Android Studio.
We're also releasing an alpha version of the 28.0.0 Support
Library for you to try.
Check out the release notes for complete details.
We plan to update the preview system images
and SDK regularly.
This initial release is for developers
only and not intended for daily or consumer use.
So we're making it available by manual download in Flash only.
As we get closer to a final product,
we invite consumers to try it out as well,
and we'll open up enrollments through Android Beta
at that time.
Stay tuned for details.
But for now, please note that Android Beta is not currently
available for Android P.
As always, your feedback is critical.
So please let us know what you think.
The sooner we hear from you, the more of your feedback
we can integrate.
Look in the video description for details
on how to report issues.
And stay tuned.
This is just our first preview, after all.
The Android P story is just beginning.
[MUSIC PLAYING]