setCameraProps

Column
promise
Tags
카메라 설정값 셋팅 (360도 영상)

setCameraProps

setCameraProps(cameraProps: object): Promise<object, (RangeError|Error)>
카메라 설정값 셋팅 (360도 영상)
 

params

cameraProps
{
"yaw" : 0 ~ 360 사이 값 (왼쪽 오른쪽)
"pitch" : -90 ~ 90 사이 값 (위 아래)
"roll" : -180 ~ 180 사이 값
"fov" : The field of view in degrees.
}

함수 예시

player.setCameraProps({ "yaw": 360, "pitch": 90, "roll": 180, "fov": 45 })
player.setCameraProps({ "yaw": 360, // 좌우 값 "pitch": 90, // 상하 값 "roll": 180, // Number between -180 and 180. "fov": 45 // The field of view in degrees. }).then((cameraProps)=>{ // cameraProps 설정 완료된 경우 }).catch((error)=>{ switch (error.name) { case 'RangeError': // one of the camera properties is out of range break; default: // some other error occurred break; } });