LinkPosition

Links the display in the 3D Window owning this SGWorld80 object to the display in a target 3D Window. Whichever window currently has the input focus determines the display in both windows, taking into account whatever offsets are set in this method.

 

JavaScript

 

LinkPosition(

       target,

       OffsetX,

       OffsetY,

       OffsetAltitude,

       OffsetYaw,

       OffsetPitch,

       LinkFlags)

 

C#

 

void LinkPosition(

       object target,

       double OffsetX = 0,

       double OffsetY = 0,

       double OffsetAltitude = 0,

       double OffsetYaw = 0,

       double OffsetPitch = 0,

       LinkPositionFlags LinkFlags = LinkPositionFlags.LP_NONE)

 

C++

 

HRESULT LinkPosition(

       VARIANT target,

       double OffsetX,

       double OffsetY,

       double OffsetAltitude,

       double OffsetYaw,

       double OffsetPitch,

       LinkPositionFlags LinkFlags)

Parameters

target

An ISGWorld80 object.

OffsetX

The offset, in meters, on the x-axis of the 3D Window owning this SGWorld80 object from the target window (passed in the first parameter).

OffsetY

The offset, in meters, on the y-axis of the 3D Window owning this SGWorld80 object from the target window (passed in the first parameter).

OffsetAltitude

The offset, in meters, of the altitude of the 3D Window owning this SGWorld80 object from the target window (passed in the first parameter).

OffsetYaw

The offset, in degrees, of the yaw (direction angle along the vertical axis relative to north) of the 3D Window owning this SGWorld80 object from the target window (passed in the first parameter).

OffsetPitch

The offset, in degrees, of the pitch (tilt angle) of the 3D Window owning this SGWorld80 object from the target window (passed in the first parameter).

LinkFlags

An enum that determines the position linking relationship of the linked 3D Windows by defining how some of the offset parameters should be applied. The LinkFlags enum can contain any combination of the following values:

·          LP_NONE = 0
All offset parameters are treated as offsets from the target 3D Window passed in the first parameter.

·          LP_ABSOLUTE_ALTITUDE = 1
When set, this flag indicates that the OffsetAltitude parameter should be used as a constant absolute altitude of the linked window, and not as an offset. Setting an absolute altitude allows the linked windows to show the same geographical area as the leader, but at independent altitudes.

·          LP_ABSOLUTE_YAW = 2
When set, this flag indicates that the OffsetYaw parameter should be used as a constant yaw value of the linked window, and not as an offset. Setting an absolute yaw allows the linked windows to show the same geographical area as the leader, while looking to a different direction.

·          LP_ABSOLUTE_PITCH = 4
When set, this flag indicates that the OffsetPitch parameter should be used as a constant pitch value of the linked window, and not as an offset. Setting an absolute pitch allows the linked windows to show the same geographical area as the leader, while looking down at different angles.

·          LP_FACTOR_ALTITUDE = 2048
When set, this flag indicates that the OffsetAltitude parameter should be used as a factor of the altitude of the linked window, and not as an offset. Setting a factor altitude allows the linked windows to show the same geographical area as the leader, but at different altitudes.

·          LP_FOLLOWER_ONLY = 4096
When set, the 3D Window owning this SGWorld80 object can follow the target 3D Window but it cannot act as a leader of the target 3D Window. If the selected window is SetAsLeader (i.e., it has the user input focus), the client can update position in the 3D Window but the linked window will not be affected.

Exceptions

See: HRESULT Return Values for a list of possible values returned by the HRESULT.