Skip to content

feat(animations): Add map steady check for better animations#20

Merged
dkhawk merged 2 commits into
mainfrom
feat/samples-for-map-steady
Oct 28, 2025
Merged

feat(animations): Add map steady check for better animations#20
dkhawk merged 2 commits into
mainfrom
feat/samples-for-map-steady

Conversation

@dkhawk

@dkhawk dkhawk commented Oct 24, 2025

Copy link
Copy Markdown
Collaborator

Demonstrates using maps3d.GoogleMap3D#setOnMapSteadyListener

Introduces a mechanism to wait for the map to be fully loaded and idle (isMapSteady) before initiating camera animations. This prevents animations from starting on a partially rendered or moving map, resulting in a better visual experience.

  • Adds awaitMapSteady() to Map3dViewModel to suspend execution until the map is stable, with an optional timeout.
  • Creates a new WaitUntilTheMapIsSteadyStep for use in declarative animation sequences.
  • Refactors ThreeDMap, ScenarioScreen, and CameraControlDemoScreen to pass the ViewModel directly, simplifying state management and removing the need for onMap3dViewReady and onReleaseMap callbacks.
  • Integrates the steady check into existing animation scenarios to ensure they begin from a stable map state.

Introduces a mechanism to wait for the map to be fully loaded and idle (isMapSteady) before initiating camera animations. This prevents animations from starting on a partially rendered or moving map, resulting in a smoother and more professional user experience.

- Adds awaitMapSteady() to Map3dViewModel to suspend execution until the map is stable, with an optional timeout.
- Creates a new WaitUntilTheMapIsSteadyStep for use in declarative animation sequences.
- Refactors ThreeDMap, ScenarioScreen, and CameraControlDemoScreen to pass the ViewModel directly, simplifying state management and removing the need for onMap3dViewReady and onReleaseMap callbacks.
- Integrates the steady check into existing animation scenarios to ensure they begin from a stable map state.
@dkhawk dkhawk requested a review from kikoso October 24, 2025 19:52

@kikoso kikoso left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! This can be merged.

@dkhawk dkhawk merged commit fbefa67 into main Oct 28, 2025
7 checks passed
@dkhawk dkhawk deleted the feat/samples-for-map-steady branch October 28, 2025 15:57
googlemaps-bot pushed a commit that referenced this pull request Oct 28, 2025
# [1.3.0](v1.2.0...v1.3.0) (2025-10-28)

### Features

* **animations:** Add map steady check for better animations ([#20](#20)) ([fbefa67](fbefa67))
@googlemaps-bot

Copy link
Copy Markdown

🎉 This PR is included in version 1.3.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants