AGI Components with Insight3D Alpha 2008 r8
Conventions
Topic Description
Naming Conventions Prefixes for classes, interfaces, and enumerations
Collections, Composites, and Batches Ways to group objects together
Naming Conventions
To avoid naming conflicts in non .NET environments, the following naming conventions are used:
  • Classes and enumerations are prefixed with AgGx.
  • Interfaces are prefixed with IAgGx.

Many interface and class names go from least specific to most specific, e.g. AgGxPrimitivePolyline and AgGxPrimitivePointBatch. This allows similar interfaces and classes, such as primitives, to show up together in Intellisense.

Collections, Composites, and Batches

Collections are groups of objects, such as AgGxCartesianCollection. Indices in collections are zero-based. When an object provides two similar methods, one that takes an array, and one that takes a collection (e.g. AgGxPrimitivePointBatch's Initialize and InitializeFromCartesianCollection), the method taking an array is more efficient. Methods taking a collection are slightly easier to use and available to scripting languages. Scripting languages do not support the array-based methods.

Composites are also groups of objects. The composite itself is the same type as the objects it contains, so composites can contain composites. This is used for building hierarchies. Composite primitives, AgGxPrimitiveComposite, are used to build hierarchies of primitives for efficient rendering, layering, and aggregation/deaggregation.

Batches are homogeneous groups of primitives that share common properties. For example, the point batch primitive, AgGxPrimitivePointBatch, is a collection of points with the same pixel size. In general, rendering a few large batches is more efficient then rendering several small batches.