gmsmapview

How can I check if a CLLocationCoordinate2D is inside four CLLocationCoordinate2D Square? in Objective C with Google Maps

佐手、 提交于 2019-12-06 01:37:09
问题 I want to test if a CLLocationCoordinate2D is inside a Square created from other four CLLocationCoordinate2D I have a struct like this: typedef struct { CLLocationCoordinate2D southWest; CLLocationCoordinate2D southEast; CLLocationCoordinate2D northEast; CLLocationCoordinate2D northWest; } Bounds; And a CLLocationCoordinate2D coordinate passed as param. And I want to test if coordinate is inside the Bounds. How can I test that? - (BOOL) isCoordinate:(CLLocationCoordinate2D)coordinate

How to apply animations to GMSMarker

浪尽此生 提交于 2019-12-05 12:29:51
I’m changing my app by migrating iOS maps to google maps using Google Maps SDK for iOS V1.1.0 and I’m trying to animate the markers while adding/removing but I didn’t find any suggestions in the documentation related to this, Please suggest me how to perform the animations on GMSMarkers Amozoss In the GMSMarker Class Reference , it says, for the appearAnimation property: Controls the animation used when this marker is placed on a GMSMapView (default kGMSMarkerAnimationNone , no animation). Using the Google Maps SDK for iOS , a marker can be made like this: GMSMarker *startMarker = [GMSMarker

how to show markers only in gmscircle region otherwise hide in ios

…衆ロ難τιáo~ 提交于 2019-12-04 21:19:41
how to show markers only in GMSCirle region otherwise hide in iOS , I have created GMSCirle using google maps, now I wanna display markers only on the region of GMSCirle otherwise hide markers. here is my code : GMSMarker *centerPoint=[GMSMarker markerWithPosition:CLLocationCoordinate2DMake(16.301687, 80.419235)]; centerPoint.icon=[UIImage imageNamed:@"PinImage.png"]; circ.fillColor = [UIColor colorWithRed:0.25 green:0 blue:0 alpha:0.05]; circ.strokeColor = [UIColor blackColor]; circ.strokeWidth = 5; circ.tappable=true; circ.map = mapView_; mapView_.settings.myLocationButton=YES; mapView_

Follow user location on google maps

老子叫甜甜 提交于 2019-12-04 18:16:15
I have google maps sdk on ios and enabled userlocation = yes. I want to get the user location via GPS when he moves. I could not find any method in document that returns me location updates as the user keeps moving. I want to keep my user in center of the screen by continuously then updating the camera using these location. Any points on this? There is a method didchangecameraposition which updates when i apply gestures on maps, but not when the gps gets updated. You cannot do it totally with the Google maps SDK, you got to use the CLLocationManger framework to get the location updates.

GoogleMaps (GMSView) Won't display in iOS

痴心易碎 提交于 2019-12-04 09:57:14
问题 I have incorporated the following: Tried importing both the GoogleMaps/GoogleMaps.h as well as the GoogleMapsM4B/GoogleMaps.h files through an Obj-C Bridging Header Manually typed out the iOS API key in my AppDelegate.swift (didFinishLaunchingWithOptions) method. Cleaned the project (command+shift+k) Closed/relaunched Xcode Uninstalled/reinstalled Xcode And pretty much everything else other people have suggested. I have spent two days straight trying to fix this problem. Does anyone know a

How can I check if a CLLocationCoordinate2D is inside four CLLocationCoordinate2D Square? in Objective C with Google Maps

谁都会走 提交于 2019-12-04 07:29:30
I want to test if a CLLocationCoordinate2D is inside a Square created from other four CLLocationCoordinate2D I have a struct like this: typedef struct { CLLocationCoordinate2D southWest; CLLocationCoordinate2D southEast; CLLocationCoordinate2D northEast; CLLocationCoordinate2D northWest; } Bounds; And a CLLocationCoordinate2D coordinate passed as param. And I want to test if coordinate is inside the Bounds. How can I test that? - (BOOL) isCoordinate:(CLLocationCoordinate2D)coordinate insideBounds:(Bounds)bounds { ... } If you have four points you can make a CGRect and use CGRectContainsPoint()

How to add marker for a map view in google maps sdk for ios in swift

北慕城南 提交于 2019-12-03 07:59:26
Trying to add a marker to Google map,but the app is getting crashed at while addMarker() function call,Exception details are as follows, Terminating app due to uncaught exception ' GMSThreadException ', reason: 'All calls to the Google Maps SDK for iOS must be made from the UI thread' FYI vwGogleMap is global and in a function I'm trying to plot marker. func addMarker() -> Void { var vwGogleMap : GMSMapView? var position = CLLocationCoordinate2DMake(17.411647,78.435637) var marker = GMSMarker(position: position) marker.title = "Hello World" marker.map = vwGogleMap } Any help would be

GMSMarker bouncing around the corners on GMSPolyline

泪湿孤枕 提交于 2019-12-01 22:01:57
问题 I am working on a navigation app and tracking user's current movement on an already drawn GMSPolyline. It works good when the user is going straight. Now if, suppose there is right / left turn or a u-turn on the GMSPolyline, now as per my GPS location I get one update around 20 meters before taking a turn and another after 30 meters. My GPS fails to collect the points that will exist just at the turning point. In this case my GMSMarker jumps from point x to y and if I apply animation then it

GMSMarker bouncing around the corners on GMSPolyline

那年仲夏 提交于 2019-12-01 21:27:35
I am working on a navigation app and tracking user's current movement on an already drawn GMSPolyline. It works good when the user is going straight. Now if, suppose there is right / left turn or a u-turn on the GMSPolyline, now as per my GPS location I get one update around 20 meters before taking a turn and another after 30 meters. My GPS fails to collect the points that will exist just at the turning point. In this case my GMSMarker jumps from point x to y and if I apply animation then it moves diagonally and does not move along the GMSPolyline arcs or curves. Please suggest me how can I

Google maps iOS sdk get tapped overlay coordinates

我只是一个虾纸丫 提交于 2019-12-01 06:22:07
i'm working with Google maps iOS sdk. i want to get the coordinates of the touched point when user taps an overlay. there is this delegate method: - (void)mapView:(GMSMapView *)mapView didTapAtCoordinate:(CLLocationCoordinate2D)coordinate but it's not called when you tap an overlay or a marker. can i call it programmatically (but coordinate parameter is missing-that's what i want..)? or get location from this: - (void) mapView: (GMSMapView *) mapView didTapOverlay: (GMSOverlay *) overlay any suggestion's precious! thanks! UPDATE 6/2/15 Just staple a UITapGestureRecognizer onto the map and then