fsCameraRequestCameraWorldLocker

The fsCameraRequestCameraWorldLocker function can be used to set a locker in the world to load the terrain, scenery and objects around it, but only if you have acquired the camera first. This is useful if you wish to move the camera far from the user aircraft where the world data may have been unloaded from memory.

IMPORTANT! World lockers are performance heavy, and as such should be used with care and released as soon as possible.

 

Syntax
bool fsCameraRequestCameraWorldLocker(
    FsVec3d lockerPosition,
    FsPositionReferential referential,
    FsSimObjId objectId
    );

 

Members
Parameters Description
lockerPosition A 3 value vector (x, y, z) defining the position of the camera. The units and values returned will depend of the selected referential.
referential

The reference used to define the lockerPosition value. One of the following:

  1. SimObject - The position is an offset from the simobject position (expressed in meters).
  2. SimObject Datum - The position is an offset from the simobject Datum Reference Point (expressed in meters).
  3. Eyepoint - The position is an offset from the aircraft pilot eyepoint (expressed in meters).
  4. World - The position is expressed using latitude, longitude, and altitude.
objectId

Ignored if is referential set to World.

The object Id of the simobject that will be used to set position by SimObject, SimObject Datum and Eyepoint referential.

Set to 0 to focus user's aircraft. If the object Id is invalid, user's aircraft will be used instead.

 

Return Values

The function returns false if it was not possible to setup a locker. If the request was sent but failed, the callback specified through fsCameraSubscribeToCameraWorldLockerStatusUpdate will be invoked with an appropriate value.

 

Remarks

N/A

 

Related Topics

  1. WebAssembly
  2. Camera API

0/255