-
Notifications
You must be signed in to change notification settings - Fork 1
nearby.js
Finds artworks in the vicinity of the user that does not have coordinates associated.
Nearby
Finds nearby artworks.
getList(nearby, distFromPMerid, distFromEquator, Lat, callback)
Creates a list of artworks close to the user.
@param nearby - The nearby object.
@param distFromPMerid - Distance from user to prime meridian (in meters).
@param distFromEquator - Distance from the user to the equator (in meters).
@param lat - Latitude of user.
@param callback - If nearby artworks are found, this functions will called with the list of found artworks as an argument.
getUnlocated(position, successCallback, failCallback)
Finds artworks close to the user.
@param position - The user position. Should be an object with this format: {"latitude": lat, "longitude": lng}.
@param successCallback - If nearby artworks are found, this functions will called with the list of found artworks as an argument.
@param failCallback - (Not used yet).
distanceFromPrimeMeridian(longitude, latitude)
Calculates the distance from the Prime meridian.
@param longitude - The longitude.
@param latitude - The latitude.
@return The distance.
distanceFromEquator(latitude)
Calculates the distance from the Equator.
@param latitude - the latitude of the user
@return The distance from the equator.
distFromPMeridToLong(distance, latitude)
Calculate the user's longitude from the user's distance to the prime meridian.
@param distance - The users distance from the Prime meridian.
@param latitude - The users latitude.
@return The longitude of the user.
distFromEquatorToLat(distance)
Calculate the user's latitude from the user's distance to the equator.
@param distance - the distance from the equator.
@return The users latitude.
toRadians(degrees)
@param degrees - Angle in degrees.
@return The angle in radians.
calculateBBox(topDist, botDist, leftDist, rightDist, latitude)
Calculates a bounding box with edges at topDist, botDist, leftDist and rightDist.
@param topDist - The distance from the equator to the top edge.
@param botDist - The distance from the equator to the bottom edge.
@leftDist - The distance from the Prime Meridian to the left edge.
@rightDist - The distance from the Prime Meridian to the right edge.
@latitude - The latitude of the user.
###Main Pages
###Javascript files
###Project directories
###About WAKT