기능 및 API 개요

Android 15에는 개발자를 위한 훌륭한 새 기능과 API가 도입되었습니다. 다음 섹션에는 관련 API를 시작하는 데 도움이 되는 이러한 기능이 요약되어 있습니다.

새로운 API, 수정된 API, 삭제된 API에 관한 자세한 목록은 API 차이점 보고서를 참고하세요. 새로운 API에 관한 자세한 내용은 Android API 참조를 확인하세요. 새로운 API는 강조 표시되어 쉽게 확인할 수 있습니다. 또한 플랫폼 변경사항이 앱에 영향을 미칠 수 있는 분야에 관해 알아보려면 Android 15를 타겟팅할 때 앱에 영향을 미치는 Android 15 동작 변경사항targetSdkVersion와 관계없이 모든 앱에 영향을 미치는 동작 변경사항을 검토해야 합니다.

카메라 및 미디어

Android 15에는 카메라와 미디어 환경을 개선하고 제작자가 Android에서 비전을 실현할 수 있도록 지원하는 도구와 하드웨어에 액세스할 수 있는 다양한 기능이 포함되어 있습니다.

Android 미디어 및 카메라용 최신 기능과 개발자 솔루션에 관한 자세한 내용은 Google I/O의 최신 Android 미디어 및 카메라 환경 빌드 강연을 참고하세요.

어두운 조명 모드

Android 15 引入了低光增强,这是一种新的自动曝光模式,可供 Camera 2夜间模式相机扩展使用。“低光增强”功能可调整预览视频流在弱光条件下的曝光量。这与夜间模式相机扩展程序创建静态图片的方式不同,因为夜间模式会组合多张照片来制作单张增强图片。虽然夜间模式非常适合创建静态图片,但无法创建连续的帧流,但“低光增强”可以。因此,“低光增强”可以实现新的相机功能,例如:

  • 提供增强的图片预览,以便用户更好地为弱光环境取景
  • 在光线昏暗的环境下扫描二维码

如果您启用“弱光增强”,它会在光线较暗时自动开启,在光线较暗时关闭。

应用可以在光线昏暗的环境下录制预览流,以保存明亮的视频。

有关详情,请参阅弱光增强

인앱 카메라 제어

Android 15에서는 지원되는 기기에서 카메라 하드웨어 및 알고리즘을 더 효과적으로 제어하기 위한 새 확장 프로그램을 추가합니다.

  • 고급 플래시 강도 조정을 통해 이미지를 캡처하는 동안 SINGLETORCH 모드에서 플래시 강도를 정밀하게 제어할 수 있습니다.

HDR 헤드룸 제어

Android 15는 기본 기기 기능과 패널의 비트 심도에 적합한 HDR 헤드룸을 선택합니다. 단일 HDR 썸네일을 표시하는 메시지 앱과 같이 SDR 콘텐츠가 많은 페이지의 경우 이 동작은 SDR 콘텐츠의 인지되는 밝기에 부정적인 영향을 줄 수 있습니다. Android 15에서는 setDesiredHdrHeadroom로 HDR 헤드룸을 제어하여 SDR과 HDR 콘텐츠 간의 균형을 맞출 수 있습니다.

왼쪽 화면에 있는 SDR UI 요소의 밝기는 오른쪽 화면의 밝기보다 더 균일하게 보입니다. 이는 HDR과 SDR 콘텐츠가 혼합될 때 발생할 수 있는 헤드룸 문제를 시뮬레이션합니다. HDR 헤드룸을 조정하면 SDR과 HDR 콘텐츠 간의 밸런스를 개선할 수 있습니다.

음량 제어

Android 15 introduces support for the CTA-2075 loudness standard to help you avoid audio loudness inconsistencies and ensure users don't have to constantly adjust volume when switching between content. The system leverages known characteristics of the output devices (headphones and speaker) along with loudness metadata available in AAC audio content to intelligently adjust the audio loudness and dynamic range compression levels.

To enable this feature, you need to ensure loudness metadata is available in your AAC content and enable the platform feature in your app. For this, you instantiate a LoudnessCodecController object by calling its create factory method with the audio session ID from the associated AudioTrack; this automatically starts applying audio updates. You can pass an OnLoudnessCodecUpdateListener to modify or filter loudness parameters before they are applied on the MediaCodec.

// Media contains metadata of type MPEG_4 OR MPEG_D
val mediaCodec = 
val audioTrack = AudioTrack.Builder()
                                .setSessionId(sessionId)
                                .build()
...
// Create new loudness controller that applies the parameters to the MediaCodec
try {
   val lcController = LoudnessCodecController.create(mSessionId)
   // Starts applying audio updates for each added MediaCodec
}

AndroidX media3 ExoPlayer will also be updated to use the LoudnessCodecController APIs for a seamless app integration.

가상 MIDI 2.0 기기

Android 13에서는 범용 MIDI 패킷 (UMP)을 사용하여 통신하는 USB를 사용하여 MIDI 2.0 기기에 연결할 수 있는 지원을 추가했습니다. Android 15는 가상 MIDI 앱으로 UMP 지원을 확장하여 컴포지션 앱이 USB MIDI 2.0 기기와 마찬가지로 가상 MIDI 2.0 기기로 신시사이저 앱을 제어할 수 있도록 합니다.

더 효율적인 AV1 소프트웨어 디코딩

dav1d 로고

이제 VideoLAN의 인기 있는 AV1 소프트웨어 디코더인 dav1d를 하드웨어에서 AV1 디코딩을 지원하지 않는 Android 기기에서 사용할 수 있습니다. dav1d는 기존 AV1 소프트웨어 디코더보다 성능이 최대 3배 더 우수하므로 일부 저성능 및 중간 등급 기기를 포함한 더 많은 사용자가 HD AV1을 재생할 수 있습니다.

지금은 앱에서 "c2.android.av1-dav1d.decoder"라는 이름으로 dav1d를 호출하여 dav1d를 사용하도록 선택해야 합니다. 이후 업데이트에서 dav1d가 기본 AV1 소프트웨어 디코더가 됩니다. 이 지원은 표준화되어 Google Play 시스템 업데이트를 수신하는 Android 11 기기로 백포팅됩니다.

개발자 생산성 및 도구

Google의 생산성 개선 작업은 대부분 Android 스튜디오, Jetpack Compose, Android Jetpack 라이브러리와 같은 도구를 중심으로 이루어지지만 Google은 항상 개발자가 비전을 더 쉽게 실현할 수 있는 방법을 찾기 위해 노력하고 있습니다.

OpenJDK 17 업데이트

Android 15 会继续更新 Android 的核心库,以与最新 OpenJDK LTS 版本中的功能保持一致。

其中包含以下主要功能和改进:

这些 API 通过 Google Play 系统更新在超过 10 亿台搭载 Android 12(API 级别 31)及更高版本的设备上进行了更新,让您能够以最新的编程功能为目标平台。

PDF 개선

Android 15 对 PdfRenderer API 进行了重大改进。应用可以整合一些高级功能,例如渲染受密码保护的文件、注解、表单编辑搜索和通过复制进行选择。支持线性 PDF 优化,以加快本地 PDF 的查看速度并减少资源使用量。

针对 PDF 渲染功能的最新更新包括搜索嵌入式 PDF 文件等功能。

PdfRenderer 已移至一个模块,此模块可使用与平台版本无关的 Google Play 系统更新来进行更新,并且我们将通过创建兼容的 API Surface 低于 Android 15 的版本(称为 PdfRendererPreV)来支持在 Android 11(API 级别 30)中更新这些变更。

我们非常重视您对 PdfRenderer API 接口的增强功能的反馈,我们计划通过即将推出的 Android Jetpack 库,让开发者能更轻松地将这些 API 整合到您的应用中。

자동 언어 전환 미세 조정

Android 14에서는 언어 간 자동 전환을 통해 오디오에 기기 내 다국어 인식을 추가했지만, 이로 인해 특히 두 발화 간에 일시중지가 적은 언어가 전환되는 경우 단어가 누락될 수 있습니다. Android 15에는 앱이 이 전환을 사용 사례에 맞게 조정할 수 있도록 추가 컨트롤이 추가되었습니다. EXTRA_LANGUAGE_SWITCH_INITIAL_ACTIVE_DURATION_TIME_MILLIS는 자동 전환을 오디오 세션의 시작 부분으로 제한하고, EXTRA_LANGUAGE_SWITCH_MATCH_SWITCHES는 정의된 수의 스위치 후에 언어 전환을 비활성화합니다. 이 옵션은 세션 중에 사용되는 단일 언어가 있을 것으로 예상되는 경우 특히 유용합니다.

개선된 OpenType 변수 글꼴 API

Android 15 提高了 OpenType 可变字体的易用性。现在,您可以 基于可变字体创建 FontFamily 实例,而不指定 使用 buildVariableFamily API 绘制权重轴。文本渲染程序替换项 wght 轴的值,以与显示的文本匹配。

使用新的 API,这可以简化用于创建 Typeface 的代码 大量:

Kotlin

val newTypeface = Typeface.CustomFallbackBuilder(
            FontFamily.Builder(
                Font.Builder(assets, "RobotoFlex.ttf").build())
                    .buildVariableFamily())
    .build()

Java

Typeface newTypeface = Typeface.CustomFallbackBuilder(
            new FontFamily.Builder(
                new Font.Builder(assets, "RobotoFlex.ttf").build())
                    .buildVariableFamily())
    .build();

以前,如需创建相同的 Typeface,您需要更多代码:

Kotlin

val oldTypeface = Typeface.CustomFallbackBuilder(
            FontFamily.Builder(
                Font.Builder(assets, "RobotoFlex.ttf")
                    .setFontVariationSettings("'wght' 400")
                    .setWeight(400)
                    .build())
                .addFont(
                    Font.Builder(assets, "RobotoFlex.ttf")
                        .setFontVariationSettings("'wght' 100")
                        .setWeight(100)
                        .build()
                )
                .addFont(
                    Font.Builder(assets, "RobotoFlex.ttf")
                        .setFontVariationSettings("'wght' 200")
                        .setWeight(200)
                        .build()
                )
                .addFont(
                    Font.Builder(assets, "RobotoFlex.ttf")
                        .setFontVariationSettings("'wght' 300")
                        .setWeight(300)
                        .build()
                )
                .addFont(
                    Font.Builder(assets, "RobotoFlex.ttf")
                        .setFontVariationSettings("'wght' 500")
                        .setWeight(500)
                        .build()
                )
                .addFont(
                    Font.Builder(assets, "RobotoFlex.ttf")
                        .setFontVariationSettings("'wght' 600")
                        .setWeight(600)
                        .build()
                )
                .addFont(
                    Font.Builder(assets, "RobotoFlex.ttf")
                        .setFontVariationSettings("'wght' 700")
                        .setWeight(700)
                        .build()
                )
                .addFont(
                    Font.Builder(assets, "RobotoFlex.ttf")
                        .setFontVariationSettings("'wght' 800")
                        .setWeight(800)
                        .build()
                )
                .addFont(
                    Font.Builder(assets, "RobotoFlex.ttf")
                        .setFontVariationSettings("'wght' 900")
                        .setWeight(900)
                        .build()
                ).build()
        ).build()

Java

Typeface oldTypeface = new Typeface.CustomFallbackBuilder(
    new FontFamily.Builder(
        new Font.Builder(assets, "RobotoFlex.ttf")
            .setFontVariationSettings("'wght' 400")
            .setWeight(400)
            .build()
    )
    .addFont(
        new Font.Builder(assets, "RobotoFlex.ttf")
            .setFontVariationSettings("'wght' 100")
            .setWeight(100)
            .build()
    )
    .addFont(
        new Font.Builder(assets, "RobotoFlex.ttf")
            .setFontVariationSettings("'wght' 200")
            .setWeight(200)
            .build()
    )
    .addFont(
        new Font.Builder(assets, "RobotoFlex.ttf")
            .setFontVariationSettings("'wght' 300")
            .setWeight(300)
            .build()
    )
    .addFont(
        new Font.Builder(assets, "RobotoFlex.ttf")
            .setFontVariationSettings("'wght' 500")
            .setWeight(500)
            .build()
    )
    .addFont(
        new Font.Builder(assets, "RobotoFlex.ttf")
            .setFontVariationSettings("'wght' 600")
            .setWeight(600)
            .build()
    )
    .addFont(
        new Font.Builder(assets, "RobotoFlex.ttf")
            .setFontVariationSettings("'wght' 700")
            .setWeight(700)
            .build()
    )
    .addFont(
        new Font.Builder(assets, "RobotoFlex.ttf")
            .setFontVariationSettings("'wght' 800")
            .setWeight(800)
            .build()
    )
    .addFont(
        new Font.Builder(assets, "RobotoFlex.ttf")
            .setFontVariationSettings("'wght' 900")
            .setWeight(900)
            .build()
    )
    .build()
).build();

以下示例展示了如何同时使用新旧 API 创建 Typeface 呈现:

示例:使用新旧版本时字体渲染有何不同
API

在此示例中,使用旧 API 创建的 Typeface 不包含 为 350、450、550 和 650 创建准确的字体粗细 Font 实例,因此渲染程序会回退到最接近的权重。在 在此示例中,系统会渲染 300 而不是 350,渲染 400 而不是 450, 依此类推。相比之下,使用新 API 创建的 Typeface 会动态创建 给定权重的 Font 实例,因此系统会渲染 350 的准确权重, 450、550 和 650。

세밀한 줄바꿈 제어

从 Android 15 开始,TextView 和底层 换行符可以保留同一行中给定的文本部分, 可读性。您可以通过使用 字符串资源中的 <nobreak> 标记,或 createNoBreakSpan。同样,您可以保留 使用 <nohyphen> 标记断字;或者 createNoHyphenationSpan

例如,以下字符串资源不包含换行符,并且 渲染时会显示“Pixel 8 Pro”文字在不理想的位置发生故障:

<resources>
    <string name="pixel8pro">The power and brains behind Pixel 8 Pro.</string>
</resources>

相比之下,此字符串资源包含 <nobreak> 标记,用于封装 如“Pixel 8 Pro”并防止换行:

<resources>
    <string name="pixel8pro">The power and brains behind <nobreak>Pixel 8 Pro.</nobreak></string>
</resources>

下方显示了这些字符串的呈现方式差异 图片:

一行文字的布局,其中包含短语“Pixel 8 Pro”。未使用 <nobreak> 标记进行封装。
短语“Pixel 8 Pro”所在的同一行文字的布局。使用 <nobreak> 标记封装。

앱 보관처리

Android and Google Play announced support for app archiving last year, allowing users to free up space by partially removing infrequently used apps from the device that were published using Android App Bundle on Google Play. Android 15 includes OS level support for app archiving and unarchiving, making it easier for all app stores to implement it.

Apps with the REQUEST_DELETE_PACKAGES permission can call the PackageInstaller requestArchive method to request archiving an installed app package, which removes the APK and any cached files, but persists user data. Archived apps are returned as displayable apps through the LauncherApps APIs; users will see a UI treatment to highlight that those apps are archived. If a user taps on an archived app, the responsible installer will get a request to unarchive it, and the restoration process can be monitored by the ACTION_PACKAGE_ADDED broadcast.

그래픽

Android 15에서는 ANGLE 및 캔버스 그래픽 시스템 추가를 비롯한 최신 그래픽 개선사항을 제공합니다.

Android의 GPU 액세스 현대화

Vulkan logo

Android hardware has evolved quite a bit from the early days where the core OS would run on a single CPU and GPUs were accessed using APIs based on fixed-function pipelines. The Vulkan® graphics API has been available in the NDK since Android 7.0 (API level 24) with a lower-level abstraction that better reflects modern GPU hardware, scales better to support multiple CPU cores, and offers reduced CPU driver overhead — leading to improved app performance. Vulkan is supported by all modern game engines.

Vulkan is Android's preferred interface to the GPU. Therefore, Android 15 includes ANGLE as an optional layer for running OpenGL® ES on top of Vulkan. Moving to ANGLE will standardize the Android OpenGL implementation for improved compatibility, and, in some cases, improved performance. You can test out your OpenGL ES app stability and performance with ANGLE by enabling the developer option in Settings -> System -> Developer Options -> Experimental: Enable ANGLE on Android 15.

The Android ANGLE on Vulkan roadmap

Roadmap of upcoming changes to the Android GPU APIs.

As part of streamlining our GPU stack, going forward we will be shipping ANGLE as the GL system driver on more new devices, with the future expectation that OpenGL/ES will be only available through ANGLE. That being said, we plan to continue support for OpenGL ES on all devices.

Recommended next steps

Use the developer options to select the ANGLE driver for OpenGL ES and test your app. For new projects, we strongly encourage using Vulkan for C/C++.

캔버스 개선사항

Android 15에서는 새로운 기능을 통해 Android 캔버스 그래픽 시스템을 현대화하고 있습니다.

  • Matrix44는 3D에서 캔버스를 조작하려고 할 때 사용해야 하는 좌표 변환을 위한 4x4 행렬을 제공합니다.
  • clipShader는 현재 클립을 지정된 셰이더와 교차하는 반면 clipOutShader는 클립을 현재 클립과 셰이더의 차이로 설정하여 각각 셰이더를 알파 마스크로 처리합니다. 이를 통해 복잡한 도형을 효율적으로 그릴 수 있습니다.

성능 및 배터리

Android는 개발자가 앱의 성능과 품질을 개선하는 데 도움이 되는 데 최선을 다하고 있습니다. Android 15에는 앱의 작업을 더 효율적으로 실행하고 앱 성능을 최적화하며 앱에 관한 유용한 정보를 수집할 수 있는 새로운 API가 도입되었습니다.

배터리 효율적인 권장사항, 네트워크 및 전력 사용량 디버깅, Android 15 및 최신 버전의 Android에서 백그라운드 작업의 배터리 효율성을 개선하는 방법에 관한 자세한 내용은 Google I/O의 Android에서 백그라운드 작업의 배터리 효율 개선 강연을 참고하세요.

애플리케이션 시작 정보 API

在以前的 Android 版本中,应用启动有点神秘。在应用中确定应用是从冷状态、温状态还是热状态开始的过程很难确定。此外,我们也很难知道您的应用在不同发布阶段所用的时间:创建进程分支、调用 onCreate、绘制第一帧等。在实例化 Application 类时,您无法得知应用是从广播、content provider、作业、备份、启动完成、闹钟还是 Activity 启动的。

Android 15 上的 ApplicationStartInfo API 可提供所有这些功能以及更多其他功能。您甚至可以选择将自己的时间戳添加到流程中,以便在一个位置收集时间数据。除了收集指标之外,您还可以使用 ApplicationStartInfo 直接优化应用启动;例如,当应用因广播而启动时,您可以避免在 Application 类中实例化界面相关库的高成本。

자세한 앱 크기 정보

Android 8.0(API 수준 26)부터 Android에는 APK 크기, APK에서 추출한 파일 크기, 기기에서 생성된 파일(예: AOT(Ahead-Of-Time) 컴파일 코드)의 합계인 단일 바이트 수로 앱 설치 크기를 요약하는 StorageStats.getAppBytes API가 포함되었습니다. 이 수치는 앱이 저장용량을 사용하는 방식과 관련하여 중요한 역할을 하지 않습니다.

Android 15에는 APK 파일 분할, AOT 및 속도 향상 관련 코드, dex 메타데이터, 라이브러리, 가이드 프로필 등 앱이 공간을 어떻게 사용하고 있는지 파악할 수 있는 StorageStats.getAppBytesByDataType([type]) API가 추가되었습니다.

앱 관리 프로파일링

Android 15에는 앱 내에서 프로파일링 정보를 수집할 수 있는 완전히 새로운 ProfilingManager 클래스가 포함되어 있습니다. 프로파일링 요청 구성을 간소화하는 Android Jetpack API로 이를 래핑할 계획이지만 핵심 API는 힙 덤프, 힙 프로필, 스택 샘플링 등의 수집을 허용합니다. 제공된 태그와 함께 앱에 콜백을 제공하여 앱의 파일 디렉터리로 전달되는 출력 파일을 식별합니다. API는 성능 영향을 최소화하기 위해 비율 제한을 실행합니다.

SQLite 데이터베이스 개선사항

Android 15 引入了新的 SQLite API,可提供底层 SQLite 引擎的高级功能,这些功能旨在解决应用中可能出现的特定性能问题。

开发者应查阅 SQLite 性能最佳实践,以充分利用其 SQLite 数据库,尤其是在使用大型数据库或运行对延迟敏感的查询时。

  • 只读延迟事务:发出只读事务(不包括写入语句)时,使用 beginTransactionReadOnly()beginTransactionWithListenerReadOnly(SQLiteTransactionListener) 发出只读 DEFERRED 事务。此类事务可以相互并发运行,如果数据库处于 WAL 模式,则它们可以与 IMMEDIATEEXCLUSIVE 事务并发运行。
  • 行数和 ID:新增了 API,用于检索已更改的行的计数或最后插入的行 ID,而无需发出额外的查询。getLastChangedRowCount() 返回当前事务中的最新 SQL 语句插入、更新或删除的行数,而 getTotalChangedRowCount() 返回当前连接的相关计数。getLastInsertRowId() 返回要在当前连接上插入的最后一行的 rowid
  • 原始语句:发出原始 SQlite 语句,绕过便捷封装容器以及它们可能产生的任何其他处理开销。

Android 동적 성능 프레임워크 업데이트

Android 15 继续投资开发 Android 动态性能框架 (ADPF),这是一组 API,可让游戏和性能密集型应用更直接地与 Android 设备的电源和散热系统进行互动。在受支持的设备上,Android 15 将添加新的 ADPF 功能:

  • 适用于提示会话的节能模式,用于指明其关联的线程应该优先考虑节能而非性能,非常适合长时间运行的后台工作负载。
  • 可以在提示会话中报告 GPU 和 CPU 的运行时长,从而使系统能够同时调整 CPU 和 GPU 频率,以便更好地满足工作负载需求。
  • 热余量阈值,用于根据余量预测来解释可能的热节流状态。

如需详细了解如何在应用和游戏中使用 ADPF,请参阅相关文档

개인 정보 보호

Android 15에는 앱 개발자가 사용자 개인 정보를 보호하는 데 도움이 되는 다양한 기능이 포함되어 있습니다.

화면 녹화 감지

Android 15 添加了对应用的支持,以检测 正在录制。每当应用转换时,系统都会调用回调 在屏幕录制内容中处于可见与隐藏状态之间。应用 如果注册进程的 UID 拥有的 activity 正在录制。这样一来,如果您的应用正在执行敏感操作,您可以 可以告知用户其正在录制。

val mCallback = Consumer<Int> { state ->
  if (state == SCREEN_RECORDING_STATE_VISIBLE) {
    // We're being recorded
  } else {
    // We're not being recorded
  }
}

override fun onStart() {
   super.onStart()
   val initialState =
      windowManager.addScreenRecordingCallback(mainExecutor, mCallback)
   mCallback.accept(initialState)
}

override fun onStop() {
    super.onStop()
    windowManager.removeScreenRecordingCallback(mCallback)
}

확장된 IntentFilter 기능

Android 15 build 通过通过以下方式支持更精确的 Intent 解析: UriRelativeFilterGroup,其中包含一组 构成一组 IntentUriRelativeFilter 对象 每个必须满足的匹配规则,包括网址查询参数、网址 以及屏蔽或排除规则

这些规则可以在 AndroidManifest XML 文件中定义,新的 <uri-relative-filter-group> 标记,该标记中可以选择包含一个 android:allow 标记之间。这些标记可以包含使用现有数据的 <data> 标记 标记属性以及新的 android:queryandroid:fragment 属性。

以下是 AndroidManifest 语法的示例:

<intent-filter>
  <action android:name="android.intent.action.VIEW" />
  <category android:name="android.intent.category.BROWSABLE" />
  <data android:scheme="http" />
  <data android:scheme="https" />
  <data android:domain="astore.com" />
  <uri-relative-filter-group>
    <data android:pathPrefix="/auth" />
    <data android:query="region=na" />
  </uri-relative-filter-group>
  <uri-relative-filter-group android:allow="false">
    <data android:pathPrefix="/auth" />
    <data android:query="mobileoptout=true" />
  </uri-relative-filter-group>
  <uri-relative-filter-group android:allow="false">
    <data android:pathPrefix="/auth" />
    <data android:fragmentPrefix="faq" />
  </uri-relative-filter-group>
</intent-filter>

비공개 스페이스

<ph type="x-smartling-placeholder">
您可以通过解锁和锁定私密空间来显示或隐藏私密空间 敏感应用。

私密空间可让用户在设备上创建单独的空间 保护敏感应用免遭窥探, 身份验证。私密空间使用单独的用户个人资料。用户可以 选择为私密空间使用设备锁定或单独的锁定因素。

私密空间中的应用显示在启动器中的单独容器中,并且 不会显示在“最近用过”视图、通知、设置和其他应用中 在私密空间处于锁定状态时显示通知用户生成的内容(例如 媒体或文件),而账号会在私密空间和 主空间系统 Sharesheet照片选择器:用于授权应用访问内容

用户无法将现有应用及其数据移至私密空间。相反, 用户在私密空间中选择安装选项,以便使用 无论他们喜欢哪家应用商店私密空间中的应用会以下列身份安装: 来自主空间中任何应用的单独副本(同一应用的新副本)。

当用户锁定私密空间后,系统会停用相应个人资料。而配置文件 已停止,私密空间中的应用不再有效,无法执行 前台或后台 activity,包括显示通知。

我们建议您使用私密空间测试您的应用,以确保您的应用 按预期运行,尤其是当应用属于以下某种情况时 类别:

선택한 사진 액세스에 대한 최근 사용자 선택 쿼리 쿼리

이제 앱에서 가장 최근에 선택한 사진만 강조 표시할 수 있습니다. 미디어 권한에 대한 부분 액세스 권한이 부여된 경우 동영상 및 동영상 등 YouTube에 저장된 동영상 파일도 안전하게 보호할 수 있습니다. 이 기능을 통해 자주 요청되는 앱의 사용자 환경을 개선할 수 있습니다. 사진 및 동영상에 액세스할 수 없습니다. 앱에서 이 기능을 사용하려면 MediaStore를 쿼리할 때 QUERY_ARG_LATEST_SELECTION_ONLY 인수 ContentResolver까지

Kotlin

val externalContentUri = MediaStore.Files.getContentUri("external")

val mediaColumns = arrayOf(
   FileColumns._ID,
   FileColumns.DISPLAY_NAME,
   FileColumns.MIME_TYPE,
)

val queryArgs = bundleOf(
   // Return only items from the last selection (selected photos access)
   QUERY_ARG_LATEST_SELECTION_ONLY to true,
   // Sort returned items chronologically based on when they were added to the device's storage
   QUERY_ARG_SQL_SORT_ORDER to "${FileColumns.DATE_ADDED} DESC",
   QUERY_ARG_SQL_SELECTION to "${FileColumns.MEDIA_TYPE} = ? OR ${FileColumns.MEDIA_TYPE} = ?",
   QUERY_ARG_SQL_SELECTION_ARGS to arrayOf(
       FileColumns.MEDIA_TYPE_IMAGE.toString(),
       FileColumns.MEDIA_TYPE_VIDEO.toString()
   )
)

Java

Uri externalContentUri = MediaStore.Files.getContentUri("external");

String[] mediaColumns = {
    FileColumns._ID,
    FileColumns.DISPLAY_NAME,
    FileColumns.MIME_TYPE
};

Bundle queryArgs = new Bundle();
queryArgs.putBoolean(MediaStore.QUERY_ARG_LATEST_SELECTION_ONLY, true);
queryArgs.putString(MediaStore.QUERY_ARG_SQL_SORT_ORDER, FileColumns.DATE_ADDED + " DESC");
queryArgs.putString(MediaStore.QUERY_ARG_SQL_SELECTION, FileColumns.MEDIA_TYPE + " = ? OR " + FileColumns.MEDIA_TYPE + " = ?");
queryArgs.putStringArray(MediaStore.QUERY_ARG_SQL_SELECTION_ARGS, new String[] {
    String.valueOf(FileColumns.MEDIA_TYPE_IMAGE),
    String.valueOf(FileColumns.MEDIA_TYPE_VIDEO)
});

Android의 개인 정보 보호 샌드박스

Android 15에는 최신 버전의 Android의 개인 정보 보호 샌드박스가 통합된 최신 Android 광고 서비스 확장 프로그램이 포함되어 있습니다. 이러한 추가 조치는 사용자 개인 정보 보호를 개선하고 모바일 앱에 효과적인 개인 맞춤 광고 경험을 지원하는 새로운 기술을 개발하려는 노력의 일환입니다. 개인 정보 보호 샌드박스 페이지에서 시작하는 데 도움이 되는 Android의 개인 정보 보호 샌드박스 개발자 프리뷰 및 베타 프로그램에 관한 자세한 정보를 확인할 수 있습니다.

헬스 커넥트

Android 15 integrates the latest extensions around Health Connect by Android, a secure and centralized platform to manage and share app-collected health and fitness data. This update adds support for additional data types across fitness, nutrition, skin temperature, training plans, and more.

Skin temperature tracking allows users to store and share more accurate temperature data from a wearable or other tracking device.

Training plans are structured workout plans to help a user achieve their fitness goals. Training plans support includes a variety of completion and performance goals:

Learn more about the latest updates to Health Connect in Android in the Building adaptable experiences with Android Health talk from Google I/O.

부분 화면 공유

Android 15는 부분 화면 공유를 지원하므로 사용자는 전체 기기 화면이 아닌 앱 창만 공유하거나 녹화할 수 있습니다. Android 14 QPR2에서 처음 사용 설정된 이 기능에는 앱에서 부분 화면 공유 환경을 맞춤설정할 수 있는 MediaProjection 콜백이 포함되어 있습니다. Android 14 (API 수준 34) 이상을 타겟팅하는 앱의 경우 이제 각 MediaProjection 캡처 세션에 사용자 동의가 필요합니다.

사용자 환경 및 시스템 UI

Android 15에서는 앱 개발자와 사용자가 필요에 맞게 기기를 구성할 수 있는 더 많은 제어와 유연성을 제공합니다.

Android 15의 최신 개선사항을 사용하여 앱의 사용자 환경을 개선하는 방법에 관한 자세한 내용은 Google I/O의 Android 앱의 사용자 환경 개선 강연을 참고하세요.

Generated Previews API로 더 풍부한 위젯 미리보기

Before Android 15, the only way to provide widget picker previews was to specify a static image or layout resource. These previews often differ significantly from the look of the actual widget when it is placed on the home screen. Also, static resources can't be created with Jetpack Glance, so a Glance developer had to screenshot their widget or create an XML layout to have a widget preview.

Android 15 adds support for generated previews. This means that app widget providers can generate RemoteViews to use as the picker preview, instead of a static resource.

Apps can provide Remote Views to the Widget Picker, so they can update the content in the picker to be more representative of what the user will see.

Push API

Apps can provide generated previews through a push API. Apps can provide previews at any point in their lifecycle, and don't receive an explicit request from the host to provide previews. Previews are persisted in AppWidgetService, and hosts can request them on-demand. The following example loads an XML widget layout resource and sets it as the preview:

AppWidgetManager.getInstance(appContext).setWidgetPreview(
   ComponentName(
       appContext,
       SociaLiteAppWidgetReceiver::class.java
   ),
   AppWidgetProviderInfo.WIDGET_CATEGORY_HOME_SCREEN,
   RemoteViews("com.example", R.layout.widget_preview)
)

The expected flow is:

  1. At any time, the widget provider calls setWidgetPreview. The provided previews are persisted in AppWidgetService with other provider info.
  2. setWidgetPreview notifies hosts of an updated preview through the AppWidgetHost.onProvidersChanged callback. In response, the widget host reloads all of its provider information.
  3. When displaying a widget preview, the host checks AppWidgetProviderInfo.generatedPreviewCategories, and if the chosen category is available, calls AppWidgetManager.getWidgetPreview to return the saved preview for this provider.

When to call setWidgetPreview

Because there is no callback to provide previews, apps can choose to send previews at any point when they are running. How often to update the preview depends on the widget's use case.

The following list describes the two main categories of preview use cases:

  • Providers that show real data in their widget previews, such as personalized or recent information. These providers can set the preview once the user has signed in or has done initial configuration in their app. After this, they can set up a periodic task to update the previews at their chosen cadence. Examples of this type of widget could be a photo, calendar, weather or news widget.
  • Providers that show static information in previews or quick-action widgets that don't display any data. These providers can set previews once, when the app first launches. Examples of this type of widget include a drive quick actions widget or chrome shortcuts widget.

Some providers might show static previews on the hub mode picker, but real information on the homescreen picker. These providers should follow the guidance for both of these use cases to set previews.

PIP 모드

Android 15 introduces changes in Picture-in-Picture (PiP) ensuring an even smoother transition when entering into PiP mode. This will be beneficial for apps having UI elements overlaid on top of their main UI, which goes into PiP.

Developers use the onPictureInPictureModeChanged callback to define logic that toggles the visibility of the overlaid UI elements. This callback is triggered when the PiP enter or exit animation is completed. Beginning in Android 15, the PictureInPictureUiState class includes another state.

With this UI state, apps targeting Android 15 (API level 35) will observe the Activity#onPictureInPictureUiStateChanged callback being invoked with isTransitioningToPip() as soon as the PiP animation starts. There are many UI elements that are not relevant for the app when it is in PiP mode, for example views or layout that include information such as suggestions, upcoming video, ratings, and titles. When the app goes to PiP mode, use the onPictureInPictureUiStateChanged callback to hide these UI elements. When the app goes to full screen mode from the PiP window, use onPictureInPictureModeChanged callback to unhide these elements, as shown in the following examples:

override fun onPictureInPictureUiStateChanged(pipState: PictureInPictureUiState) {
        if (pipState.isTransitioningToPip()) {
          // Hide UI elements
        }
    }
override fun onPictureInPictureModeChanged(isInPictureInPictureMode: Boolean) {
        if (isInPictureInPictureMode) {
          // Unhide UI elements
        }
    }

This quick visibility toggle of irrelevant UI elements (for a PiP window) helps ensure a smoother and flicker-free PiP enter animation.

개선된 방해 금지 모드 규칙

AutomaticZenRule 可让应用自定义注意力管理(勿扰)规则,并决定何时启用或停用这些规则。Android 15 大幅增强了这些规则,以改善用户体验。其中包含以下增强功能:

  • 将类型添加到 AutomaticZenRule,允许系统对某些规则应用特殊处理。
  • AutomaticZenRule 添加了图标,有助于使模式更易于识别。
  • AutomaticZenRule 添加 triggerDescription 字符串,用于描述应在哪些条件下为用户启用规则。
  • AutomaticZenRule 添加了 ZenDeviceEffects,以允许规则触发灰度显示、夜间模式或调暗壁纸等功能。

알림 채널에 VibrationEffect 설정

Android 15는 NotificationChannel.setVibrationEffect를 사용하여 수신 알림에 다양한 진동 설정을 지원하므로 사용자가 기기를 보지 않고도 여러 유형의 알림을 구별할 수 있습니다.

대형 화면 및 폼 팩터

Android 15에서는 앱에서 대형 화면, 플립블, 폴더블을 비롯한 Android 폼 팩터를 최대한 활용할 수 있도록 지원합니다.

개선된 대형 화면 멀티태스킹

Android 15 为用户提供了更好的在大屏设备上进行多任务处理的方式。例如,用户可以保存他们喜欢的分屏应用组合以快速访问,还可以固定屏幕上的任务栏以在应用之间快速切换。这意味着,确保应用具有自适应能力比以往任何时候都更加重要。

Google I/O 大会举办了有关构建自适应 Android 应用使用 Material 3 自适应库构建界面的会议,这对您有所帮助。我们的文档中包含更多可以帮助您针对大屏幕进行设计的文档。

커버 화면 지원

앱은 Android 15에서 지원되는 플립형 기기의 작은 커버 화면에 Application 또는 Activity가 표시되도록 하는 데 사용하는 속성을 선언할 수 있습니다. 이러한 화면은 Android 앱을 실행하기에 호환되는 타겟으로 간주하기에는 너무 작지만 앱이 이를 지원하도록 선택하여 더 많은 위치에서 앱을 사용할 수 있습니다.

연결

Android 15에서는 앱이 통신 및 무선 기술의 최신 발전 사항에 액세스할 수 있도록 플랫폼을 업데이트합니다.

위성 지원

Android 15에서는 위성 연결을 위한 플랫폼 지원을 계속 확장하고 위성 연결 환경 전반에서 일관된 사용자 환경을 보장하기 위해 일부 UI 요소를 포함합니다.

앱은 ServiceState.isUsingNonTerrestrialNetwork()를 사용하여 기기가 위성에 연결된 시점을 감지하고 전체 네트워크 서비스를 사용할 수 없는 이유를 더 잘 파악할 수 있습니다. 또한 Android 15는 메시지를 보내고 받는 데 위성 연결을 사용할 수 있도록 SMS 및 MMS 앱은 물론 미리 로드된 RCS 앱을 지원합니다.

기기가 위성에 연결되면 알림이 표시됩니다.

더 부드러운 NFC 환경

Android 15 致力于打造更顺畅、更可靠的感应式付款体验,同时继续支持 Android 强大的 NFC 应用生态系统。在受支持的设备上,应用可以请求 NfcAdapter 进入观察模式。在该模式下,设备会监听 NFC 读取器但不会响应 NFC 读取器,从而将应用的 NFC 服务 PollingFrame 对象发送给系统进行处理。PollingFrame 对象可用于在与 NFC 读取器首次通信之前进行身份验证,以便在许多情况下实现一键交易。

此外,应用现在可以在受支持的设备上注册过滤器,以便接收轮询循环 activity 的通知,从而与多个 NFC 感知应用顺畅运行。

월렛 역할

Android 15에는 사용자가 선호하는 월렛 앱과의 긴밀한 통합을 가능하게 하는 새로운 월렛 역할이 도입되었습니다. 이 역할은 NFC 기본 미접촉 결제 설정을 대체합니다. 사용자는 설정 > 앱 > 기본 앱으로 이동하여 월렛 역할 보유자를 관리할 수 있습니다.

월렛 역할은 결제 카테고리에 등록된 AID의 NFC 탭을 라우팅할 때 사용됩니다. 동일한 AID에 등록된 다른 앱이 포그라운드에서 실행되고 있지 않은 한 탭은 항상 월렛 역할 보유자로 이동합니다.

이 역할은 월렛 빠른 액세스 타일이 활성화될 때 이동할 위치를 결정하는 데도 사용됩니다. 역할이 'None'으로 설정되면 QuickAccess 카드를 사용할 수 없으며 결제 카테고리 NFC 탭은 포그라운드 앱에만 전달됩니다.

보안

Android 15는 앱의 보안을 강화하고 앱 데이터를 보호하며 사용자에게 데이터에 관한 더 높은 투명성과 제어 기능을 제공합니다. 사용자 보호 장치를 개선하고 새로운 위협으로부터 앱을 보호하기 위해 Google에서 어떤 노력을 기울이고 있는지 자세히 알아보려면 Google I/O의 Android에서 사용자 보안 보호 강연을 참조하세요.

자동 완성과 인증 관리자 통합

Starting with Android 15, developers can link specific views like username or password fields with Credential Manager requests, making it easier to provide a tailored user experience during the sign-in process. When the user focuses on one of these views, a corresponding request is sent to Credential Manager. The resulting credentials are aggregated across providers and displayed in autofill fallback UIs, such as inline suggestions or drop-down suggestions. The Jetpack androidx.credentials library is the preferred endpoint for developers to use and will soon be available to further enhance this feature in Android 15 and higher.

원탭 가입 및 로그인을 생체 인식 프롬프트와 통합

Credential Manager integrates biometric prompts into the credential creation and sign-in processes, eliminating the need for providers to manage biometric prompts. As a result, credential providers only need to focus on the results of the create and get flows, augmented with the biometric flow result. This simplified process creates a more efficient and streamlined credential creation and retrieval process.

엔드 투 엔드 암호화를 위한 키 관리

Android 15에 암호화 공개 키 저장을 위한 OS 수준 API를 제공하여 Android 앱의 엔드 투 엔드 암호화 (E2EE)를 용이하게 하는 E2eeContactKeysManager가 도입되었습니다.

E2eeContactKeysManager는 플랫폼 연락처 앱과 통합되도록 설계되어 사용자에게 연락처의 공개 키를 중앙에서 관리하고 확인하는 방법을 제공합니다.

콘텐츠 URI의 권한 확인

Android 15 引入了一组可对内容 URI 执行权限检查的新 API:

접근성

Android 15에는 사용자의 접근성을 개선하는 기능이 추가되었습니다.

향상된 점자 기능

Android 15에서는 TalkBack이 USB 및 보안 블루투스를 통해 HID 표준을 사용하는 점자 디스플레이를 지원할 수 있도록 했습니다.

마우스 및 키보드에서 사용하는 것과 매우 유사한 이 표준은 Android가 시간이 지남에 따라 더 다양한 점자 디스플레이를 지원하는 데 도움이 될 것입니다.

다국어 지원

Android 15에는 기기를 다양한 언어로 사용할 때의 사용자 환경을 보완하는 기능이 추가되었습니다.

CJK 가변 글꼴

Android 15부터 한국어, 중국어, 일본어, 한국어 (CJK) 언어의 글꼴 파일 NotoSansCJK가 가변 글꼴로 변경됩니다. 가변 글꼴은 CJK 언어의 창의적인 서체를 위한 새로운 가능성을 열어줍니다. 디자이너는 더 광범위한 스타일을 탐색하고 이전에는 달성하기 어렵거나 불가능했던 시각적으로 눈에 띄는 레이아웃을 만들 수 있습니다.

한국어, 일본어, 중국어 (CJK) 언어의 변수 글꼴이 다양한 글꼴 너비로 표시되는 방식

문자 간 양쪽 맞춤

Android 15부터 JUSTIFICATION_MODE_INTER_CHARACTER를 사용하여 문자 간격을 사용하여 텍스트를 맞춤화할 수 있습니다. 단어 간 양쪽 맞춤은 Android 8.0 (API 수준 26)에서 처음 도입되었으며, 문자 간 양쪽 맞춤은 중국어, 일본어 등 세분화에 공백을 사용하는 언어에 유사한 기능을 제공합니다.

JUSTIFICATION_MODE_NONE를 사용한 일본어 텍스트의 레이아웃
JUSTIFICATION_MODE_NONE를 사용하는 영어 텍스트의 레이아웃


JUSTIFICATION_MODE_INTER_WORD를 사용한 일본어 텍스트의 레이아웃
JUSTIFICATION_MODE_INTER_WORD를 사용하는 영어 텍스트의 레이아웃


JUSTIFICATION_MODE_INTER_CHARACTER를 사용한 일본어 텍스트의 레이아웃
JUSTIFICATION_MODE_INTER_CHARACTER를 사용하는 영어 텍스트의 레이아웃

자동 줄바꿈 구성

Android 从 Android 13(API 级别 33)开始针对日语和韩语支持基于短语的换行符。不过,虽然基于短语的换行符可以提高短行文本的可读性,但不适用于较长的文本。在 Android 15 中,应用现在可以使用 LINE_BREAK_WORD_STYLE_AUTO 选项为短文本行应用基于短语的换行符。此选项用于选择最适合该文本的文字样式选项。

对于简短的文本行,使用基于短语的换行符,其功能与 LINE_BREAK_WORD_STYLE_PHRASE 相同,如下图所示:

对于简短的文本行,LINE_BREAK_WORD_STYLE_AUTO 会采用基于短语的换行符,以提高文本的可读性。 这与应用 LINE_BREAK_WORD_STYLE_PHRASE 相同。

对于较长的文本,LINE_BREAK_WORD_STYLE_AUTO 使用不换行的字词样式,其功能与 LINE_BREAK_WORD_STYLE_NONE 相同,如下图所示:

对于较长的文本,LINE_BREAK_WORD_STYLE_AUTO 不会应用换行字词样式,以提高文本的可读性。 这与应用 LINE_BREAK_WORD_STYLE_NONE 相同。

새로운 일본어 헨타이가나 글꼴

Android 15에서는 기존 일본 히라가나 (헨타이가나)의 새 글꼴 파일이 기본적으로 번들로 제공됩니다. 헨타이가나 캐릭터의 독특한 모양은 예술작품이나 디자인에 독특한 느낌을 더하는 동시에 고대 일본 문서를 정확하게 전달하고 이해하는 데도 도움이 됩니다.

일본어 헨타이가나 글꼴의 문자 및 텍스트 스타일

VideoLAN cone Copyright (c) 1996~2010 VideoLAN. 누구나 VideoLAN 프로젝트 또는 VideoLAN팀에서 개발한 제품을 언급하기 위해 이 로고 또는 수정된 버전을 사용하거나 수정할 수 있지만 프로젝트가 보증한다는 의미는 아닙니다.

Vulkan 및 Vulkan 로고는 Khronos Group Inc.의 등록 상표입니다.

OpenGL은 등록 상표이며 OpenGL ES 로고는 Khronos의 허가 하에 사용한 Hewlett Packard Enterprise의 상표입니다.