Skip to content

Commit

Permalink
Add experimental 3D model customisation APIs. (#2826)
Browse files Browse the repository at this point in the history
* Add experimental 3D model customisation APIs.

Test 3d styling.

[wip] Add location component 3D model parts customisation.

Fix expression not being picked up.

Refactor ModelParts API to be generic.

Clean up and update docs.

Add wheel direction customisation example.

Add automatic blinker animation based on bearing, added support to play a pre-defined route.

Address review comments.

Expose color-mix-intensity.

Update stylegen pin.

Update stylespec and expose new properties.

Update api files.

Update changelog.

Update changelog.

Manually overload feature state APIs to avoid breaking change.

Fix ktlint

Fix jvm overload.

Add support for model opacity customization.

Add default opacity, default emissive strength and default color mix intensity setters.

Update api files.

Bump glnative snapshot to use latest changes for opacitiy.

Update api

* Add new properties to the end of Puck3D to avoid breaking changes in java API.

* Fix unit tests.

* Add support for car body color customisation.

* Address review comments.

* Fix rotation expression fallback.

* Move strings to constans

* Address review comments.

* Use double list for rotation, change function setter to vars, and use user set value to build expression's default value.

* Update stylegen pin.
  • Loading branch information
pengdev authored Nov 28, 2024
1 parent a975c25 commit 865e3df
Show file tree
Hide file tree
Showing 34 changed files with 2,125 additions and 104 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ Mapbox welcomes participation and contributions from everyone.
* [compose] Adds support for `fillZOffset` in `PolygonAnnotationState`, `PolygonAnnotationGroupState`.
* [compose] Expose `MapViewportState.cameraForCoordinates` method.
* [compose] Introduce `radius` parameter for all relevant compose functions for interactions to support an extra area around the interaction.
* Introduce experimental `AnimatableModel`, `ModelMaterialPart`, `ModelNodePart` APIs to style the 3D location puck's overridable parts.
* Introduce `modelRotationExpression`, `modelColor` `modelColorExpression`, `modelColorMixIntensity`, `modelColorMixIntensityExpression`, `modelOpacityExpression` on `LocationPuck3D`.
* Introduce experimental `LocationPuck3D.materialOverrides` and `LocationPuck3D.nodeOverrides` API to allow model parts overrides.

# 11.7.3 November 19, 2024
## Bug fixes 🐞
Expand Down
12 changes: 12 additions & 0 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -1402,5 +1402,17 @@
android:name="android.support.PARENT_ACTIVITY"
android:value=".ExampleOverviewActivity" />
</activity>
<activity
android:name=".examples.LocationComponentModelAnimationActivity"
android:description="@string/description_location_component_model_animation"
android:exported="true"
android:label="@string/activity_location_component_model_animation">
<meta-data
android:name="@string/category"
android:value="@string/category_location" />
<meta-data
android:name="android.support.PARENT_ACTIVITY"
android:value=".ExampleOverviewActivity" />
</activity>
</application>
</manifest>
Binary file added app/src/main/assets/ego_car.glb
Binary file not shown.
Loading

0 comments on commit 865e3df

Please sign in to comment.