checkObjectVisibility method
- MapSceneObject? mapSceneObject,
- Rectangle<
int> ? rect,
Check if the given scene object visible in the given viewport.
Does not take into account the object visibility.
Parameters
- IN mapSceneObject Map scene object to test
- IN rect Viewport rectangle in screen coordinates. If no viewport is given, the whole screen is used
Returns
- True if the given scene object visible in the given viewport, false otherwise
Implementation
bool checkObjectVisibility({
MapSceneObject? mapSceneObject,
Rectangle<int>? rect,
}) {
rect ??= const Rectangle<int>(0, 0, 0, 0);
mapSceneObject ??= MapSceneObject.getDefPositionTracker();
final OperationResult resultString = objectMethod(
_pointerId,
'MapView',
'checkObjectVisibility',
args: <String, dynamic>{
'obj': mapSceneObject.pointerId,
'rc': RectType<int>.fromRectangle(rect)
},
);
return resultString['result'];
}