Upgrade to Pro — share decks privately, control downloads, hide ads and more …

How to handle 3D content on Android XR

How to handle 3D content on Android XR

Android XR で3Dコンテンツを扱う方法
https://hey.connpass.com/event/358065/

Avatar for Akio Itaya

Akio Itaya

June 26, 2025
Tweet

More Decks by Akio Itaya

Other Decks in Programming

Transcript

  1. 1. ࠷ॳͷσόΠε͸ Samsung ͷ Project Moohan 2. Home SpaceɾFull Space

    ͱ͍͏2ͭͷϞʔυ 3. SceneCore ʹΑΔ Skybox ͱ຅ೖܕϏσΦ 4. glTFϑΝΠϧΛ࢖༻ͨ͠3DΦϒδΣΫτදࣔ 5. ARCore ʹΑΔӬଓΞϯΧʔͱϋϯυτϥοΩϯά Summary of the Session
  2. 1. ࠷ॳͷσόΠε͸ Samsung ͷ Project Moohan 2. Home SpaceɾFull Space

    ͱ͍͏2ͭͷϞʔυ 3. SceneCore ʹΑΔ Skybox ͱ຅ೖܕϏσΦ 4. glTFϑΝΠϧΛ࢖༻ͨ͠3DΦϒδΣΫτදࣔ 5. ARCore ʹΑΔӬଓΞϯΧʔͱϋϯυτϥοΩϯά Summary of the Session https://news.samsung.com/global/unlock-the-in fi nite-possibilities-of-xr-with-galaxy-ai ޖೠ / ແݶ
  3. 1. ࠷ॳͷσόΠε͸ Samsung ͷ Project Moohan 2. Home SpaceɾFull Space

    ͱ͍͏2ͭͷϞʔυ 3. SceneCore ʹΑΔ Skybox ͱ຅ೖܕϏσΦ 4. glTFϑΝΠϧΛ࢖༻ͨ͠3DΦϒδΣΫτදࣔ 5. ARCore ʹΑΔӬଓΞϯΧʔͱϋϯυτϥοΩϯά Summary of the Session https://developer.android.com/design/ui/xr/guides/foundations
  4. 1. ࠷ॳͷσόΠε͸ Samsung ͷ Project Moohan 2. Home SpaceɾFull Space

    ͱ͍͏2ͭͷϞʔυ 3. SceneCore ʹΑΔ Skybox ͱ຅ೖܕϏσΦ 4. glTFϑΝΠϧΛ࢖༻ͨ͠3DΦϒδΣΫτදࣔ 5. ARCore ʹΑΔӬଓΞϯΧʔͱϋϯυτϥοΩϯά Summary of the Session https://developer.android.com/design/ui/xr/guides/environments
  5. 1. ࠷ॳͷσόΠε͸ Samsung ͷ Project Moohan 2. Home SpaceɾFull Space

    ͱ͍͏2ͭͷϞʔυ 3. SceneCore ʹΑΔ Skybox ͱ຅ೖܕϏσΦ 4. glTFϑΝΠϧΛ࢖༻ͨ͠3DΦϒδΣΫτදࣔ 5. ARCore ʹΑΔӬଓΞϯΧʔͱϋϯυτϥοΩϯά Summary of the Session ࠓճͷ 
 ຊ୊
  6. 1. ࠷ॳͷσόΠε͸ Samsung ͷ Project Moohan 2. Home SpaceɾFull Space

    ͱ͍͏2ͭͷϞʔυ 3. SceneCore ʹΑΔ Skybox ͱ຅ೖܕϏσΦ 4. glTFϑΝΠϧΛ࢖༻ͨ͠3DΦϒδΣΫτදࣔ 5. ARCore ʹΑΔӬଓΞϯΧʔͱϋϯυτϥοΩϯά Summary of the Session https://io.google/2025/explore/technical-session-22
  7. @SuppressLint("RestrictedApi") @Composable fun MySpatialContent() { val session = checkNotNull(LocalSession.current) SpatialPanel()

    { LaunchedEffect(key1 = Unit) { val model = GltfModel.create(session, “models/girl.gltf") .await() var modelEntity = GltfModelEntity.create( session = session, model = model ) } } }
  8. @SuppressLint("RestrictedApi") @Composable fun MySpatialContent() { val session = checkNotNull(LocalSession.current) var

    modelEntity by remember { mutableStateOf<GltfModelEntity?>(null) } SpatialPanel() { LaunchedEffect(key1 = Unit) { val model = GltfModel.create(session, “models/girl.gltf") .await() modelEntity = GltfModelEntity.create( session = session, model = model ) } DisposableEffect(Unit) { onDispose { modelEntity?.dispose() } } } }
  9. @SuppressLint("RestrictedApi") @Composable fun MySpatialContent(onRequestHomeSpaceMode: () -> Unit) { val session

    = checkNotNull(LocalSession.current) var modelEntity by remember { mutableStateOf<GltfModelEntity?>(null) } SpatialPanel(SubspaceModifier.width(1280.dp).height(800.dp).resizable().movable()) { LaunchedEffect(key1 = Unit) { val model = GltfModel.create(session, "models/girl.gltf").await() val entity = GltfModelEntity.create( session = session, model = model, pose = Pose( translation = Vector3(0f, -0.5f, 0.2f), rotation = Quaternion.fromEulerAngles(Vector3(90f, 0f, 0f)) ) ) entity.setScale(0.5f) modelEntity = entity } DisposableEffect(Unit) { onDispose { modelEntity?.dispose() } } } }