AugmenterBaseBehaviour Class

Description

AugmenterBaseBehaviour is the component to control Augmenter in the AR scene.

The object with AugmenterBaseBehaviour is the parent of RenderCameras, and the transform between Augmenter and tracked Target is controlled by EasyAR.

Public Types

enum CenterMode{Target, Augmenter}

Public Fields

Augmenter Augmenter
CenterMode WorldCenter
bool RenderReality (since 1.3.0)
ImageTargetBaseBehaviour CenterTarget (since1.3.0)

Public Functions

void Bind(CameraDeviceBaseBehaviour behaviour) (until 1.2.1)
void Bind(DeviceAbstractBehaviour behaviour) (since 1.3.0)
void UnBind(CameraDeviceBaseBehaviour behaviour) (until 1.2.1)

Public Events

event Action<AugmenterBaseBehaviour, Frame> FrameUpdate
event Action<AugmenterBaseBehaviour, Texture2D> PlaneTextureCreated
event Action<AugmenterBaseBehaviour, ImageTargetBaseBehaviour, Target> TargetFound (since 1.3.0)
event Action<AugmenterBaseBehaviour, ImageTargetBaseBehaviour, Target> TargetLost (since 1.3.0)
event Action<AugmenterBaseBehaviour, string> TextMessage (since 1.3.0)

Overwritten MonoBahaviour Functions

protected virtual void Awake()
protected virtual void OnDestroy()
protected virtual void Start()
protected virtual void Update() (since 1.3.0)

enum CenterMode

Constant

Value

Description

Target (until 1.2.1)
FirstTarget (since 1.3.0)

0

The AR scene will use the first tracked target as centered. You can move or rotate the target and the Augmenter will follow. You cannot manually change the Augmenter's transform in this mode. The relative transform from Target to Augmenter is controlled by EasyAR.

../_images/image111.png ../_images/image121.png

Augmenter

1

The AR scene is augmenter centered. You can move or rotate the augmenter and the Target will follow. You cannot manually change the Target's transform in this mode. The relative transform from Target to Augmenter is controlled by EasyAR.

../_images/image131.png ../_images/image141.png

SpecificTarget (since 1.3.0)

2

The AR scene will use the target specified by CenterTarget as centered. If the specified target is not found, will fall back to Augmenter center mode.The relative transform from Target to Augmenter is controlled by EasyAR.

Augmenter Augmenter

The Augmenter object. You can reach advanced controls with Augmenter. See Augmenter for more details.

CenterMode WorldCenter

The AR world center. It can be changed on the fly. See CenterMode for more details.

bool RenderReality

Flag to render or disalble reality plane. Camera background will stop to display is set to false.

ImageTargetBaseBehaviour CenterTarget

Centered target when WorldCenter is target.

void Bind(CameraDeviceBaseBehaviour behaviour) (until 1.2.1)

void Bind(DeviceAbstractBehaviour behaviour) (since 1.3.0)

Binds CameraDeviceBaseBehaviour. It is used for building AR scene. AugmenterBaseBehaviour must be bind to a CameraDeviceBaseBehaviour before all functions work.

void UnBind(CameraDeviceBaseBehaviour behaviour) (until 1.2.1)

Unbind CameraDeviceBaseBehaviour.

event Action<AugmenterBaseBehaviour, Frame> FrameUpdate

Event for a frame update. You can get a Frame and its underlying data like the tracked target or current image of the frame. The image inside the frame is synchronized with the RealityPlane. See Frame for more details.

event Action<AugmenterBaseBehaviour, Texture2D> PlaneTextureCreated

Event for the creation of RealityPlane texture.

event Action<AugmenterBaseBehaviour, ImageTargetBaseBehaviour, Target> TargetFound (since 1.3.0)

Target found event. All targets found will be evented here.

event Action<AugmenterBaseBehaviour, ImageTargetBaseBehaviour, Target> TargetLost (since 1.3.0)

Target lost event. All targets lost will be evented here.

event Action<AugmenterBaseBehaviour, string> TextMessage (since 1.3.0)

Text message get event. QRCode message will be evented here.