HERE Android SDK Developer's Guide

ar

The package ar is a member of com.here.android.mpa.

Package Summary

ar

The AR package provides classes, interfaces and enumerations for displaying LiveSight and customizing the experience.

Package Details

The AR package provides classes, interfaces and enumerations for displaying LiveSight and customizing the experience.

Some key classes and interfaces in this package are:

CompositeFragment

The CompositeFragment class is a UI fragment that can be embedded into an activity to render both the Map and LiveSight. It is composite because it provides Map functionality (such as that provided by MapFragment) as well as LiveSight functionality. The fragment can be embedded as follows:


 <fragment
      class="com.here.android.mpa.ar.CompositeFragment"
      android:id="@+id/compositefragment"
      android:layout_width="fill_parent"
      android:layout_height="fill_parent" />
  

The ARController can be retrieved from the CompositeFragment by way of the getARController() API.

ARController

The ARController serves as a facade for LiveSight functionality. It contains methods and callbacks for controlling and customizing LiveSight behavior. Some key APIs are:

  • start() - Start LiveSight, transition from Map mode to LiveSight mode
  • stop() - Stop LiveSight, transition from LiveSight mode to Map mode
  • addARObject(ARObject) - Add content to LiveSight
  • press(PointF) - Return ARObject at PointF and render to simulate pressing

ARIconObject

The ARIconObject is a concrete ARObject which represents the LiveSight object model. It is composed of Front, Down and Back icons, an info icon and a GeoCoordinate representing the objects position.

For more information on using this feature, please consult the "LiveSight" section in the HERE SDK for Android Developer's Guide.