AnnotationLayoutConfig class
Configuration for AnnotationLayoutEngine.layout.
Constructors
- AnnotationLayoutConfig({required double annotationWidth, required double annotationHeight, required double maxVisibleDistance, required double paddingOverlap, double? yOffsetOverlap, double cameraFieldOfView = defaultCameraFieldOfView, double previewAspectRatio = defaultPreviewAspectRatio, bool useAltitude = false, double rowHysteresis = 24, bool hideWithinLocationAccuracy = false, int? maxRows, bool scaleWithDistance = false, double minScale = defaultMinScale, double horizontalSpacing = 4})
-
const
Properties
- annotationHeight → double
-
final
- annotationWidth → double
-
final
- cameraFieldOfView → double
-
Field of view of the camera along its long side, in degrees.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- hideWithinLocationAccuracy → bool
-
Hide POIs closer than the user location's accuracy: their bearing is
meaningless when the user could be on either side of them.
final
- horizontalSpacing → double
-
Minimum horizontal gap, in pixels, between two labels on the same row.
final
- maxRows → int?
-
Maximum number of overlap rows a label can be stacked on (the natural
position counting as the first one). Labels are also never stacked
above the top of the screen. Annotations that do not fit are grouped
into an overlapping visible one, see AnnotationLayoutResult.groups.
Null means limited by the screen height only.
final
- maxVisibleDistance → double
-
final
- minScale → double
-
final
- paddingOverlap → double
-
final
- previewAspectRatio → double
-
Aspect ratio (long side / short side) of the camera preview.
final
- rowHysteresis → double
-
Extra horizontal clearance, in pixels, a label needs before moving
back down to a lower row than the one it had in the previous layout.
Prevents labels from flickering between rows while the device moves.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- scaleWithDistance → bool
-
Shrink labels linearly with their distance, from 1 next to the user to
minScale at maxVisibleDistance.
final
- useAltitude → bool
-
Place POIs above/below the horizon from the altitude difference with
the user. Off by default: it requires POI altitudes in the same
reference as the GPS altitude (and not left to 0), otherwise POIs end
up far below the horizon wherever the user is at high altitude.
final
- yOffsetOverlap → double?
-
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.
inherited
Constants
- defaultCameraFieldOfView → const double
- Used when the real camera field of view cannot be read from the device.
- defaultMinScale → const double
- Scale of a label at maxVisibleDistance when scaleWithDistance.
- defaultPreviewAspectRatio → const double
- Most phone camera sensors are 4:3.