API Reference

Class List

pc.VrManager

Manage and update pc.VrDisplays that are attached to this device.

Summary

Static Properties

isSupportedReports whether this device supports the WebVR API
usesPolyfillReports whether this device supports the WebVR API using a polyfill

Properties

displayThe default pc.VrDisplay to be used.
displaysThe list of pc.VrDisplays that are attached to this device
isSupportedReports whether this device supports the WebVR API
usesPolyfillReports whether this device supports the WebVR API using a polyfill

Methods

destroyRemove events and clear up manager
pollCalled once per frame to poll all attached displays

Events

displayconnectFired when an VR display is connected
displaydisconnectFired when an VR display is disconnected

Details

Static Properties

isSupportedReports whether this device supports the WebVR API
usesPolyfillReports whether this device supports the WebVR API using a polyfill

Constructor

VrManager(app)

Manage and update pc.VrDisplays that are attached to this device.

Parameters

apppc.ApplicationThe main application

Properties

pc.VrDisplaydisplay

The default pc.VrDisplay to be used. Usually the first in the `displays` list

pc.VrDisplay[]displays

The list of pc.VrDisplays that are attached to this device

BooleanisSupported

Reports whether this device supports the WebVR API

BooleanusesPolyfill

Reports whether this device supports the WebVR API using a polyfill

Methods

destroy()

Remove events and clear up manager

poll()

Called once per frame to poll all attached displays

Events

displayconnect

Fired when an VR display is connected

Parameters

displaypc.VrDisplayThe pc.VrDisplay that has just been connected

displaydisconnect

Fired when an VR display is disconnected

Parameters

displaypc.VrDisplayThe pc.VrDisplay that has just been disconnected