STK Graphics PrimitivesSend comments on this topic.
ComputeWithHole Method (IAgStkGraphicsSurfacePolygonTriangulatorInitializer)
See Also
CentralBody
The central body to compute the triangulation on.
Positions
An array containing positions (in the order x, y, z) defining the boundary of the polygon, in the centralBody's fixed reference frame, to triangulate.
HolePositions
An array containing positions (in the order x, y, z) defining the hole in the polygon, in the centralBody's fixed reference frame.
Windows





Windows & Linux

Description

Computes the triangulation on the specified centralBody for a polygon whose boundary is defined by the specified positions with a hole specified by holePositions. This is equivalent to calling Compute with an altitude of 0 and a granularity of 1 degree.

Syntax

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

Parameters

CentralBody
The central body to compute the triangulation on.
Positions
An array containing positions (in the order x, y, z) defining the boundary of the polygon, in the centralBody's fixed reference frame, to triangulate.
HolePositions
An array containing positions (in the order x, y, z) defining the hole in the polygon, in the centralBody's fixed reference frame.

See Also

Example

Shows the format of the Positions and HolePositions parameters when computing using a surface polygon triangulator.
[C#]
Array positions = new object[]
{
    1097959.63, -5171334.09, 3556288,
    1007572.15, -5150349.71, 3612667.74,   
    978879.05, -5195164.23, 3556326.55,
    1037389.68, -5188523.96, 3549473.77,
    1097959.63, -5171334.09, 3556288
};

Array holePositions = new object[]
{
    1079859.69, -5169944.96, 3563791.24,
    1030755, -5179965.11, 3563781.97,   
    1028569.57, -5145251.03, 3614006.53,
    1039944.33, -5153880.71, 3598525.9,
    1027115.87, -5150522.49, 3606951.77,
    1026998.55, -5162243.13, 3590303.25,
    1079859.69, -5169944.96, 3563791.24
};

IAgStkGraphicsSurfaceTriangulatorResult result = sceneManager.Initializers.SurfacePolygonTriangulator.ComputeWithHole("Earth", ref positions, ref holePositions);
Shows the format of the Positions and HolePositions parameters when computing using a surface polygon triangulator.
[Visual Basic .NET]
Dim positions As Array = New Object() {1097959.63, -5171334.09, 3556288, 1007572.15, -5150349.71, 3612667.74, _
	978879.05, -5195164.23, 3556326.55, 1037389.68, -5188523.96, 3549473.77, _
	1097959.63, -5171334.09, 3556288}

Dim holePositions As Array = New Object() {1079859.69, -5169944.96, 3563791.24, 1030755, -5179965.11, 3563781.97, _
	1028569.57, -5145251.03, 3614006.53, 1039944.33, -5153880.71, 3598525.9, _
	1027115.87, -5150522.49, 3606951.77, 1026998.55, -5162243.13, 3590303.25, _
	1079859.69, -5169944.96, 3563791.24}

Dim result As IAgStkGraphicsSurfaceTriangulatorResult = sceneManager.Initializers.SurfacePolygonTriangulator.ComputeWithHole("Earth", positions, holePositions)
© 2024 Analytical Graphics, Inc. All Rights Reserved.