Label Namespace

Usage of the SDK constitutes your agreement with the Matterport SDK Agreement. Email developers@matterport.com with any questions.

Index

Enumerations

Types

Methods

Types

Label

Label: object

Type declaration

  • floor: number
  • floorInfo: object
    • id: string
    • sequence: number
  • position: Vector3
  • screenPosition: Vector2
  • sid: string
  • text: string
  • visible: boolean

Methods

getData

  • This function returns the data of all labels.

    mpSdk.Label.getData()
      .then(function(labels) {
        // Label data retrieval complete.
        console.log('Total labels: ' + labels.length);
        console.log('Text of first label: ' + labels[0].text);
        console.log('On-screen position of first label: ' + JSON.stringify(labels[0].position));
      })
      .catch(function(error) {
        // Label data retrieval error.
      });
    

    Returns Promise<Label.Label[]>