DeviceInfo
Get information of current device.
| Type | Name | Interface Description |
|---|---|---|
| Static Functions | getCameraFacingType(): number | • Function: Gets the camera facing type of the device. Returns The camera facing type identifier. |
| Static Functions | getDeviceCameraResolution(): Vector2f | • Function: Get the resolution of the device camera input texture. |
| Static Functions | getOS(): OS | • Function: Gets the operating system of the current device. Returns The operating system type of the device. |
Use Case
@component()
export class NewBehaviourScript extends APJS.BasicScriptComponent {
onStart() {
// TODO: instantiate / use DeviceInfo here
}
onUpdate(deltaTime: number) {
}
}