Google.XR.Cardboard.Api

CardboardXR Plugin API.

Summary

Properties

IsCloseButtonPressed
static bool
Gets a value indicating whether the close button is pressed this frame.
IsGearButtonPressed
static bool
Gets a value indicating whether the gear button is pressed this frame.
IsTriggerPressed
static bool
Gets a value indicating whether the Cardboard trigger button is pressed this frame.

Public static functions

HasDeviceParams()
bool
Evaluates whether or not device params are saved in the storage.
HasNewDeviceParams()
bool
Evaluates if device parameters changed from last time they were reloaded.
ReloadDeviceParams()
void
Enables device parameter reconfiguration on next frame update.
ScanDeviceParams()
void
Starts QR Code scanning activity.
UpdateScreenParams()
void
Updates screen parameters.

Properties

IsCloseButtonPressed

static bool IsCloseButtonPressed

Gets a value indicating whether the close button is pressed this frame.

IsGearButtonPressed

static bool IsGearButtonPressed

Gets a value indicating whether the gear button is pressed this frame.

IsTriggerPressed

static bool IsTriggerPressed

Gets a value indicating whether the Cardboard trigger button is pressed this frame.

Public static functions

HasDeviceParams

bool HasDeviceParams()

Evaluates whether or not device params are saved in the storage.

Details
Returns
Whether or not device parameters are found.

HasNewDeviceParams

bool HasNewDeviceParams()

Evaluates if device parameters changed from last time they were reloaded.

Details
Returns
true when device parameters changed.

ReloadDeviceParams

void ReloadDeviceParams()

Enables device parameter reconfiguration on next frame update.

ScanDeviceParams

void ScanDeviceParams()

Starts QR Code scanning activity.

UpdateScreenParams

void UpdateScreenParams()

Updates screen parameters.

This method must be called at framerate to ensure the safe area is properly taken into account on iOS devices.

Note: This method is a workaround for Issue #1288515 in Unity.