Class TLcdBoundedCompositeViewshed
- All Implemented Interfaces:
ILcdViewshed
A bounded object viewshed is a composite viewshed optimized for bounded objects.
Adding
new viewsheds to this viewshed can be done using the addBoundedObject(com.luciad.shape.ILcdBounded, com.luciad.transformation.ILcdModelModelTransformation, ILcdViewshed)
method. The result of a
getVisibility(com.luciad.shape.ILcdPoint)
query will be the result of visibility queries
for all added viewsheds through the ILcdVisibilityComposite
visibility composite set by the
ALcdCompositeViewshed.setComposite(com.luciad.tea.viewshed.ILcdVisibilityComposite)
method.
To this respect, this
viewshed should be used to composite viewsheds that represent separate objects, such as
buildings. In this case, each building should be added individually, and the TLcdBoundedCompositeViewshed
would represent the viewshed for a collection
of buildings for the given ALcdViewshedObserver
Note: It is important that all added viewsheds be defined in the same reference and for the same observer in order for this viewshed to generate meaningful results.
Performance considerations: Using the addAllObjects(TLcdBoundedCompositeViewshed)
can
be greatly beneficial to performance. It is generally recommended to use a single bounded object viewshed
per observer to achieve maximum performance.
- Since:
- 11.0
-
Constructor Summary
ConstructorDescriptionTLcdBoundedCompositeViewshed
(ILcdGeoReference aViewshedReference, ALcdViewshedObserver aViewshedObserver) Creates a newTLcdBoundedCompositeViewshed
, given anALcdViewshedObserver
. -
Method Summary
Modifier and TypeMethodDescriptionvoid
addAllObjects
(TLcdBoundedCompositeViewshed aViewshed) Adds all the bounded objects from the given bounded object viewshed to this bounded object viewshed, effectively merging the two.void
addBoundedObject
(ILcdBounded aBoundedObject, ILcdModelModelTransformation aTransformation, ILcdViewshed aViewshed) Adds a bounded object to this viewshed.Returns the reference in which this viewshed is defined.Returns the viewshed observer for thisTLcdBoundedCompositeViewshed
.double
getVisibility
(ILcdPoint aPoint) Returns the visibility of a given point.Methods inherited from class com.luciad.tea.viewshed.ALcdCompositeViewshed
getComposite, setComposite
-
Constructor Details
-
TLcdBoundedCompositeViewshed
public TLcdBoundedCompositeViewshed(ILcdGeoReference aViewshedReference, ALcdViewshedObserver aViewshedObserver) Creates a newTLcdBoundedCompositeViewshed
, given anALcdViewshedObserver
.- Parameters:
aViewshedReference
- The reference in which this viewshed is defined. Must be a cartesian reference.aViewshedObserver
- The viewshed observer for this viewshed.
-
-
Method Details
-
getViewshedObserver
Returns the viewshed observer for thisTLcdBoundedCompositeViewshed
.- Returns:
- A viewshed observer.
-
addAllObjects
Adds all the bounded objects from the given bounded object viewshed to this bounded object viewshed, effectively merging the two. Note that the twoALcdViewshedObserver
must be equal in order for this method to work.- Parameters:
aViewshed
- A viewshed with bounded objects that should be added to this bounded object viewshed. The given viewshed must be defined for the same observer as this viewshed.
-
addBoundedObject
public void addBoundedObject(ILcdBounded aBoundedObject, ILcdModelModelTransformation aTransformation, ILcdViewshed aViewshed) Adds a bounded object to this viewshed. The bounded object must be accompanied by a viewshed.
Note: It is important that all viewsheds are defined in the same reference and for the same viewshed observer, namely the one returned by
getViewshedObserver()
for this class to generate meaningful results.- Parameters:
aBoundedObject
- The bounded object that is the cause for the viewshed, defined in the source reference ofaTransformation
.aTransformation
- A transformation that can transform the bounded object to the reference of the this viewshed. The destination of this transformation must be the same for all added viewsheds.aViewshed
- The viewshed that is the result of the bounded object, given in the destination reference ofaTransformation
and generated for the viewshed observer ingetViewshedObserver()
.
-
getVisibility
Description copied from interface:ILcdViewshed
Returns the visibility of a given point.- Parameters:
aPoint
- The point to check visibility of. The point must be given in the reference in which the viewshed is defined.- Returns:
- A double indicating the visibility of the point. This value will be bound between 0 and 1. 0 represents non-visible. 1 represents fully visible. Anything in between 0 and 1 is partially visible, depending on specific cases.
-
getReference
Description copied from interface:ILcdViewshed
Returns the reference in which this viewshed is defined.- Returns:
- The reference in which viewshed is defined
-