ARCore 效能重疊
透過集合功能整理內容
你可以依據偏好儲存及分類內容。
ARCore 可顯示重疊面板與應用程式的效能統計資料,例如:
CPU 和記憶體用量,提供系統資源的即時總覽。

請按照下列步驟啟用效能重疊功能。
請在應用程式中開啟 AR 體驗,以便系統正在執行 ARCore 工作階段
備用資源您的應用程式必須處於 AR 模式,才能接收會啟用該功能的廣播
重疊。必須能在裝置上看到 AR 相機預覽圖片
。
使用下列活動管理員廣播指令,即可啟用
效能重疊。
# Enables ARCore's performance overlay and saves a setting to your app's
# Android Shared Preferences, so that the overlay remains enabled in
# subsequent ARCore sessions.
# Your app must have an actively running ARCore session to receive the broadcast.
adb shell am broadcast -a com.google.ar.core.ENABLE_PERFORMANCE_OVERLAY
系統可能會將您導向「Settings」選單,讓你授予 ARCore 套件
繪製疊加層的權限。此步驟只需執行一次。尋找
請Google Play Services for AR,並將權限切換鈕設為「Allowed」
再返回應用程式
如果您在未授予 ARCore 的情況下啟用效能重疊功能
繪製重疊圖層的權限,系統會將您導向「設定」選單
。在這種情況下,您應該
授予 ARCore 權限,或停用效能重疊功能。
如要停用效能重疊,請按照下列步驟操作。
請在應用程式中開啟 AR 體驗,以便系統正在執行 ARCore 工作階段
備用資源應用程式必須處於 AR 模式,才能接收停用的廣播訊息
重疊。必須能在裝置上看到 AR 相機預覽圖片
。
使用下列活動管理員廣播指令,即可停用
效能重疊。
# Disables ARCore's performance overlay and saves a setting to your app's
# Android Shared Preferences, so that the overlay remains disabled in
# subsequent ARCore sessions.
# Your app must have an actively running ARCore session to receive the broadcast.
adb shell am broadcast -a com.google.ar.core.DISABLE_PERFORMANCE_OVERLAY
你也可以輕觸關閉按鈕,停用效能重疊功能
重疊且正在清除
的 Android 分享偏好設定。其中一種方法是清除應用程式的
資料。
解讀 CPU 用量值
Process CPU Usage 欄位會顯示
應用程式程序目前佔裝置總數的佔
可用的 CPU 作業時間這個值包括應用程式工作負載、ARCore 工作負載、
以及應用程式使用的任何其他程式庫例如,
如果應用程式程序完全耗盡單一 CPU 核心,則 CPU 使用率為 25%
也就是在 4 核心裝置上執行
效能覆蓋圖也提供個別的 CPU 使用率
ARCore 功能,這些細目也會以
裝置的可用 CPU 總作業時間工作負載如下:
疊加畫面不會顯示已停用或小於
0.1% 的 CPU 作業時間
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權,程式碼範例則為阿帕契 2.0 授權。詳情請參閱《Google Developers 網站政策》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2025-07-26 (世界標準時間)。
[null,null,["上次更新時間:2025-07-26 (世界標準時間)。"],[[["\u003cp\u003eARCore offers a performance overlay that displays real-time CPU and memory usage statistics for your app during AR experiences.\u003c/p\u003e\n"],["\u003cp\u003eTo enable or disable the overlay, use specific ADB commands while your app is actively running in AR mode.\u003c/p\u003e\n"],["\u003cp\u003eThe overlay requires permission to draw overlays, which can be granted in the device's settings for "Google Play Services for AR".\u003c/p\u003e\n"],["\u003cp\u003eCPU usage is shown as a percentage of total device CPU, including both app and ARCore processes, and further broken down by specific ARCore features like motion tracking and plane detection.\u003c/p\u003e\n"]]],[],null,["# ARCore performance overlay\n\nARCore can display an overlay panel with an app's performance statistics such as\nCPU and memory usage, providing a real-time overview of system resources.\n\nEnable the performance overlay\n------------------------------\n\nFollow these steps to enable the performance overlay.\n\n1. Open the AR experience in your app so that there is an active ARCore session\n running. **Your app must be in AR mode to receive the broadcast that enables\n the overlay.** The AR camera preview images should be visible on the device\n screen.\n\n2. Use the following activity manager broadcast command to enable the\n performance overlay for your app.\n\n # Enables ARCore's performance overlay and saves a setting to your app's\n # Android Shared Preferences, so that the overlay remains enabled in\n # subsequent ARCore sessions.\n\n # Your app must have an actively running ARCore session to receive the broadcast.\n adb shell am broadcast -a com.google.ar.core.ENABLE_PERFORMANCE_OVERLAY\n\n3. You may be directed to the **Settings** menu to grant the ARCore package\n permission to draw overlays. This step only needs to be performed once. Find\n **Google Play Services for AR** and set the permissions toggle to **Allowed**\n before navigating back to your app.\n\n If you have enabled the performance overlay without granting ARCore\n permission to draw overlays, you will be directed to the Settings menu each\n time the app begins a new ARCore session. In this case, you should either\n grant ARCore permission, or disable the performance overlay.\n\nDisable the performance overlay\n-------------------------------\n\nFollow these steps to disable the performance overlay.\n\n1. Open the AR experience in your app so that there is an active ARCore session\n running. **Your app must be in AR mode to receive the broadcast that disables\n the overlay.** The AR camera preview images should be visible on the device\n screen.\n\n2. Use the following activity manager broadcast command to disable the\n performance overlay for your app.\n\n # Disables ARCore's performance overlay and saves a setting to your app's\n # Android Shared Preferences, so that the overlay remains disabled in\n # subsequent ARCore sessions.\n\n # Your app must have an actively running ARCore session to receive the broadcast.\n adb shell am broadcast -a com.google.ar.core.DISABLE_PERFORMANCE_OVERLAY\n\nYou can also disable the performance overlay by tapping the close button\non the overlay and clearing\nyour app's Android Shared Preferences. One way to do this is to clear your app's\ndata.\n\nInterpreting CPU usage values\n-----------------------------\n\nThe **Process CPU Usage** field displays the amount of CPU time that the\napplication process currently uses as a percentage of the device's total\navailable CPU time. This value includes application workloads, ARCore workloads,\nand any other libraries that your app uses. For example, the field would display\n25% CPU usage if the application process fully saturates a single CPU core when\nrunning on a quad-core device.\n\nThe performance overlay also provides a CPU usage breakdown for individual\nARCore features. These breakdowns are also expressed as a percentage of the\ndevice's total available CPU time. The workloads are:\n\n- [Motion Tracking](/ar/discover/concepts#motion_tracking)\n- [Plane Detection](/ar/discover/concepts#environmental_understanding)\n\nThe overlay does not display any features that are disabled or using less than\n0.1% CPU time."]]