diff options
author | Ander Conselvan de Oliveira <ander.deoliveira@mapbox.com> | 2019-03-07 15:43:06 +0200 |
---|---|---|
committer | Ander Conselvan de Oliveira <ander.deoliveira@mapbox.com> | 2019-03-14 18:33:11 +0200 |
commit | a73cc9d8e363b0b3f4fa66c5d9c34625dffbb7e5 (patch) | |
tree | ad0b4cd4349a17a8f4c3bc6ec9f5bbbf0c25f1dd /test | |
parent | dba40c64ea8175b5dbf1cd043b3bc40730e13956 (diff) | |
download | qtlocation-mapboxgl-a73cc9d8e363b0b3f4fa66c5d9c34625dffbb7e5.tar.gz |
[core] Remove support for setting minimum and maximum pitch
Support for limiting pitch was introduced in commit c4fc89977bcb ([core]
Added {set,get}{Min,Max}Pitch) in 2017 but was never exposed by the
platform SDKs. Simplify the Map interface by removing this unused
feature.
v2: Add util::PITCH_MIN
Diffstat (limited to 'test')
-rw-r--r-- | test/map/transform.test.cpp | 19 |
1 files changed, 0 insertions, 19 deletions
diff --git a/test/map/transform.test.cpp b/test/map/transform.test.cpp index 04b9c1a931..441794886d 100644 --- a/test/map/transform.test.cpp +++ b/test/map/transform.test.cpp @@ -761,22 +761,3 @@ TEST(Transform, LatLngBounds) { transform.moveBy(ScreenCoordinate { 500, 0 }); ASSERT_DOUBLE_EQ(transform.getLatLng().longitude(), 120.0); } - -TEST(Transform, PitchBounds) { - Transform transform; - transform.resize({ 1000, 1000 }); - - transform.jumpTo(CameraOptions().withCenter(LatLng()).withZoom(transform.getState().getMaxZoom())); - - ASSERT_DOUBLE_EQ(transform.getState().getPitch() * util::RAD2DEG, 0.0); - ASSERT_DOUBLE_EQ(transform.getState().getMinPitch() * util::RAD2DEG, 0.0); - ASSERT_DOUBLE_EQ(transform.getState().getMaxPitch() * util::RAD2DEG, 60.0); - - transform.setMinPitch(45.0 * util::DEG2RAD); - transform.jumpTo(CameraOptions().withPitch(0)); - ASSERT_NEAR(transform.getState().getPitch() * util::RAD2DEG, 45.0, 1e-5); - - transform.setMaxPitch(55.0 * util::DEG2RAD); - transform.jumpTo(CameraOptions().withPitch(60.0)); - ASSERT_NEAR(transform.getState().getPitch() * util::RAD2DEG, 55.0, 1e-5); -} |