public final class TextBatchPrimitive extends Primitive implements IDisposable
Renders one or more strings in the 3D scene.
For best performance, avoid creating lots of batches with only a few strings each. See the Batching Performance topic.
Text Batch Primitive topic Performance topicTextBatchPrimitiveOptionalParameters
Constructor and Description |
---|
TextBatchPrimitive(GraphicsFont font)
Initializes a marker batch primitive with the specified font.
|
TextBatchPrimitive(GraphicsFont font,
SetHint setHint)
Initializes a marker batch primitive with the specified font
and setHint.
|
TextBatchPrimitive(GraphicsFont font,
SetHint setHint,
boolean renderInScreenSpace)
Initializes a text batch primitive with the specified font
and setHint, optimized for 2d screen space rendering.
|
Modifier and Type | Method and Description |
---|---|
protected void |
dispose(boolean disposing) |
protected void |
finalize()
Called by the garbage collector on an object when garbage collection
determines that there are no more references to the object.
|
boolean |
getAlignToPixel()
Gets whether the screen space position of each string is aligned to a pixel.
|
double |
getBoundingSphereScale()
Gets or sets the scale applied to the radius of this primitive's bounding sphere.
|
Color |
getColor()
Gets the color that affects every string in the batch.
|
DistanceDisplayCondition |
getDistanceDisplayConditionPerString()
Gets a
DistanceDisplayCondition
that is evaluated per string in the text batch during rendering. |
GraphicsFont |
getFont()
Gets the font used to render the text batch.
|
Color |
getOutlineColor()
Gets the text's outline color.
|
float |
getOutlineTranslucency()
Gets the text's outline translucency.
|
boolean |
getPerItemPickingEnabled()
Gets whether individual text indices will be included in the
PickResults returned
from the Scene's Pick method. |
boolean |
getRenderInScreenSpace()
Gets whether the primitive is positioned and rendered in screen space coordinates.
|
SetHint |
getSetHint()
Gets the primitive's
SetHint . |
TextureFilter2D |
getTextureFilter()
Gets the filter used to filter the texture-based
Font . |
float |
getTranslucency()
Gets the translucency that affects every string in the batch.
|
void |
set(Iterable<Cartesian> positions,
Iterable<String> text)
Defines the positions and text of strings in a text batch.
|
void |
set(Iterable<Cartesian> positions,
Iterable<String> text,
TextBatchPrimitiveOptionalParameters optionalParameters)
Defines the positions, text, and optional parameters of strings in a
text batch.
|
void |
set(Iterable<Cartesian> positions,
Iterable<String> text,
TextBatchPrimitiveOptionalParameters optionalParameters,
RenderPassHint renderPassHint)
Defines the positions, text, and optional parameters of strings in a
text batch.
|
void |
setAlignToPixel(boolean value)
Sets whether the screen space position of each string is aligned to a pixel.
|
void |
setBoundingSphereScale(double value)
Gets or sets the scale applied to the radius of this primitive's bounding sphere.
|
void |
setCartographic(CentralBody centralBody,
Iterable<Cartographic> positions,
Iterable<String> text)
For convenience.
|
void |
setCartographic(CentralBody centralBody,
Iterable<Cartographic> positions,
Iterable<String> text,
TextBatchPrimitiveOptionalParameters optionalParameters)
For convenience.
|
void |
setCartographic(CentralBody centralBody,
Iterable<Cartographic> positions,
Iterable<String> text,
TextBatchPrimitiveOptionalParameters optionalParameters,
RenderPassHint renderPassHint)
For convenience.
|
void |
setColor(Color value)
Sets the color that affects every string in the batch.
|
void |
setDistanceDisplayConditionPerString(DistanceDisplayCondition value)
Sets a
DistanceDisplayCondition
that is evaluated per string in the text batch during rendering. |
void |
setOutlineColor(Color value)
Sets the text's outline color.
|
void |
setOutlineTranslucency(float value)
Sets the text's outline translucency.
|
void |
setPartial(Iterable<Cartesian> positions,
Iterable<String> text,
Iterable<Integer> indices)
Updates a subset of positions and/or text in a text batch.
|
void |
setPartial(Iterable<Cartesian> positions,
Iterable<String> text,
Iterable<Integer> indices,
IndicesOrderHint indicesOrderHint)
Updates a subset of positions and/or text in a text batch.
|
void |
setPartial(Iterable<Cartesian> positions,
Iterable<String> text,
TextBatchPrimitiveOptionalParameters optionalParameters,
Iterable<Integer> indices)
Updates a subset of positions, text, and/or optional per-string parameters in a text batch.
|
void |
setPartial(Iterable<Cartesian> positions,
Iterable<String> text,
TextBatchPrimitiveOptionalParameters optionalParameters,
Iterable<Integer> indices,
IndicesOrderHint indicesOrderHint,
RenderPassHint renderPassHint)
Updates a subset of positions, text, and/or optional per-string parameters in a text batch.
|
void |
setPartialCartographic(CentralBody centralBody,
Iterable<Cartographic> positions,
Iterable<String> text,
Iterable<Integer> indices)
For convenience.
|
void |
setPartialCartographic(CentralBody centralBody,
Iterable<Cartographic> positions,
Iterable<String> text,
Iterable<Integer> indices,
IndicesOrderHint indicesOrderHint)
For convenience.
|
void |
setPartialCartographic(CentralBody centralBody,
Iterable<Cartographic> positions,
Iterable<String> text,
TextBatchPrimitiveOptionalParameters optionalParameters,
Iterable<Integer> indices)
For convenience.
|
void |
setPartialCartographic(CentralBody centralBody,
Iterable<Cartographic> positions,
Iterable<String> text,
TextBatchPrimitiveOptionalParameters optionalParameters,
Iterable<Integer> indices,
IndicesOrderHint indicesOrderHint,
RenderPassHint renderPassHint)
For convenience.
|
void |
setPerItemPickingEnabled(boolean value)
Sets whether individual text indices will be included in the
PickResults returned
from the Scene's Pick method. |
void |
setRenderInScreenSpace(boolean renderInScreenSpace)
Sets whether the primitive is positioned and rendered in screen space coordinates.
|
void |
setTextureFilter(TextureFilter2D filter)
Sets the filter used to filter the texture-based
Font . |
void |
setTranslucency(float value)
Sets the translucency that affects every string in the batch.
|
dispose, getAutomaticallyComputeBoundingSphere, getBoundingSphere, getDisplay, getDisplayCondition, getReferenceFrame, getTag, setAutomaticallyComputeBoundingSphere, setBoundingSphere, setDisplay, setDisplayCondition, setReferenceFrame, setTag
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
close, dispose
public TextBatchPrimitive(GraphicsFont font)
SetHint
of Frequent
.font
- The font used to render text in the text batch.
See TextBatchPrimitive.TextBatchPrimitive(agi.foundation.graphics.GraphicsFont,agi.foundation.graphics.SetHint)
for a full discussion.
public TextBatchPrimitive(GraphicsFont font, SetHint setHint)
Set
and SetPartial
methods.
See the Set Hint topic for more information on
selecting an appropriate value.font
- The font used to render text in the text batch.system.ArgumentNullException
- font is null
.
setHint must be a valid enumeration value in
SetHint
.
After constructing the primitive, call a method such as
The primitive's properties are initialized to the following values:
get
) before it will be rendered.public TextBatchPrimitive(GraphicsFont font, SetHint setHint, boolean renderInScreenSpace)
Set
and SetPartial
methods.
See the Set Hint topic for more information on
selecting an appropriate value.font
- The font used to render text in the text batch.system.ArgumentNullException
- font is null
.
setHint must be a valid enumeration value in
SetHint
.
After constructing the primitive, call a method such as
The primitive's properties are initialized to the following values:
get
) before it will be rendered.protected void finalize() throws Throwable
java.lang.Object
finalize
method to dispose of
system resources or to perform other cleanup.
The general contract of finalize
is that it is invoked
if and when the Java™ virtual
machine has determined that there is no longer any
means by which this object can be accessed by any thread that has
not yet died, except as a result of an action taken by the
finalization of some other object or class which is ready to be
finalized. The finalize
method may take any action, including
making this object available again to other threads; the usual purpose
of finalize
, however, is to perform cleanup actions before
the object is irrevocably discarded. For example, the finalize method
for an object that represents an input/output connection might perform
explicit I/O transactions to break the connection before the object is
permanently discarded.
The finalize
method of class Object
performs no
special action; it simply returns normally. Subclasses of
Object
may override this definition.
The Java programming language does not guarantee which thread will
invoke the finalize
method for any given object. It is
guaranteed, however, that the thread that invokes finalize will not
be holding any user-visible synchronization locks when finalize is
invoked. If an uncaught exception is thrown by the finalize method,
the exception is ignored and finalization of that object terminates.
After the finalize
method has been invoked for an object, no
further action is taken until the Java virtual machine has again
determined that there is no longer any means by which this object can
be accessed by any thread that has not yet died, including possible
actions by other objects or classes which are ready to be finalized,
at which point the object may be discarded.
The finalize
method is never invoked more than once by a Java
virtual machine for any given object.
Any exception thrown by the finalize
method causes
the finalization of this object to be halted, but is otherwise
ignored.
finalize
in class Object
Throwable
- the Exception
raised by this methodWeakReference
,
PhantomReference
public Color getColor()
getColor
in class Primitive
system.InvalidOperationException
- Cannot access Color
when the primitive was defined
with per-string colors and translucency using a method such as a
agi.foundation.graphics.TextBatchPrimitive#Set(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String},agi.foundation.graphics.TextBatchPrimitiveOptionalParameters)
Each string has a color and translucency, therefore the primitive's
Color
is ignored.
If per-string color and translucency were specified with
TextBatchPrimitiveOptionalParameters.SetColors
,
the per-batch color is ignored.agi.foundation.graphics.TextBatchPrimitive#Set(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String},agi.foundation.graphics.TextBatchPrimitiveOptionalParameters)
,
TextBatchPrimitiveOptionalParameters.SetColors
public void setColor(Color value)
setColor
in class Primitive
system.InvalidOperationException
- Cannot access Color
when the primitive was defined
with per-string colors and translucency using a method such as a
agi.foundation.graphics.TextBatchPrimitive#Set(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String},agi.foundation.graphics.TextBatchPrimitiveOptionalParameters)
Each string has a color and translucency, therefore the primitive's
Color
is ignored.
If per-string color and translucency were specified with
TextBatchPrimitiveOptionalParameters.SetColors
,
the per-batch color is ignored.agi.foundation.graphics.TextBatchPrimitive#Set(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String},agi.foundation.graphics.TextBatchPrimitiveOptionalParameters)
,
TextBatchPrimitiveOptionalParameters.SetColors
public float getTranslucency()
Translucency
is between 0
and 1
,
where 0
is opaque and 1
is transparent.getTranslucency
in class Primitive
system.ArgumentOutOfRangeException
- Translucency
must be between 0
and 1
.system.InvalidOperationException
- Cannot access Translucency
when the primitive was defined
with per-string colors and translucency using a method such as a
agi.foundation.graphics.TextBatchPrimitive#Set(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String},agi.foundation.graphics.TextBatchPrimitiveOptionalParameters)
Each string has a color and translucency, therefore the primitive's
Translucency
is ignored.
If per-string color and translucency were specified with
TextBatchPrimitiveOptionalParameters.SetColors
,
the per-batch translucency is ignored.agi.foundation.graphics.TextBatchPrimitive#Set(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String},agi.foundation.graphics.TextBatchPrimitiveOptionalParameters)
,
TextBatchPrimitiveOptionalParameters.SetColors
public void setTranslucency(float value)
Translucency
is between 0
and 1
,
where 0
is opaque and 1
is transparent.setTranslucency
in class Primitive
system.ArgumentOutOfRangeException
- Translucency
must be between 0
and 1
.system.InvalidOperationException
- Cannot access Translucency
when the primitive was defined
with per-string colors and translucency using a method such as a
agi.foundation.graphics.TextBatchPrimitive#Set(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String},agi.foundation.graphics.TextBatchPrimitiveOptionalParameters)
Each string has a color and translucency, therefore the primitive's
Translucency
is ignored.
If per-string color and translucency were specified with
TextBatchPrimitiveOptionalParameters.SetColors
,
the per-batch translucency is ignored.agi.foundation.graphics.TextBatchPrimitive#Set(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String},agi.foundation.graphics.TextBatchPrimitiveOptionalParameters)
,
TextBatchPrimitiveOptionalParameters.SetColors
public final SetHint getSetHint()
SetHint
.
See the Set Hint topic for more information on
selecting an appropriate value to construct the primitive with.public final double getBoundingSphereScale()
public final void setBoundingSphereScale(double value)
public final GraphicsFont getFont()
public final Color getOutlineColor()
system.InvalidOperationException
- Font
was not created with an outline.public final void setOutlineColor(Color value)
system.InvalidOperationException
- Font
was not created with an outline.public final float getOutlineTranslucency()
Translucency
is between 0
and 1
,
where 0
is opaque and 1
is transparent.system.ArgumentOutOfRangeException
- Translucency
must be between 0
and 1
.system.InvalidOperationException
- Font
was not created with an outline.public final void setOutlineTranslucency(float value)
Translucency
is between 0
and 1
,
where 0
is opaque and 1
is transparent.system.ArgumentOutOfRangeException
- Translucency
must be between 0
and 1
.system.InvalidOperationException
- Font
was not created with an outline.public final boolean getAlignToPixel()
public final void setAlignToPixel(boolean value)
public final boolean getRenderInScreenSpace()
public final void setRenderInScreenSpace(boolean renderInScreenSpace)
public final DistanceDisplayCondition getDistanceDisplayConditionPerString()
DistanceDisplayCondition
that is evaluated per string in the text batch during rendering. This is different than
agi.foundation.graphics.primitive.DisplayCondition
,
which is evaluated once for the entire text batch.
When DistanceDisplayConditionPerString
is null
, no per string display condition is evaluated.
During rendering, first the primitive's
agi.foundation.graphics.primitive.DisplayCondition
is evaluated. If it succeeds, this distance display condition is evaluated
for each string in the batch before a marker is rendered.public final void setDistanceDisplayConditionPerString(DistanceDisplayCondition value)
DistanceDisplayCondition
that is evaluated per string in the text batch during rendering. This is different than
agi.foundation.graphics.primitive.DisplayCondition
,
which is evaluated once for the entire text batch.
When DistanceDisplayConditionPerString
is null
, no per string display condition is evaluated.
During rendering, first the primitive's
agi.foundation.graphics.primitive.DisplayCondition
is evaluated. If it succeeds, this distance display condition is evaluated
for each string in the batch before a marker is rendered.public final boolean getPerItemPickingEnabled()
PickResults
returned
from the Scene's
Pick
method. Each text
index that is picked will be returned as a BatchPrimitiveIndex
.
Picking topicpublic final void setPerItemPickingEnabled(boolean value)
PickResults
returned
from the Scene's
Pick
method. Each text
index that is picked will be returned as a BatchPrimitiveIndex
.
Picking topicpublic final TextureFilter2D getTextureFilter()
Font
.Font
public final void setTextureFilter(TextureFilter2D filter)
Font
.Font
public final void set(Iterable<Cartesian> positions, Iterable<String> text)
agi.foundation.graphics.primitive.ReferenceFrame
.
The new positions for strings in the text batch.
The text for strings in the text batch. Each element in this collection
corresponds to an element in system.ArgumentNullException
- positions or text is null
.system.ArgumentException
- positions and text must contain the
same number of elements.CouldNotCreateVideoCardResourceException
- Could not allocate video memory for positions
and text.
This call overwrites the primitive's previous strings. To update a subset of string, use
agi.foundation.graphics.SetHint#Frequent
,
which is the default. If this method will be called only once or infrequently, construct the primitive with
agi.foundation.graphics.SetHint#Infrequent
.
See the Set Hint topic for more information.
If the primitive's
AutomaticallyComputeBoundingSphere (get
)
property is , the primitive's
BoundingSphere (get
)
is computed based on positions.
Otherwise, it is the caller's responsibility to update the primitive's
BoundingSphere (get
)
to a sphere that encompasses all the positions.
Text Batch Primitive topic
Performance topicagi.foundation.graphics.TextBatchPrimitive#SetPartial(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String},system.collections.generic.ienumerable`1{system.Int32})
public final void set(Iterable<Cartesian> positions, Iterable<String> text, TextBatchPrimitiveOptionalParameters optionalParameters)
agi.foundation.graphics.primitive.ReferenceFrame
.
The new positions for strings in the text batch.
The text for strings in the text batch. Each element in this collection
corresponds to an element in optionalParameters
- Optional per-batch parameters or per-string parameters corresponding to positions.
Each per-string parameter must have the same number of elements as positions.system.ArgumentNullException
- positions or text is null
.system.ArgumentException
- positions and text must contain the
same number of elements.CouldNotCreateVideoCardResourceException
- Could not allocate video memory for positions
and text.
This call overwrites the primitive's previous strings. To update a subset of string, use
See
agi.foundation.graphics.SetHint#Frequent
,
which is the default. If this method will be called only once or infrequently, construct the primitive with
agi.foundation.graphics.SetHint#Infrequent
.
See the Set Hint topic for more information.
If the primitive's
AutomaticallyComputeBoundingSphere (get
)
property is , the primitive's
BoundingSphere (get
)
is computed based on positions.
Otherwise, it is the caller's responsibility to update the primitive's
BoundingSphere (get
)
to a sphere that encompasses all the positions.
Text Batch Primitive topic
Performance topicagi.foundation.graphics.TextBatchPrimitive#SetPartial(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String},system.collections.generic.ienumerable`1{system.Int32})
public final void set(Iterable<Cartesian> positions, Iterable<String> text, TextBatchPrimitiveOptionalParameters optionalParameters, RenderPassHint renderPassHint)
agi.foundation.graphics.primitive.ReferenceFrame
.
renderPassHint is provided for efficiency.
The new positions for strings in the text batch.
The text for strings in the text batch. Each element in this collection
corresponds to an element in optionalParameters
- Optional per-batch parameters or per-string parameters corresponding to positions.
Each per-string parameter must have the same number of elements as positions.renderPassHint
- An optimization hint indicating the RenderPass
implied by per-strings colors defined in optionalParameters.
Calling this method with a
See
agi.foundation.graphics.TextBatchPrimitive#Set(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String},agi.foundation.graphics.TextBatchPrimitiveOptionalParameters)
public final void setCartographic(CentralBody centralBody, Iterable<Cartographic> positions, Iterable<String> text)
Cartographic
positions.
Longitude and latitude are in radians, and altitude is in meters.
This is equivalent to
converting each position in positions to
Cartesian
and calling
agi.foundation.graphics.TextBatchPrimitive#Set(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String})
.centralBody
- The central body the positions are defined on.
The new positions for strings in the text batch.
The text for strings in the text batch. Each element in this collection
corresponds to an element in get
)
is not equal to centralBody fixed frame.
centralBody is used to convert positions to
Cartesian
.
The primitive's
ReferenceFrame (get
)
must be equal to the centralBody fixed frame. If the primitive's
ReferenceFrame (get
)
is changed after calling this method, the
Cartesian
positions stored by the primitive are not modified and are unlikely to represent the original
Cartographic
positions provided to this method.
See
agi.foundation.graphics.TextBatchPrimitive#Set(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String})
public final void setCartographic(CentralBody centralBody, Iterable<Cartographic> positions, Iterable<String> text, TextBatchPrimitiveOptionalParameters optionalParameters)
Cartographic
positions.
Longitude and latitude are in radians, and altitude is in meters.
This is equivalent to
converting each position in positions to
Cartesian
and calling
agi.foundation.graphics.TextBatchPrimitive#Set(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String})
.centralBody
- The central body the positions are defined on.
The new positions for strings in the text batch.
The text for strings in the text batch. Each element in this collection
corresponds to an element in optionalParameters
- Optional per-batch parameters or per-string parameters corresponding to positions.
Each per-string parameter must have the same number of elements as positions.
centralBody is .
The primitive's ReferenceFrame (get
)
is not equal to centralBody fixed frame.
centralBody is used to convert positions to
Cartesian
.
The primitive's
ReferenceFrame (get
)
must be equal to the centralBody fixed frame. If the primitive's
ReferenceFrame (get
)
is changed after calling this method, the
Cartesian
positions stored by the primitive are not modified and are unlikely to represent the original
Cartographic
positions provided to this method.
See
agi.foundation.graphics.TextBatchPrimitive#Set(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String},agi.foundation.graphics.TextBatchPrimitiveOptionalParameters)
public final void setCartographic(CentralBody centralBody, Iterable<Cartographic> positions, Iterable<String> text, TextBatchPrimitiveOptionalParameters optionalParameters, RenderPassHint renderPassHint)
Cartographic
positions.
Longitude and latitude are in radians, and altitude is in meters.
This is equivalent to
converting each position in positions to
Cartesian
and calling
agi.foundation.graphics.TextBatchPrimitive#Set(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String})
.centralBody
- The central body the positions are defined on.
The new positions for strings in the text batch.
The text for strings in the text batch. Each element in this collection
corresponds to an element in optionalParameters
- Optional per-batch parameters or per-string parameters corresponding to positions.
Each per-string parameter must have the same number of elements as positions.renderPassHint
- An optimization hint indicating the RenderPass
implied by per-strings colors defined in optionalParameters.
centralBody is .
The primitive's ReferenceFrame (get
)
is not equal to centralBody fixed frame.
centralBody is used to convert positions to
Cartesian
.
The primitive's
ReferenceFrame (get
)
must be equal to the centralBody fixed frame. If the primitive's
ReferenceFrame (get
)
is changed after calling this method, the
Cartesian
positions stored by the primitive are not modified and are unlikely to represent the original
Cartographic
positions provided to this method.
See
agi.foundation.graphics.TextBatchPrimitive#Set(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String},agi.foundation.graphics.TextBatchPrimitiveOptionalParameters,agi.foundation.graphics.advanced.RenderPassHint)
public final void setPartial(Iterable<Cartesian> positions, Iterable<String> text, Iterable<Integer> indices)
text
- A collection of new text used to update a subset of text in the text batch.
A collection of zero-based indices that map a corresponding position in
positions to a position already in the primitive.
For example, if a primitive is first given 5
positions with
a call to Set
, positions 1
and 3
can be modified
with SetPartial
by passing in positions containing
two new positions and an indices collection with two
elements, e.g. [1, 3]
. The first position in positions
will modify the position at index 1
in the primitive and the second
will modify the position at index 3
.
The primitive's SetHint
property is not
agi.foundation.graphics.SetHint#Partial
.
Construct the primitive using
agi.foundation.graphics.SetHint#Partial
to order to call this method.system.ArgumentNullException
- positions and text are
null
. Or indices is null
.system.ArgumentException
- if non-null
, positions and
text must contain the same number of elements.
To call SetPartial
, the primitive must be constructed with
agi.foundation.graphics.SetHint#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 (get
)
property is , the primitive's
BoundingSphere (get
)
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 (get
)
to a sphere that encompasses all the positions in the primitive.
Dynamic Updates topic
Set Hint Performance topicpublic final void setPartial(Iterable<Cartesian> positions, Iterable<String> text, Iterable<Integer> indices, IndicesOrderHint indicesOrderHint)
text
- A collection of new text used to update a subset of text in the text batch.
A collection of zero-based indices that map a corresponding position in
positions to a position already in the primitive.
For example, if a primitive is first given 5
positions with
a call to Set
, positions 1
and 3
can be modified
with SetPartial
by passing in positions containing
two new positions and an indices collection with two
elements, e.g. [1, 3]
. The first position in positions
will modify the position at index 1
in the primitive and the second
will modify the position at index 3
.
An optimization hint indicating how indices are sorted.
The primitive's SetHint
property is not
agi.foundation.graphics.SetHint#Partial
.
Construct the primitive using
agi.foundation.graphics.SetHint#Partial
to order to call this method.system.ArgumentNullException
- positions and text are
null
. Or indices is null
.system.ArgumentException
- if non-null
, positions and
text must contain the same number of elements.
To call SetPartial
, the primitive must be constructed with
agi.foundation.graphics.SetHint#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 (get
)
property is , the primitive's
BoundingSphere (get
)
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 (get
)
to a sphere that encompasses all the positions in the primitive.
Dynamic Updates topic
Set Hint Performance topicpublic final void setPartial(Iterable<Cartesian> positions, Iterable<String> text, TextBatchPrimitiveOptionalParameters optionalParameters, Iterable<Integer> indices)
text
- A collection of new text used to update a subset of text in the text batch.optionalParameters
- Optional per-batch parameters or per-string parameters corresponding to positions.
Each per-string parameter must have the same number of elements as positions.
A collection of zero-based indices that map a corresponding position in
positions to a position already in the primitive.
For example, if a primitive is first given 5
positions with
a call to Set
, positions 1
and 3
can be modified
with SetPartial
by passing in positions containing
two new positions and an indices collection with two
elements, e.g. [1, 3]
. The first position in positions
will modify the position at index 1
in the primitive and the second
will modify the position at index 3
.
The primitive's SetHint
property is not
agi.foundation.graphics.SetHint#Partial
.
Construct the primitive using
agi.foundation.graphics.SetHint#Partial
to order to call this method.system.ArgumentNullException
- positions and text are
null
. Or indices is null
.system.ArgumentException
- Every specified collection from positions, text,
and optionalParameters
must have the same number of elements.
To call SetPartial
, the primitive must be constructed with
agi.foundation.graphics.SetHint#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 (get
)
property is , the primitive's
BoundingSphere (get
)
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 (get
)
to a sphere that encompasses all the positions in the primitive.
Dynamic Updates topic
Set Hint Performance topicpublic final void setPartial(Iterable<Cartesian> positions, Iterable<String> text, TextBatchPrimitiveOptionalParameters optionalParameters, Iterable<Integer> indices, IndicesOrderHint indicesOrderHint, RenderPassHint renderPassHint)
text
- A collection of new text used to update a subset of text in the text batch.optionalParameters
- Optional per-batch parameters or per-string parameters corresponding to positions.
Each per-string parameter must have the same number of elements as positions.
A collection of zero-based indices that map a corresponding position in
positions to a position already in the primitive.
For example, if a primitive is first given 5
positions with
a call to Set
, positions 1
and 3
can be modified
with SetPartial
by passing in positions containing
two new positions and an indices collection with two
elements, e.g. [1, 3]
. The first position in positions
will modify the position at index 1
in the primitive and the second
will modify the position at index 3
.
An optimization hint indicating how indices are sorted.renderPassHint
- An optimization hint indicating the RenderPass
implied by per-marker colors defined in optionalParameters.
The primitive's SetHint
property is not
agi.foundation.graphics.SetHint#Partial
.
Construct the primitive using
agi.foundation.graphics.SetHint#Partial
to order to call this method.system.ArgumentNullException
- positions and text are
null
. Or indices is null
.system.ArgumentException
- Every specified collection from positions, text,
and optionalParameters
must have the same number of elements.
To call SetPartial
, the primitive must be constructed with
agi.foundation.graphics.SetHint#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 (get
)
property is , the primitive's
BoundingSphere (get
)
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 (get
)
to a sphere that encompasses all the positions in the primitive.
Dynamic Updates topic
Set Hint Performance topicpublic final void setPartialCartographic(CentralBody centralBody, Iterable<Cartographic> positions, Iterable<String> text, Iterable<Integer> indices)
Cartographic
positions.
Longitude and latitude are in radians, and altitude is in meters.
This is equivalent to
converting each position in positions to
Cartesian
and calling
agi.foundation.graphics.TextBatchPrimitive#SetPartial(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String},system.collections.generic.ienumerable`1{system.Int32})
.centralBody
- The central body the positions are defined on.
A collection of new positions used to update a subset of positions in the text batch.
text
- A collection of new text used to update a subset of text in the text batch.
A collection of zero-based indices that map a corresponding position in
positions to a position already in the primitive.
For example, if a primitive is first given 5
positions with
a call to Set
, positions 1
and 3
can be modified
with SetPartial
by passing in positions containing
two new positions and an indices collection with two
elements, e.g. [1, 3]
. The first position in positions
will modify the position at index 1
in the primitive and the second
will modify the position at index 3
.
centralBody is .
The primitive's ReferenceFrame (get
)
is not equal to centralBody fixed frame.
centralBody is used to convert positions to
Cartesian
.
The primitive's
ReferenceFrame (get
)
must be equal to the centralBody fixed frame. If the primitive's
ReferenceFrame (get
)
is changed after calling this method, the
Cartesian
positions stored by the primitive are not modified and are unlikely to represent the original
Cartographic
positions provided to this method.
See
agi.foundation.graphics.TextBatchPrimitive#SetPartial(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String},system.collections.generic.ienumerable`1{system.Int32})
public final void setPartialCartographic(CentralBody centralBody, Iterable<Cartographic> positions, Iterable<String> text, Iterable<Integer> indices, IndicesOrderHint indicesOrderHint)
Cartographic
positions.
Longitude and latitude are in radians, and altitude is in meters.
This is equivalent to
converting each position in positions to
Cartesian
and calling
agi.foundation.graphics.TextBatchPrimitive#SetPartial(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String},system.collections.generic.ienumerable`1{system.Int32},agi.foundation.graphics.advanced.IndicesOrderHint)
.centralBody
- The central body the positions are defined on.
A collection of new positions used to update a subset of positions in the text batch.
text
- A collection of new text used to update a subset of text in the text batch.
A collection of zero-based indices that map a corresponding position in
positions to a position already in the primitive.
For example, if a primitive is first given 5
positions with
a call to Set
, positions 1
and 3
can be modified
with SetPartial
by passing in positions containing
two new positions and an indices collection with two
elements, e.g. [1, 3]
. The first position in positions
will modify the position at index 1
in the primitive and the second
will modify the position at index 3
.
An optimization hint indicating how indices are sorted.
centralBody is .
The primitive's ReferenceFrame (get
)
is not equal to centralBody fixed frame.
centralBody is used to convert positions to
Cartesian
.
The primitive's
ReferenceFrame (get
)
must be equal to the centralBody fixed frame. If the primitive's
ReferenceFrame (get
)
is changed after calling this method, the
Cartesian
positions stored by the primitive are not modified and are unlikely to represent the original
Cartographic
positions provided to this method.
See
agi.foundation.graphics.TextBatchPrimitive#SetPartial(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String},system.collections.generic.ienumerable`1{system.Int32},agi.foundation.graphics.advanced.IndicesOrderHint)
public final void setPartialCartographic(CentralBody centralBody, Iterable<Cartographic> positions, Iterable<String> text, TextBatchPrimitiveOptionalParameters optionalParameters, Iterable<Integer> indices)
Cartographic
positions.
Longitude and latitude are in radians, and altitude is in meters.
This is equivalent to
converting each position in positions to
Cartesian
and calling
agi.foundation.graphics.TextBatchPrimitive#SetPartial(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String},agi.foundation.graphics.TextBatchPrimitiveOptionalParameters,system.collections.generic.ienumerable`1{system.Int32})
.centralBody
- The central body the positions are defined on.
A collection of new positions used to update a subset of positions in the text batch.
text
- A collection of new text used to update a subset of text in the text batch.optionalParameters
- Optional per-batch parameters or per-string parameters corresponding to positions.
Each per-string parameter must have the same number of elements as positions.
A collection of zero-based indices that map a corresponding position in
positions to a position already in the primitive.
For example, if a primitive is first given 5
positions with
a call to Set
, positions 1
and 3
can be modified
with SetPartial
by passing in positions containing
two new positions and an indices collection with two
elements, e.g. [1, 3]
. The first position in positions
will modify the position at index 1
in the primitive and the second
will modify the position at index 3
.
centralBody is .
The primitive's ReferenceFrame (get
)
is not equal to centralBody fixed frame.
centralBody is used to convert positions to
Cartesian
.
The primitive's
ReferenceFrame (get
)
must be equal to the centralBody fixed frame. If the primitive's
ReferenceFrame (get
)
is changed after calling this method, the
Cartesian
positions stored by the primitive are not modified and are unlikely to represent the original
Cartographic
positions provided to this method.
See
agi.foundation.graphics.TextBatchPrimitive#SetPartial(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String},agi.foundation.graphics.TextBatchPrimitiveOptionalParameters,system.collections.generic.ienumerable`1{system.Int32})
public final void setPartialCartographic(CentralBody centralBody, Iterable<Cartographic> positions, Iterable<String> text, TextBatchPrimitiveOptionalParameters optionalParameters, Iterable<Integer> indices, IndicesOrderHint indicesOrderHint, RenderPassHint renderPassHint)
Cartographic
positions.
Longitude and latitude are in radians, and altitude is in meters.
This is equivalent to
converting each position in positions to
Cartesian
and calling
agi.foundation.graphics.TextBatchPrimitive#SetPartial(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String},agi.foundation.graphics.TextBatchPrimitiveOptionalParameters,system.collections.generic.ienumerable`1{system.Int32},agi.foundation.graphics.advanced.IndicesOrderHint,agi.foundation.graphics.advanced.RenderPassHint)
.centralBody
- The central body the positions are defined on.
A collection of new positions used to update a subset of positions in the text batch.
text
- A collection of new text used to update a subset of text in the text batch.optionalParameters
- Optional per-batch parameters or per-string parameters corresponding to positions.
Each per-string parameter must have the same number of elements as positions.
A collection of zero-based indices that map a corresponding position in
positions to a position already in the primitive.
For example, if a primitive is first given 5
positions with
a call to Set
, positions 1
and 3
can be modified
with SetPartial
by passing in positions containing
two new positions and an indices collection with two
elements, e.g. [1, 3]
. The first position in positions
will modify the position at index 1
in the primitive and the second
will modify the position at index 3
.
An optimization hint indicating how indices are sorted.renderPassHint
- An optimization hint indicating the RenderPass
implied by per-marker colors defined in optionalParameters.
centralBody is .
The primitive's ReferenceFrame (get
)
is not equal to centralBody fixed frame.
centralBody is used to convert positions to
Cartesian
.
The primitive's
ReferenceFrame (get
)
must be equal to the centralBody fixed frame. If the primitive's
ReferenceFrame (get
)
is changed after calling this method, the
Cartesian
positions stored by the primitive are not modified and are unlikely to represent the original
Cartographic
positions provided to this method.
See
agi.foundation.graphics.TextBatchPrimitive#SetPartial(system.collections.generic.ienumerable`1{agi.foundation.coordinates.Cartesian},system.collections.generic.ienumerable`1{system.String},agi.foundation.graphics.TextBatchPrimitiveOptionalParameters,system.collections.generic.ienumerable`1{system.Int32},agi.foundation.graphics.advanced.IndicesOrderHint,agi.foundation.graphics.advanced.RenderPassHint)