Skip to content
This repository was archived by the owner on Aug 8, 2023. It is now read-only.
This repository was archived by the owner on Aug 8, 2023. It is now read-only.

My Location indicator does not get tilted #7086

Closed

Description

@ahuang13

Tilting the map does not immediately tilt the My Location blue dot indicator. (However, tilting the map a second time will then cause the My Location indicator to get tilted.)

Platform: Android
Mapbox SDK version: 4.2.0-beta.5

Steps to trigger behavior

  1. Start out with map showing the My Location indicator.

device-2016-11-15-161227

  1. Tilt the map by calling the following tiltCamera() method.
private void tiltCamera() {
    final CameraPosition cameraPosition = new CameraPosition.Builder().tilt(MapboxConstants.MAXIMUM_TILT).build();
    final CameraUpdate cameraUpdate = CameraUpdateFactory.newCameraPosition(cameraPosition);
    mMapboxMap.moveCamera(cameraUpdate);
}

Expected behavior

I expect both the map and the My Location indicator to be tilted as such... (note that calling tiltCamera() a second time will achieve this result.)

device-2016-11-15-161248

Actual behavior

Only the map gets tilted. The My Location indicator remains in its original perspective as seen here...

device-2016-11-15-161239

Activity

  1. ahuang13 commented on Nov 16, 2016

    @ahuang13
    Author

    I noticed that the problem happens with all of the below camera methods...

    • moveCamera(CameraUpdate)
    • easeCamera(CameraUpdate)
    • animateCamera(CameraUpdate)

    However, when I add a sufficiently long duration (~1 second or more) to easeCamera(...) and animateCamera(...), the My Location indicator will get tilted.

  2. added
    Android
    on Nov 16, 2016
  3. tobrun commented on Nov 17, 2016

    @tobrun
    Member

    Thank you for the detailed explanation @ahuang13. It seems that setting tilt while out of screen is not getting applied. Tilt isn't changed as part of onDraw and is only set when we explicitly call setTilt.

  4. added this to the android-v5.0.0 milestone on Jan 20, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Android

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions