Skip to main content
←API Reference ←NSDK ←NSDKFrameData

GpsData


Declaration​

struct GpsData

Summary​

GPS location data for geographic positioning. This structure contains location information from the device's GPS system, providing geographic coordinates and accuracy estimates for location-based AR features and location positioning.


Constructors​

init(timestampMs: UInt64, latitude: Double, longitude: Double, altitude: Double, verticalAccuracy: Float, horizontalAccuracy: Float)

Summary​

Creates GPS data with the specified location parameters.

Parameters​

NameTypeSummary
timestampMsUInt64
Timestamp of the GPS reading in milliseconds
latitudeDouble
Latitude in decimal degrees
longitudeDouble
Longitude in decimal degrees
altitudeDouble
Altitude in meters above the WGS84 ellipsoid (use
CLLocation.ellipsoidalAltitude, not CLLocation.altitude)
verticalAccuracyFloat
Vertical accuracy in meters
horizontalAccuracyFloat
Horizontal accuracy in meters

Properties​

NameTypeSummary
var altitudeDouble
Altitude in meters above the WGS84 ellipsoid (not mean sea level). When
taking it from a CLLocation, use ellipsoidalAltitude, not altitude.
Accuracy depends on GPS signal quality and atmospheric conditions.
var horizontalAccuracyFloat
Horizontal accuracy of the position measurement in meters.
Lower values indicate more accurate position readings. Values under
5 meters are considered good accuracy for most AR applications.
var latitudeDouble
Latitude coordinate in decimal degrees.
Positive values represent locations north of the equator,
negative values represent locations south of the equator.
var longitudeDouble
Longitude coordinate in decimal degrees.
Positive values represent locations east of the Prime Meridian,
negative values represent locations west of the Prime Meridian.
var timestampMsUInt64
Timestamp when the GPS reading was captured (in milliseconds).
var verticalAccuracyFloat
Vertical accuracy of the altitude measurement in meters.
Lower values indicate more accurate altitude readings. GPS altitude
is typically less accurate than horizontal position.

Operators​

NameTypeSummary
static func != Bool
Returns a Boolean value indicating whether two values are not equal.
Inequality is the inverse of equality. For any values a and b, a != b
implies that a == b is false.
This is the default implementation of the not-equal-to operator (!=)
for any type that conforms to Equatable.

Relationships​

conforms to: Swift.Equatable