utility
Header:#include "easyar/utility.hpp"

Public Functions

Matrix44FgetProjectionGL(const CameraCalibration& calib, float nearPlane, float farPlane)
Matrix44FgetPoseGL(const Matrix34F& pose)
boolinitialize(const char* key)
voidonResume()
voidonPause()
voidsetRotationIOS(int rotation)
voidsetRotation(int rotation) (since 1.3.0)
const char*versionString()

Matrix44F getProjectionGL(const CameraCalibration& calib, float nearPlane, float farPlane)

Gets projections matrix from calibration data and clip planes.

Matrix44F getPoseGL(const Matrix34F& pose)

Gets OpenGL matrix from the pose.

bool initialize(const char* key)

Initializes EasyAR with key. This function is used in Windows, Mac and iOS. For Android, you should use java method EasyAR.initialize. EasyAR must be initialized before other functions start to work.

void onResume()

Handles the app onResume, resumes internal tasks.

void onPause()

Handles the app onPause, pauses internal tasks.

void setRotationIOS(int rotation)

Sets iOS view rotation. You should call this functions only in iOS to handle view rotation.

Orientationinput value
UIInterfaceOrientationPortrait270
UIInterfaceOrientationPortraitUpsideDown90
UIInterfaceOrientationLandscapeLeft180
UIInterfaceOrientationLandscapeRight0

void setRotation(int rotation) (since 1.3.0)

Sets rotation for all platforms.

Orientationinput value
UIInterfaceOrientationPortrait270
UIInterfaceOrientationPortraitUpsideDown90
UIInterfaceOrientationLandscapeLeft180
UIInterfaceOrientationLandscapeRight0

const char* versionString()

Returns EasyAR version string.