FollowPuckViewportState class final
A ViewportState that configures the camera to follow the user's location indicator (puck).
The FollowPuckViewportState adjusts the camera to continuously track the user's current location on the map.
Note: Location should be enabled to use this viewport state.
Note: It is recommended to use only the DefaultViewportTransition animation option when transitioning to the FollowPuckViewportState, as it smoothly handles the moving user location puck.
- Inheritance
-
- Object
- ViewportState
- FollowPuckViewportState
Constructors
- FollowPuckViewportState({double? zoom = 16.35, FollowPuckViewportStateBearing? bearing = const FollowPuckViewportStateBearingHeading(), double? pitch = 45, MbxEdgeInsets? padding})
-
Creates a FollowPuckViewportState that configures the camera to follow the user's location indicator.
const
Properties
- bearing → FollowPuckViewportStateBearing?
-
The bearing behavior of the map.
final
- hashCode → int
-
The hash code for this object.
no setteroverride
- padding → MbxEdgeInsets?
-
The value to use for setting CameraOptions.padding. If null, padding will not be modified by the FollowPuckViewportState.
final
- pitch → double?
-
The pitch of the camera toward the horizon, in degrees.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- zoom → double?
-
The zoom level of the map.
final
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.
override