MikeMurko
MikeMurko

Reputation: 2233

W3C Geolocation speed specification

In the Geolocation API spec, the W3C specified the speed property of the coordinates interface as

The speed attribute denotes the magnitude of the horizontal component of the hosting device's current velocity and is specified in meters per second. If the implementation cannot provide speed information, the value of this attribute must be null. Otherwise, the value of the speed attribute must be a non-negative real number.

What is the reason behind only the horizontal component is being used? If a user were to move "vertically" (by this I assume along a line of longitude), would their speed be returned as zero?

I found this changelog and it appears the wording was changed from "ground speed" to "magnitude of horizontal component" in 2011. Is this implementation left up to the browsers?

Upvotes: 1

Views: 280

Answers (1)

AlexWien
AlexWien

Reputation: 28727

horicontaly means: moving on the ground in any direction (changes in latitude / longitude)

vertically means moving up into the air (changes in altitude)

further horicontal error therefore means error related to 2d position (lat +lon) vertical error: eror in altitude.

Upvotes: 1

Related Questions