Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clustering: add setter for clusterDistancePoints in the GMUNonHierarchicalDistanceBasedAlgorithm.m #452

Open
vorokami opened this issue Aug 28, 2023 · 2 comments
Labels
triage me I really want to be triaged. type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design.

Comments

@vorokami
Copy link

In googlemaps/android-maps-utils in distance based algorithms we have a method setMaxDistanceBetweenClusteredItems() to change the distance between markes when clustering is active. It will be great if we have this functionality for iOS too.


Example of using this variable in Android:

        if (this.googleMap.getCameraPosition().zoom < 13) {
            mClusterManager.getAlgorithm().setMaxDistanceBetweenClusteredItems(CapacitorGoogleMaps.maxDistanceBetweenClusteredItems);
        } else {
            mClusterManager.getAlgorithm().setMaxDistanceBetweenClusteredItems((int) (thisDeviceIconSize / 2));
        }

Example of possible using this method in iOS:

        if (cameraPosition.zoom < 13 ) {
            self.mClusterManager.algorithm.setClusterDistancePoints(CapacitorGoogleMapsPlugin.maxDistanceBetweenClusteredItems)
        } else {
            self.mClusterManager.algorithm.setClusterDistancePoints(UInt(CapacitorGoogleMapsPlugin.SIZE_OF_MARKERS.width)/2)
        }
@vorokami vorokami added triage me I really want to be triaged. type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design. labels Aug 28, 2023
@wangela
Copy link
Member

wangela commented Aug 28, 2023

If you would like to upvote the priority of this issue, please comment below or react on the original post above with 👍 so we can see what is popular when we triage.

@vorokami Thank you for opening this issue. 🙏
Please check out these other resources that might help you get to a resolution in the meantime:

This is an automated message, feel free to ignore.

@enoler
Copy link

enoler commented Oct 18, 2024

Totally agree! I also need this implementation as I would like to be able to decide in which level of zoom I would like the markers to be clustered.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
triage me I really want to be triaged. type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design.
Projects
None yet
Development

No branches or pull requests

3 participants