AGI STK Graphics 11 Send comments on this topic.
SetOrigins Method (IAgStkGraphicsMarkerBatchPrimitiveOptionalParameters)
See Also  Example
Origins
An array containing a Origin element for each marker in the batch. There must be one origin for each position passed to the Marker Batch Primitive's Set or SetPartial method.





Description

Defines a collection of origins, one for each marker in the batch.

Syntax

[Visual Basic .NET]
Public Sub SetOrigins( _
   ByRef Origins As System.Array _
) 

[C#]
public void SetOrigins(
ref System.Array Origins
);

[Managed C++]
public: void SetOrigins(
System::Array ^^ Origins
);

[Java]
public  setOrigins(
Object[] Origins
);

[Unmanaged C++]
public: HRESULT SetOrigins(
SAFEARRAY ** Origins
);

Parameters

Origins
An array containing a Origin element for each marker in the batch. There must be one origin for each position passed to the Marker Batch Primitive's Set or SetPartial method.

Remarks

The origin defines where the marker is placed relative to its position.

Per-marker origins override the per-batch origin. Therefore, when per-marker origins are defined with this method, MarkerBatchPrimitive.Origin is not used.

Example

Shows the format of the Origins parameter when setting per marker origins.
[C#] Copy Code
Array origins = new object[] 

    AgEStkGraphicsOrigin.eStkGraphicsOriginCenter, 
    AgEStkGraphicsOrigin.eStkGraphicsOriginBottomLeft, 
    AgEStkGraphicsOrigin.eStkGraphicsOriginBottomRight, 
    AgEStkGraphicsOrigin.eStkGraphicsOriginTopLeft 
}; 
 
IAgStkGraphicsMarkerBatchPrimitiveOptionalParameters parameters = sceneManager.Initializers.MarkerBatchPrimitiveOptionalParameters.Initialize(); 
parameters.SetOrigins(ref origins); 
 

Shows the format of the Origins parameter when setting per marker origins.
[Visual Basic .NET] Copy Code
Dim origins As Array = New Object() {AgEStkGraphicsOrigin.eStkGraphicsOriginCenter, AgEStkGraphicsOrigin.eStkGraphicsOriginBottomLeft, AgEStkGraphicsOrigin.eStkGraphicsOriginBottomRight, AgEStkGraphicsOrigin.eStkGraphicsOriginTopLeft}

Dim parameters As IAgStkGraphicsMarkerBatchPrimitiveOptionalParameters = sceneManager.Initializers.MarkerBatchPrimitiveOptionalParameters.Initialize()
parameters.SetOrigins(origins)

See Also

© 2016 All Rights Reserved.

STK Programming Interface 11.0.1