Class: Image
viewer.Image
classdesc Represents a image in the navigation graph.
Explanation of position and bearing properties:
When images are uploaded they will have GPS information in the EXIF, this is what
is called originalLngLat Image.originalLngLat.
When Structure from Motions has been run for a image a computedLngLat that
differs from the originalLngLat will be created. It is different because
GPS positions are not very exact and SfM aligns the camera positions according
to the 3D reconstruction Image.computedLngLat.
At last there exist a lngLat property which evaluates to
the computedLngLat from SfM if it exists but falls back
to the originalLngLat from the EXIF GPS otherwise Image.lngLat.
Everything that is done in in the Viewer is based on the SfM positions,
i.e. computedLngLat. That is why the smooth transitions go in the right
direction (nd not in strange directions because of bad GPS).
E.g. when placing a marker in the Viewer it is relative to the SfM
position i.e. the computedLngLat.
The same concept as above also applies to the compass angle (or bearing) properties
originalCa, computedCa and ca.
Accessors#
cameraParameters#
• get cameraParameters(): number[]
Get cameraParameters.
description Will be undefined if SfM has
not been run.
Camera type dependent parameters.
For perspective and fisheye camera types, the camera parameters array should be constructed according to
[focal, k1, k2]
where focal is the camera focal length, and k1, k2 are radial distortion parameters.
For spherical camera type the camera parameters are unset or emtpy array.
Returns#
number[]
The parameters related to the camera type.
Defined in#
cameraType#
• get cameraType(): string
Get cameraType.
description Will be undefined if SfM has not been run.
Returns#
string
The camera type that captured the image.
Defined in#
capturedAt#
• get capturedAt(): number
Get capturedAt.
description Timestamp of the image capture date
and time represented as a Unix epoch timestamp in milliseconds.
Returns#
number
Timestamp when the image was captured.
Defined in#
clusterId#
• get clusterId(): string
Get clusterId.
Returns#
string
Globally unique id of the SfM cluster to which the image belongs.
Defined in#
compassAngle#
• get compassAngle(): number
Get compassAngle.
description If the SfM computed compass angle exists it will
be returned, otherwise the original EXIF compass angle.
Returns#
number
Compass angle, measured in degrees clockwise with respect to north.
Defined in#
computedAltitude#
• get computedAltitude(): number
Get computedAltitude.
description If SfM has not been run the computed altitude is
set to a default value of two meters.
Returns#
number
Altitude, in meters.
Defined in#
computedCompassAngle#
• get computedCompassAngle(): number
Get computedCompassAngle.
description Will not be set if SfM has not been run.
Returns#
number
SfM computed compass angle, measured in degrees clockwise with respect to north.
Defined in#
computedLngLat#
• get computedLngLat(): LngLat
Get computedLngLat.
description Will not be set if SfM has not been run.
Returns#
SfM computed longitude, latitude in WGS84 datum, measured in degrees.
Defined in#
creatorId#
• get creatorId(): string
Get creatorId.
description Note that the creator ID will not be set when using
the Mapillary API.
Returns#
string
Globally unique id of the user who uploaded the image.
Defined in#
creatorUsername#
• get creatorUsername(): string
Get creatorUsername.
description Note that the creator username will not be set when
using the Mapillary API.
Returns#
string
Username of the creator who uploaded the image.
Defined in#
exifOrientation#
• get exifOrientation(): number
Get exifOrientation.
Returns#
number
EXIF orientation of original image.
Defined in#
height#
• get height(): number
Get height.
Returns#
number
Height of original image, not adjusted for orientation.
Defined in#
id#
• get id(): string
Get id.
Returns#
string
Globally unique id of the image.
Defined in#
image#
• get image(): HTMLImageElement
Get image.
description The image will always be set on the current image.
Returns#
HTMLImageElement
Cached image element of the image.
Defined in#
lngLat#
• get lngLat(): LngLat
Get lngLat.
description If the SfM computed longitude, latitude exist
it will be returned, otherwise the original EXIF latitude
longitude.
Returns#
Longitude, latitude in WGS84 datum, measured in degrees.
Defined in#
mergeId#
• get mergeId(): string
Get mergeId.
description Will not be set if SfM has not yet been run on
image.
Returns#
string
Id of connected component to which image belongs after the aligning merge.
Defined in#
merged#
• get merged(): boolean
Get merged.
Returns#
boolean
Value indicating whether SfM has been run on the image and the image has been merged into a connected component.
Defined in#
mesh#
• get mesh(): MeshContract
Get mesh.
description The mesh will always be set on the current image.
Returns#
SfM triangulated mesh of reconstructed atomic 3D points.
Defined in#
originalAltitude#
• get originalAltitude(): number
Get originalAltitude.
Returns#
number
EXIF altitude, in meters, if available.
Defined in#
originalCompassAngle#
• get originalCompassAngle(): number
Get originalCompassAngle.
Returns#
number
Original EXIF compass angle, measured in degrees.
Defined in#
originalLngLat#
• get originalLngLat(): LngLat
Get originalLngLat.
Returns#
Original EXIF longitude, latitude in WGS84 datum, measured in degrees.
Defined in#
ownerId#
• get ownerId(): string
Get ownerId.
Returns#
string
Globally unique id of the owner to which the image belongs. If the image does not belong to an owner the owner id will be undefined.
Defined in#
private#
• get private(): boolean
Get private.
Returns#
boolean
Value specifying if image is accessible to organization members only or to everyone.
Defined in#
qualityScore#
• get qualityScore(): number
Get qualityScore.
description Value should be on the interval [0, 1].
Returns#
number
A number between zero and one determining the quality of the image. Blurriness (motion blur / out-of-focus), occlusion (camera mount, ego vehicle, water-drops), windshield reflections, bad illumination (exposure, glare), and bad weather condition (fog, rain, snow) affect the quality score.
Defined in#
rotation#
• get rotation(): number[]
Get rotation.
description Will not be set if SfM has not been run.
Returns#
number[]
Rotation vector in angle axis representation.
Defined in#
scale#
• get scale(): number
Get scale.
description Will not be set if SfM has not been run.
Returns#
number
Scale of reconstruction the image belongs to.
Defined in#
sequenceId#
• get sequenceId(): string
Get sequenceId.
Returns#
string
Globally unique id of the sequence to which the image belongs.
Defined in#
width#
• get width(): number
Get width.
Returns#
number
Width of original image, not adjusted for orientation.