MapCameraUpdateFactory class abstract

Factory for creating MapCameraUpdate to change map's camera.

For some factory methods you can apply an additional padding in pixels by setting a viewRectangle parameter based on the current size of the map view:

var leftPaddingInPixels = 5;
var rightPaddingInPixels = 5;
var topPaddingInPixels = 5;
var bottomPaddingInPixels = 5;
var horizontalPaddingInPixels = leftPaddingInPixels + rightPaddingInPixels;
var verticalPaddingInPixels = topPaddingInPixels + bottomPaddingInPixels;

var origin = Point2D(leftPaddingInPixels, topPaddingInPixels);
var sizeInPixels = Size2D(_hereMapController.viewportSize.width - horizontalPaddingInPixels, _hereMapController.viewportSize.height - verticalPaddingInPixels);
var paddedViewRectangle = Rectangle2D(origin, sizeInPixels);

The origin indicates the top-left corner of the rectangle. An origin of (0, 0) indicates also the top-left corner of the map's viewport.

Constructors

MapCameraUpdateFactory()

Properties

hashCode → int
The hash code for this object.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Static Methods

compositeUpdate(List<MapCameraUpdate> mapCameraUpdates) MapCameraUpdate
Creates a composite camera update from a list of camera updates.
lookAtArea(GeoBox target) MapCameraUpdate
Creates an update to look at the given geo-box, preserving current orientation and zooming at the center of viewport.
lookAtAreaWithGeoOrientationAndViewRectangle(GeoBox target, GeoOrientationUpdate orientation, Rectangle2D viewRectangle) MapCameraUpdate
Create an update to look at the given geo-box and fit it inside the given rectangle.
lookAtAreaWithViewRectangle(GeoBox target, Rectangle2D viewRectangle) MapCameraUpdate
Creates an update to look at the given geo-box and fit it inside the given rectangle, preserving current orientation and zooming at the center of view rectangle.
lookAtPoint(GeoCoordinatesUpdate target) MapCameraUpdate
Creates an update to position the map camera to look at the given target, preserving the current orientation at look-at target and map measure.
lookAtPoints(List<GeoCoordinates> points, Rectangle2D viewRectangle, GeoOrientationUpdate orientation, MapMeasure measureLimit) MapCameraUpdate
Create an update to look at the given geo locations and fit them inside the given rectangle, in accordance with a map measure limit.
lookAtPointWithGeoOrientationAndMeasure(GeoCoordinatesUpdate target, GeoOrientationUpdate orientation, MapMeasure measure) MapCameraUpdate
Creates an update to position the map camera to look at the given target with the given orientation and map measure.
lookAtPointWithMeasure(GeoCoordinatesUpdate target, MapMeasure measure) MapCameraUpdate
Creates an update to position the map camera to look at the given target with the given map measure preserving the current orientation at look-at target.
lookAtPointWithOrientation(GeoCoordinatesUpdate target, GeoOrientationUpdate orientation) MapCameraUpdate
Creates an update to position the map camera to look at the given target with the given orientation preserving the current map measure (zoom level/distance/scale) Any target or orientation sub-element value that is not finite will be excluded from the update.
lookAtTargetAndPoints(GeoCoordinatesUpdate target, GeoOrientationUpdate orientation, List<GeoCoordinates> points, Rectangle2D viewRectangle, MapMeasure minMeasure, MapMeasure maxMeasure) MapCameraUpdate
Creates an update to position the camera to look at the given target with the given orientation and obeying map measure limits, so that the given geo locations are inside the given rectangle.
lookToMatchGeoPointToViewPoint(GeoCoordinates geoPoint, Point2D viewPoint) MapCameraUpdate
Creates an update to position the map camera to look at the map with the given geo point located at the given view point.
lookToMatchGeoPointToViewPointWithOrientationMapMeasure(GeoCoordinates geoPoint, Point2D viewPoint, GeoOrientationUpdate orientation, MapMeasure measure) MapCameraUpdate
Creates an update to position the map camera to look at the map with the given orientation and map measure and with the given geo point located at the given view point.
orbitBy(GeoOrientationUpdate delta, Point2D origin) MapCameraUpdate
Creates an update to orbit map camera around a pixel origin by specified geodetic orientation delta.
panBy(double xOffset, double yOffset) MapCameraUpdate
Creates an update to pan map camera over the map by the specified number of pixels in the x and y direction starting from current principal point position.
rotateBy(GeoOrientationUpdate delta) MapCameraUpdate
Creates an update to change map camera orientation by specified geodetic orientation delta.
setNormalizedPrincipalPoint(Anchor2D principalPoint) MapCameraUpdate
Creates an update to change the map camera's principal point (where the view vector intersects the image plane - default is (0.5, 0.5)).
setPrincipalPoint(Point2D principalPoint) MapCameraUpdate
Creates an update to change the map camera's principal point (where the view vector intersects the image plane - default is the center of the view).
setVerticalFieldOfView(double verticalFieldOfView) MapCameraUpdate
Creates an update to change the vertical field of view of the map camera.
zoomBy(double factor, Point2D origin) MapCameraUpdate
Creates an update to zoom map camera by a given factor preserving a given focus point.
zoomTo(double zoomLevel) MapCameraUpdate
Creates an update to move map camera's viewpoint to a particular zoom level by adjusting its position.