STK Graphics Primitives Library

These overviews introduce core areas of Graphics Primitives Library and provide code examples. In addition to reading the overviews, run the GraphicsHowTo application to see code examples in action.

Topic Description
Globe Overlays Overlays are used to render and organize terrain and imagery on a globe. Overlays can be layered and turned on/off based on the camera's altitude or current animation time. Both JPEG 2000 (.jp2) and AGI's image format (.pdttx) are supported. For terrain, AGI's terrain format (.pdtt) is supported. In addition, overlays can use web imagery from OpenStreetMap and WMS-C servers.

Overlays are efficiently drawn using an out-of-core rendering algorithm based on recent computer graphics research.
Primitives Primitives form the building blocks of a 3D scene. STK Engine provides a wide array of primitives, such as simple primitives to draw points and polylines to more advanced primitives for drawing entire models, ellipsoids, or polygons that conform to terrain. Primitives are optimized for both static and dynamic data, as primitives are commonly positioned and oriented based on computations that change over time. Primitives can be turned on/off based on the camera's altitude, distance to camera, pixel size, or current animation time. Composite primitives group primitives together to create hierarchies of primitives for efficient rendering, layering, and aggregation/deaggregation.

Primitives are organized in a bounding volume hierarchy and are efficiently culled using view frustum and horizon culling.
Screen Overlays Screen Overlays are used to render objects in 2D screen-space on top of a 3D scene. For example, screen overlays can be used to display your company's logo, create a translucent heads-up display (HUD), or display a video feed from an Unmanned Aerial Vehicle (UAV). Screen overlays support pixel and fractional units, translation, scale, and rotation transformations, and a user defined z-order.
Display Condition A property available on all primitives, globe overlays, and screen overlays, used to limit when an object is displayed. This can be based on the distance from the camera to a object, such as a primitive or globe overlay, the distance from the camera to a position, the camera's altitude, the current time, or other conditions. These fine grain conditions can be combined using Boolean logic with a composite, that is, a condition of conditions.
Picking Picking makes 3D applications interactive; allowing users to select and interact with objects in the 3D scene. This overview covers three common uses of picking in STK Engine applications: normal, roll-over, and drill picking. Normal picking is commonly used to zoom to a primitive or bring up a context menu. Roll-over picking is used to select objects or display the cursor's cartographic position over a globe as the mouse moves across the window. Drill picking is used when the same location is clicked or double clicked so the object under the top object can be acted upon.
Camera STK Engine's 3D control automatically provides rotating and zooming in a 3D scene using the mouse. The STK Engine camera object provides full control over the camera's position and orientation. The camera also provides higher level methods, such as the ability to view an entire central body or zoom to a rectangular extent on the globe. The camera is used to set view parameters like the field of view, near plane distance, and far plane distance. The camera provides functionality for taking snapshots of the 3D window as well as recording videos.
Imaging STK Engine provides a flexible Raster framework and raster processing through filters. The following raster image formats can be read by the raster class: BMP, ECW, IMG, JP2, NTF, NITF, PNG, SID, TIF, TIFF, JPG, JPEG, PPM, PGM, CLDS, and TGA. A raster can be loaded from a file, HTTP, HTTPS, or FTP source, and can also be loaded from memory, or constructed from a .NET Bitmap. The RasterFilter base class allows a user to perform many image processing tasks. The RasterStream class allows implementers to stream new data to a Raster over time, allowing for streaming of video (provided with the VideoStream class) and the ability to stream dynamic raster data into textures, including those on COLLADA models.
Performance Performance is important. This overview describes how to maximize frame rate and the fastest techniques for getting data into STK Engine.

STK 11.2.1 Programming Interface