AGI STK Esri Display 11 Send comments on this topic.
IAgEsri3dRendererContext Interface

Description

Context used to instantiate COM components in COM apartment.

Public Methods

Public Method CreateObject Creates an instance of a component in the GIS thread.
Public Method LoadObject Loads an instance of a component in the GIS thread from a object.
Public Method SaveObject Saves an instance of a component into a object in the GIS thread.

Remarks

The AgEsri3dRendererContext object gives you access to the GIS thread and apartment. This is the only object exposed by the library living in the GIS thread.

The IAgEsri3dRendererContext interface has a number of methods for helping you manage the objects you create within the GIS thread. The following is a description of how and when you would use these methods:

CreateObject

Use this method when you need to create an object in the GIS thread.

CreateObject will return a proxy to the object that is in the GIS context. Your application can make use of the proxy as if the object was created locally within its current thread. If you call a method on the proxy that hands back another object, that object will actually be in the GIS context and your application will be handed back a proxy to that object. If you get a point from the point collection using IPointCollection::Point(), the point returned will be in the same context as the point collection.

If you add a point to the point collection using IPointCollection::AddPoint(), the point should be in the same context as the point collection.

SaveObject, LoadObject

These methods allow you to serialize objects in the GIS thread, then deserialize them back into objects. Any object that supports IPersistStream can be saved and loaded using these methods. These methods allow you to copy objects between apartments.

CoClasses that Implement IAgEsri3dRendererContext

© 2016 Analytical Graphics, Inc. All Rights Reserved.

STK Programming Interface 11.0.1