Config

public class Config

Holds settings that are used to configure the session.

Nested Classes

enum Config.LightEstimationMode Select the behavior of the lighting estimation subsystem. 
enum Config.PlaneFindingMode Select the behavior of the plane detection subsystem. 
enum Config.UpdateMode Selects the behavior of update()

Public Constructors

Config(Session session)
Constructs a sensible default configuration.

Protected Constructors

Config()
(FOR TESTING) Constructs a new instance for use as a mock.

Public Methods

Config.LightEstimationMode
getLightEstimationMode()
Returns the currently configured lighting estimation mode.
Config.PlaneFindingMode
getPlaneFindingMode()
Returns the currently configured plane finding mode.
Config.UpdateMode
getUpdateMode()
Returns the currently configured behavior of update().
void
setLightEstimationMode(Config.LightEstimationMode lightEstimationMode)
Sets the lighting estimation mode that should be used.
void
setPlaneFindingMode(Config.PlaneFindingMode planeFindingMode)
Sets the plane finding mode that should be used.
void
setUpdateMode(Config.UpdateMode updateMode)
Sets the behavior of update().

Inherited Methods

Public Constructors

public Config (Session session)

Constructs a sensible default configuration. Plane detection and lighting estimation are enabled, and blocking update is selected. This configuration is guaranteed to be supported on all devices that support ARCore.

Parameters
session

Protected Constructors

protected Config ()

(FOR TESTING) Constructs a new instance for use as a mock. Calling any base method implementation on this instance may return unexpected results, throw an exception, or even crash.

To create a Config normally, use Config(Session).

Public Methods

public Config.LightEstimationMode getLightEstimationMode ()

Returns the currently configured lighting estimation mode.

public Config.PlaneFindingMode getPlaneFindingMode ()

Returns the currently configured plane finding mode.

public Config.UpdateMode getUpdateMode ()

Returns the currently configured behavior of update().

public void setLightEstimationMode (Config.LightEstimationMode lightEstimationMode)

Sets the lighting estimation mode that should be used. See the Config.LightEstimationMode enum for available options.

Parameters
lightEstimationMode The lighting estimation mode to select.

public void setPlaneFindingMode (Config.PlaneFindingMode planeFindingMode)

Sets the plane finding mode that should be used. See the Config.PlaneFindingMode enum for available options.

Parameters
planeFindingMode The plane finding mode to select.

public void setUpdateMode (Config.UpdateMode updateMode)

Sets the behavior of update(). See the Config.UpdateMode enum for available options.

Parameters
updateMode The behavior to select.

Send feedback about...