【问题标题】:How does CLLocationManager distanceFilter work? Don't you need an update to know where the phone is?CLLocationManager distanceFilter 是如何工作的?你不需要更新来知道手机在哪里吗?
【发布时间】:2011-01-23 18:24:15
【问题描述】:

我想知道 CLLocationManager 的 distanceFilter 是如何工作的。根据文档,

 The minimum distance (measured in meters) a device must move laterally before an update event is generated.

那么电话是否已经收集到位置,但 distanceFilter 只是阻止我的回电得到通知?

我看不出使用 distanceFilter 是如何节省电池寿命的,它看起来像是 Catch-22。

【问题讨论】:

  • 也许它会根据您当前的速度降低其轮询率?

标签: iphone objective-c iphone-sdk-3.0 geolocation cllocationmanager


【解决方案1】:

我相信quantumpotato 的评论很接近。不管怎样,通过 Apple 自己的测试,他们已经确定了必须在天线上使用什么功率级别才能在一定精度内获得读数。

作为使用过这个 API 的人,我同意你的看法,它并不完美,而且有点误导。将这些标志视为“所需级别”,根据您要制作的应用类型,您只需选择一个即可。

【讨论】:

    猜你喜欢
    • 2016-12-13
    • 2011-08-26
    • 1970-01-01
    • 2013-09-07
    • 2019-04-10
    • 2021-11-16
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多