Skip to content

Clustering: Ability to set a BitmapDescriptor cache for custom cluster items (2.11 Clustering composable) #272

@Shusshu

Description

@Shusshu

Feature request

Add the ability to cache Bitmapdescriptor's to make the initial drawing smooth as not every single marker needs to recreate views

This is for both clusterContent & clusterItemContent

Solutions:

  1. Ability to specify a custom renderer (extending DefaultClusterRenderer)

Opening up the cluster manager to specify our own renderer would allow an easy way to support this feature by giving the developer the ability to build it himself

  1. Specify some cache keys in order to avoid recreating the bitmap descriptor for identical items (in renderViewToBitmapDescriptor)

  2. ...

More context

Currently, I have implemented Clustering using MapEffect and I was able to make my redrawing experience as smooth as possible by recreating only different markers

For example I have 3000+ points but in practice only +-20 different item markers

I apply the same caching for cluster groups by defining a few buckets.

The solution I currently have in mind also means I do not plan to use Compose to create markers & clusters, that's fine as my goal is to make the experience as smooth as possible.

Metadata

Metadata

Assignees

No one assigned

    Labels

    priority: p2Moderately-important priority. Fix may not be included in next release.type: feature request‘Nice-to-have’ improvement, new feature or different behavior or design.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions