Skip to content

ARCore SDK for Android v1.31.0

Compare
Choose a tag to compare
@jeremyvc jeremyvc released this 11 May 18:45

Breaking & behavioral changes

  • Updated ARCore's minimum supported Android API level to 19 (from 18).
    • The upcoming Android NDK version (r24) will remove support for Android API levels v16-18.
    • For more information, see the Android NDK r23 changelog.

New APIs and capabilities

ARCore Geospatial API - new

The new ARCore Geospatial API utilizes data from Google Earth 3D models and Street View image data from Google Maps to enable your app for immersive, global-scale, location-based augmented reality experiences.

  • Kotlin/Java reference

    • Earth provides localization ability in geospatial coordinates.
      • Earth.createAnchor() creates a new Anchor at the specified latitude, longitude, altitude, and orientation.
    • Earth.Earthstate describes the current state of Earth, including its TrackingState.
    • GeospatialPose describes a specific latitude, longitude, altitude, and compass heading.
  • C reference

    • ArEarth provides localization ability in geospatial coordinates.
      • ArEarth_acquireNewAnchor() creates a new Anchor at the specified latitude, longitude, altitude, and orientation.
      • ArEarthState describes the current state of ArEarth, including its ArTrackingState.
    • ArGeospatialPose describes a specific latitude, longitude, altitude, and compass heading.

ARCore Depth API improvements

The maximum range of Depth measurements has increased from 8191mm to 65535mm when building with ARCore SDK 1.31 and later. The Depth API now uses all 16-bits to represent depth, where previously only 13 bits were used for depth values.

To reflect this change in behavior, some Depth API functions have new names and behavior changes. The old versions of these functions will have no change in behavior, though it is recommended to make use of the longer depth range. For more information, see ARCore Depth changes in ARCore 1.31.

  • Kotlin/Java
    • The Depth API function calls have changed:
      • Frame.acquireDepthImage() has been deprecated in favor of Frame.acquireDepthImage16Bits().
      • Frame.acquireRawDepthImage() has been deprecated in favor of Frame.acquireRawDepthImage16Bits().
      • The output image formats for both calls have changed from
        android.graphics.ImageFormat.DEPTH16 to
        android.hardware.HardwareBuffer.D_16.
      • Depth is still represented as a 16-bit integer in units of
        millimeters, but now all 16-bits are used to represent depth, allowing
        for a maximum expressible range of 65535mm (previously 8191mm).
  • C
    • The Depth API function calls have changed:
      • ArFrame_acquireDepthImage() has been deprecated in favor of ArFrame_acquireDepthImage16Bits().
      • ArFrame_acquireRawDepthImage() has been deprecated in favor of ArFrame_acquireRawDepthImage16Bits().
      • The output image formats for both calls have changed from AR_IMAGE_FORMAT_DEPTH16 to AR_IMAGE_FORMAT_D_16.
      • Depth is still represented as a 16-bit integer in units of
        millimeters, but now all 16-bits are used to represent depth, allowing
        for a maximum expressible range to go 65535mm (previously 8191mm).

Deprecations

  • Kotlin/Java

    • The Depth API function calls Frame.acquireDepthImage() and
      Frame.acquireRawDepthImage() are deprecated. Please use
      Frame.acquireDepthImage16Bits() and Frame.acquireRawDepthImage16Bits()
      instead.
  • C

    • The Depth API function calls ArFrame_acquireDepthImage() and
      ArFrame_acquireRawDepthImage() are deprecated. Please use
      ArFrame_acquireDepthImage16Bits() and
      ArFrame_acquireRawDepthImage16Bits() instead.

Known issues

  • Configuring a session with GeospatialMode.ENABLED while the session is running may cause the session to hang. This issue will be resolved in Google Play Services for AR (ARCore) version 1.32. In the meantime, ensure your app only sets a configuration with GeospatialMode.ENABLED while the session is paused.

Other changes

  • HelloAR sample apps now visualize the Depth API representing longer-range
    depth values with new colors.