草庐IT

Geolocation

全部标签

android - 确定点是否在多边形中

根据我的要求,我正在谷歌地图上绘制多边形,如下图所示。(使用mapv2)现在我需要在用户输入特定多边形时显示警报。如何确定我当前的位置是否在多边形中。(需要优化方式而不耗尽电池)提前致谢。 最佳答案 刚刚尝试了识别多边形中的点的光线转换算法。这很完美。请参阅http://en.wikipedia.org/wiki/Point_in_polygon用于光线转换的论文privatebooleanisPointInPolygon(LatLngtap,ArrayListvertices){intintersectCount=0;for(in

android - Cordova 地理定位精度上限为 10 米

更新:这是一个GooglePlay服务问题,内部报告here将从版本13.4.0开始修复我们使用cordovagelocationplugin以及带有选项enableHighAccuracy:true的方法navigator.geolocation.watchPosition()来跟踪用户位置并获得最准确的结果。我们的应用程序已经存在1年多了,过去我们可以毫无问题地使用任何设备来获得非常好的定位精度,户外时4/6米,天空晴朗。最近,我们的许多用户报告说,无论他们做什么,都无法获得低于10m的精度。我们决定自己测试它,我们发现有同样的问题。最初,我们认为我们在最新版本中引入了一些错误,我

android - Cordova 地理定位精度上限为 10 米

更新:这是一个GooglePlay服务问题,内部报告here将从版本13.4.0开始修复我们使用cordovagelocationplugin以及带有选项enableHighAccuracy:true的方法navigator.geolocation.watchPosition()来跟踪用户位置并获得最准确的结果。我们的应用程序已经存在1年多了,过去我们可以毫无问题地使用任何设备来获得非常好的定位精度,户外时4/6米,天空晴朗。最近,我们的许多用户报告说,无论他们做什么,都无法获得低于10m的精度。我们决定自己测试它,我们发现有同样的问题。最初,我们认为我们在最新版本中引入了一些错误,我

android - Phonegap/Cordova 地理定位无法在 Android 上运行

我无法在模拟器(即使我通过telnetgeofix)和设备上让Geolocation在Android上运行。适用于iOS、WP8和浏览器。当我使用以下代码向设备询问位置时,我总是收到错误消息(在我的情况下,自定义Retrievingyourpositionfailedforunknownreason.withnull两个错误代码和错误信息)。相关代码:successHandler=(position)->resolveApp.Location.createlat:position.coords.latitudelng:position.coords.longitudeerrorHand

android - Phonegap/Cordova 地理定位无法在 Android 上运行

我无法在模拟器(即使我通过telnetgeofix)和设备上让Geolocation在Android上运行。适用于iOS、WP8和浏览器。当我使用以下代码向设备询问位置时,我总是收到错误消息(在我的情况下,自定义Retrievingyourpositionfailedforunknownreason.withnull两个错误代码和错误信息)。相关代码:successHandler=(position)->resolveApp.Location.createlat:position.coords.latitudelng:position.coords.longitudeerrorHand

android - 在 Android 中同时使用 GPS 和 Network Provider

我在我的应用中实现了一个位置监听器,它使用了网络提供者。这一切都很好,因为我想要一个快速的位置,并且使用GPS提供程序需要很长时间。但我的应用程序中的位置必须准确(最大5-10米)。我想知道是否可以同时使用GPS提供商和网络提供商,然后获得两者的最佳结果?是否也可以让我知道GPS提供商何时向我提供了GPS位置?所以基本上:LocationManagerlm=(LocationManager)getSystemService(Context.LOCATION_SERVICE);lm.requestLocationUpdates(LocationManager.NETWORK_PROVID

android - 在 Android 中同时使用 GPS 和 Network Provider

我在我的应用中实现了一个位置监听器,它使用了网络提供者。这一切都很好,因为我想要一个快速的位置,并且使用GPS提供程序需要很长时间。但我的应用程序中的位置必须准确(最大5-10米)。我想知道是否可以同时使用GPS提供商和网络提供商,然后获得两者的最佳结果?是否也可以让我知道GPS提供商何时向我提供了GPS位置?所以基本上:LocationManagerlm=(LocationManager)getSystemService(Context.LOCATION_SERVICE);lm.requestLocationUpdates(LocationManager.NETWORK_PROVID

android - 将 GeoPoint 转换为位置

我知道这是一个非常愚蠢的问题——但是转换GeoPoint的最佳方法是什么?到Location在Android平台上。 最佳答案 doublelatitude=geoPoint.getLatitudeE6()/1E6;doublelongitude=geoPoint.getLongitudeE6()/1E6;location.setLatitude(latitude);location.setLongitude(longitude); 关于android-将GeoPoint转换为位置,我们

android - 将 GeoPoint 转换为位置

我知道这是一个非常愚蠢的问题——但是转换GeoPoint的最佳方法是什么?到Location在Android平台上。 最佳答案 doublelatitude=geoPoint.getLatitudeE6()/1E6;doublelongitude=geoPoint.getLongitudeE6()/1E6;location.setLatitude(latitude);location.setLongitude(longitude); 关于android-将GeoPoint转换为位置,我们

android - 在没有谷歌播放服务的情况下获取位置-android

我知道有些手机没有预装谷歌播放服务。我想问是否有可能在没有GooglePlayServices的情况下获取位置,只需使用LocationManager。不是LocationClient。 最佳答案 你可以使用LocationManagerLocationManagerlocationManager=(LocationManager)getApplicationContext().getSystemService(LOCATION_SERVICE);Locationlocation=locationManager.getLastKno