1

I'm trying to use custom style with Cloud Map ID for google maps flutter. As always, I got the default style for maps even if I already define the cloud map id in google maps widget.

When I take a look at the console

D/MapsInitializer(32388): preferredRenderer: LATEST
D/zzcc    (32388): preferredRenderer: LATEST
I/zzcc    (32388): Making Creator dynamically
2
W/ziparchive(32388): Unable to open '/data/user_de/0/com.google.android.gms/app_chimera/m/00000002/DynamiteLoader.dm': No such file or directory
I/DynamiteModule(32388): Considering local module com.google.android.gms.maps_core_dynamite:0 and remote module com.google.android.gms.maps_core_dynamite:203115000
I/DynamiteModule(32388): Selected remote version of com.google.android.gms.maps_core_dynamite, version >= 203115000
V/DynamiteModule(32388): Dynamite loader version >= 2, using loadModule2NoCrashUtils
2
W/ziparchive(32388): Unable to open '/data/user_de/0/com.google.android.gms/app_chimera/m/00000006/MapsDynamite.dm': No such file or directory
I/Google Maps Android API(32388): Google Play services client version: 18020000
I/Google Maps Android API(32388): Google Play services package version: 231818044
I/Google Maps Android API(32388): Google Play services maps renderer version(legacy): 203115000
D/MapsInitializer(32388): loadedRenderer: LEGACY
W/Google Maps Android API(32388): MapId is not supported with the legacy renderer.
I/PlatformViewsController(32388): Hosting view in a virtual display for platform view: 0
E/FrameEvents(32388): updateAcquireFence: Did not find frame.
E/BufferQueueProducer(32388): [SurfaceTexture-0-32388-0](id:7e8400000002,api:1,p:32388,c:32388) connect: already connected (cur=1 req=1)
I/GoogleMapController(32388): No TextureView found. Likely using the LEGACY renderer.
E/OpenGLRenderer(32388): Unable to match the desired swap behavior.

I wonder why I always get the Legacy Renderer so the config for Cloud Map ID is not used. I already initialize the map Renderer so that the preferredRenderer is Latest.

final GoogleMapsFlutterPlatform mapsImplementation =
      GoogleMapsFlutterPlatform.instance;
  if (mapsImplementation is GoogleMapsFlutterAndroid) {
    WidgetsFlutterBinding.ensureInitialized();
    mapRenderer = await mapsImplementation
        .initializeWithRenderer(AndroidMapRenderer.latest);
  }

What am I doing wrong?

1
  • Is the latest renderer still not working on your end? You can check out my answer here: stackoverflow.com/a/77485344/18422887 for the explanation on how the Latest renderer could be loaded. But make sure that you have the following: 1. You're using a virtual device with Google Play. 2. Make sure that you have finished the set up your device prompt to enable Google Play. 3. as long as you follow the guide in the Add the map ID to your app Cloud Based Maps Styling should work fine. 4. Make sure that when creating/using a Map ID, it has Android as its type. Commented Jan 4, 2024 at 0:33

1 Answer 1

-1

If you want to change map style, use setMapStyle in onMapCreated. Download json from cloud map style.

Sign up to request clarification or add additional context in comments.

1 Comment

Nah, i want to use the dataset also from cloud map by using the cloud id, and it will only be achieve by rendering the LATEST renderer. The usage of json map style is used in LEGACY and I want to try to achieve the latest implementation of setting the map style first.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.