STK Graphics PrimitivesSend comments on this topic.
TryCartographicToWindow Method (IAgStkGraphicsCamera)
See Also
CentralBody
The Central Body of the position.
Position
An array containing the Cartographic position to convert, provided in the order latitude, longitude, altitude.
Windows





Windows & Linux

Description

Converts a Cartographic position to a pixel coordinate relative to the globe control. This method does not throw an exception.

Syntax

[Visual Basic .NET]
Public Function TryCartographicToWindow( _
    ByVal CentralBody As String, _
    ByVal Position As System.Array _
) As System.Array
[C#]
public System.Array TryCartographicToWindow(
    string CentralBody,
    System.Array Position
);
[Managed C++]
public: System::Array TryCartographicToWindow(
    String __gc ^ CentralBody,
    System::Array ^ Position
);
[Unmanaged C++]
public: HRESULT TryCartographicToWindow(
    BSTR CentralBody,
    SAFEARRAY * * Position,
    SAFEARRAY * * ppRetVal
);
[Java]
public AgSafeArray tryCartographicToWindow(
    String CentralBody,
    AgSafeArray Position
);
[Python - STK API ]
def TryCartographicToWindow(self, CentralBody:str, Position:list) -> list:

Parameters

CentralBody
The Central Body of the position.
Position
An array containing the Cartographic position to convert, provided in the order latitude, longitude, altitude.

See Also

Example

Shows the format of the Position parameter when converting a cartogaphic position to a pixel coordinate.
[C#]
Array position = new object[]
{
    0.627,
    -1.644,
    0
};
Array windowPos = scene.Camera.CartographicToWindow(
    "Earth", 
    ref position);
Shows the format of the Position parameter when converting a cartogaphic position to a pixel coordinate.
[Visual Basic .NET]
Dim position As Array = New Object() {0.627, -1.644, 0}

Dim windowPos As Array = scene.Camera.CartographicToWindow("Earth", position)
© 2024 Analytical Graphics, Inc. All Rights Reserved.