AGI STK Graphics 11 Send comments on this topic.
SetSizes Method (IAgStkGraphicsMarkerBatchPrimitiveOptionalParameters)
See Also  Example
Sizes
An array containing the size (in the order width, height) for each marker in the batch. There must be one width followed by one height for each position passed to the Marker Batch Primitive's Set or SetPartial method.





Description

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

Syntax

[Visual Basic .NET]
Public Sub SetSizes( _
   ByRef Sizes As System.Array _
) 

[C#]
public void SetSizes(
ref System.Array Sizes
);

[Managed C++]
public: void SetSizes(
System::Array ^^ Sizes
);

[Java]
public  setSizes(
Object[] Sizes
);

[Unmanaged C++]
public: HRESULT SetSizes(
SAFEARRAY ** Sizes
);

Parameters

Sizes
An array containing the size (in the order width, height) for each marker in the batch. There must be one width followed by one height for each position passed to the Marker Batch Primitive's Set or SetPartial method.

Remarks

To use user-defined per-marker sizes, the marker batch must be initialized with MarkerBatchSizeSource.UserDefined, otherwise each marker's size is it's texture's size.

The size may be interpreted to be pixels or meters depending on MarkerBatchPrimitive.SizeUnit.

Per-marker sizes override the per-batch size. Therefore, when per-marker sizes are defined with this method, MarkerBatchPrimitive.Size is not used.

Example

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

    256
    128
    128
    256 
}; 
 
IAgStkGraphicsMarkerBatchPrimitiveOptionalParameters parameters = sceneManager.Initializers.MarkerBatchPrimitiveOptionalParameters.Initialize(); 
parameters.SetSizes(ref size); 
 

Shows the format of the Sizes parameter when setting per marker sizes.
[Visual Basic .NET] Copy Code
Dim size As Array = New Object() {256, 128, 128, 256}

Dim parameters As IAgStkGraphicsMarkerBatchPrimitiveOptionalParameters = sceneManager.Initializers.MarkerBatchPrimitiveOptionalParameters.Initialize()
parameters.SetSizes(size)

See Also

© 2016 All Rights Reserved.

STK Programming Interface 11.0.1