AGI STK Graphics 11 Send comments on this topic.
SetTextures Method (IAgStkGraphicsMarkerBatchPrimitiveOptionalParameters)
See Also  Example
Textures
An array containing a Texture 2D for each marker in the batch. There must be one texture for each position passed to the Marker Batch Primitive's Set or SetPartial method.





Description

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

Syntax

[Visual Basic .NET]
Public Sub SetTextures( _
   ByRef Textures As System.Array _
) 

[C#]
public void SetTextures(
ref System.Array Textures
);

[Managed C++]
public: void SetTextures(
System::Array ^^ Textures
);

[Java]
public  setTextures(
Object[] Textures
);

[Unmanaged C++]
public: HRESULT SetTextures(
SAFEARRAY ** Textures
);

Parameters

Textures
An array containing a Texture 2D for each marker in the batch. There must be one texture for each position passed to the Marker Batch Primitive's Set or SetPartial method.

Remarks

Per-marker textures override the per-batch texture. Therefore, when per-marker textures are defined with this method, MarkerBatchPrimitive.Texture is not used.

Example

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

    sceneManager.Textures.LoadFromStringUri(texturePath1), 
    sceneManager.Textures.LoadFromStringUri(texturePath2), 
    sceneManager.Textures.LoadFromStringUri(texturePath3), 
    sceneManager.Textures.LoadFromStringUri(texturePath4) 
}; 
 
IAgStkGraphicsMarkerBatchPrimitiveOptionalParameters parameters = sceneManager.Initializers.MarkerBatchPrimitiveOptionalParameters.Initialize(); 
parameters.SetTextures(ref textures); 
 

Shows the format of the Textures parameter when setting per marker textures.
[Visual Basic .NET] Copy Code
Dim textures As Array = New Object() {sceneManager.Textures.LoadFromStringUri(texturePath1), sceneManager.Textures.LoadFromStringUri(texturePath2), sceneManager.Textures.LoadFromStringUri(texturePath3), sceneManager.Textures.LoadFromStringUri(texturePath4)}

Dim parameters As IAgStkGraphicsMarkerBatchPrimitiveOptionalParameters = sceneManager.Initializers.MarkerBatchPrimitiveOptionalParameters.Initialize()
parameters.SetTextures(textures)

See Also

© 2016 All Rights Reserved.

STK Programming Interface 11.0.1