Add min and max pitch options (#199)

* Add min and max pitch options

* Add min and max pitch into attrs

* Update gl-native submodule
This commit is contained in:
Kevin Li
2020-02-28 18:17:08 +08:00
committed by GitHub
parent 53f5015ca6
commit 17b19b3b4a
13 changed files with 287 additions and 8 deletions

View File

@@ -365,6 +365,66 @@ public final class MapboxMap {
return transform.getMaxZoom();
}
//
// MinPitch
//
/**
* <p>
* Sets the minimum Pitch the map can be displayed at.
* </p>
*
* <p>
* The default and lower bound for minPitch Pitch is 0.
* </p>
* @param minPitch The new minimum Pitch.
*/
public void setMinPitchPreference(
@FloatRange(from = MapboxConstants.MINIMUM_PITCH, to = MapboxConstants.MAXIMUM_PITCH) double minPitch) {
transform.setMinPitch(minPitch);
}
/**
* <p>
* Gets the minimum Pitch the map can be displayed at.
* </p>
*
* @return The minimum Pitch.
*/
public double getMinPitch() {
return transform.getMinPitch();
}
//
// MaxPitch
//
/**
* <p>
* Sets the maximum Pitch the map can be displayed at.
* </p>
* <p>
* The default and upper bound for maximum Pitch is 60.
* </p>
*
* @param maxPitch The new maximum Pitch.
*/
public void setMaxPitchPreference(@FloatRange(from = MapboxConstants.MINIMUM_PITCH,
to = MapboxConstants.MAXIMUM_PITCH) double maxPitch) {
transform.setMaxPitch(maxPitch);
}
/**
* <p>
* Gets the maximum Pitch the map can be displayed at.
* </p>
*
* @return The maximum Pitch.
*/
public double getMaxPitch() {
return transform.getMaxPitch();
}
//
// UiSettings
//