PolylinePrimitiveSetPartial Method (IEnumerableCartesian, IEnumerableColor, IEnumerableInt32) |
Namespace: AGI.Foundation.Graphics
public void SetPartial( IEnumerable<Cartesian> positions, IEnumerable<Color> colors, IEnumerable<int> indices )
Exception | Condition |
---|---|
InvalidOperationException | The primitive's SetHint property is not Partial. Construct the primitive using Partial to order to call this method. |
InvalidOperationException | Cannot call this method until the primitive is first defined with Set. It is not possible to partially update an empty primitive. |
ArgumentNullException | positions and colors are null. Or indices is null. |
ArgumentException | positions, colors, and indices must contain the same number of elements. |
ArgumentException | A collection of colors was provided, but the primitive didn't have per-position colors defined with Set. |
To call SetPartial, the primitive must be constructed with Partial so the primitive builds the data structures necessary for partial updates. See the Set Hint topic for more information on selecting an appropriate value.
If the primitive's AutomaticallyComputeBoundingSphere property is , the primitive's BoundingSphere is computed based the primitive's unmodified positions and the updated positions from the positions collection. Otherwise, it is the caller's responsibility to update the primitive's BoundingSphere to a sphere that encompasses all the positions in the primitive.