程式碼範例總覽
透過集合功能整理內容
你可以依據偏好儲存及分類內容。
GitHub 上的 Android 版 Maps 3D SDK 存放區提供一系列範例應用程式,協助您入門並探索 SDK 的功能。存放區分為兩個模組:
Maps3DSamples/ApiDemos:這個模組使用 Kotlin 和 Android Views 展示基本 API 功能。這是瞭解地圖例項化、相機操控和新增各種地圖物件等核心概念的絕佳起點。
Maps3DSamples/advanced:
如果您使用 Jetpack Compose,這個範例會示範如何將 Maps 3D SDK for Android 整合至宣告式 UI。這項功能會運用輔助類別,將 SDK 以 View 為基礎的架構與 Compose 連結,提供更現代化的方法,以 3D 地圖建構 UI。
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權,程式碼範例則為阿帕契 2.0 授權。詳情請參閱《Google Developers 網站政策》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2025-08-31 (世界標準時間)。
[null,null,["上次更新時間:2025-08-31 (世界標準時間)。"],[],[],null,["# Code samples overview\n\nThe [Maps 3D SDK for Android repository on\nGitHub](https://github.com/googlemaps-samples/android-maps3d-samples)\nprovides a collection of sample apps to help you get started and explore the\ncapabilities of the SDK. The repository is organized into two modules:\n\n- [Maps3DSamples/ApiDemos](https://github.com/googlemaps-samples/android-maps3d-samples/tree/main/Maps3DSamples/ApiDemos):\n This module showcases the fundamental API features using Kotlin and Android\n Views. It's a great starting point to understand core concepts like map\n instantiation, camera manipulation, and adding various map objects.\n\n- [Maps3DSamples/advanced](https://github.com/googlemaps-samples/android-maps3d-samples/tree/main/Maps3DSamples/advanced):\n For developers using Jetpack Compose, this sample demonstrates how to\n integrate the Maps 3D SDK for Android into a declarative UI. It utilizes helper\n classes to bridge the SDK's View-based architecture with Compose, offering a\n more modern approach to building UIs with 3D maps."]]