Main Content

lidar.syncImageViewer.SyncImageViewer Class

Namespace: lidar.syncImageViewer

Interface to connect external tool to Lidar Labeler app

Since R2020b

Description

The lidar.syncImageViewer.SyncImageViewer class creates an interface between a custom visualization or analysis tool and a point cloud signal in the Lidar Labeler app. You can use the SyncImageViewer class to sync video and image sequence signals to the app only.

Creation

The SyncImageViewer specifies the interface for connecting an external tool to the Lidar Labeler app. An external tool can be a custom visualization tool or custom analysis tool. The class that inherits from the SyncImageViewer interface is called the client. The client performs these tasks:

  • Syncs an external tool to each frame change event for a specific signal loaded into the Lidar Labeler app. Syncing enables you to control the external tool through the range slider and playback controls of the app.

  • Controls the current time in the external tool and the corresponding display in the app.

To connect an external tool to the Lidar Labeler app, follow these steps:

  1. Define a client class that inherits from lidar.syncImageViewer.SyncImageViewer. You can use the SyncImageViewer class template to define a class and implement your custom visualization or analysis tool. At the MATLAB® command prompt, enter this code:

    lidar.syncImageViewer.SyncImageViewer.openTemplateInEditor
    Follow the steps in the template.

  2. Save the file to any folder on the MATLAB path. Alternatively, save the file to a folder outside the MATLAB path and add the folder to MATLAB path by using the addpath function.

Properties

expand all

Start time of the signal, specified as a real scalar in seconds.

Attributes:

GetAccess
public
SetAccess
private

End time of the signal, specified as a real scalar in seconds.

Attributes:

GetAccess
public
SetAccess
private

Start of the time interval in the app, specified as a real scalar in seconds. To set the start time, use the start flag interval in the app.

Attributes:

GetAccess
public
SetAccess
private

Time of the frame currently displaying in the app for the connected signal, specified as a real scalar in seconds. If the slider is between two timestamps, then the currently displaying frame is the frame that is at the previous timestamp.

Attributes:

GetAccess
public
SetAccess
private

End of the time interval in the app, specified as a real scalar in seconds. To set the end time, use the end flag interval in the app.

Attributes:

GetAccess
public
SetAccess
private

Timestamps for the connected signal, specified as a duration vector.

Attributes:

GetAccess
public
SetAccess
private

Methods

expand all

Examples

collapse all

Connect an image display tool to the Lidar Labeler app. Use the app and tool to display synchronized lidar and image data.

Specify the name of the lidar data to load into the app.

sourceName = fullfile("lidarSequence");

Connect the video display to the app and display synchronized data.

lidarLabeler(sourceName,"SyncImageViewerTargetHandle",@helperSyncImageDisplay);

Tips

  • For an example of an external tool, see the SyncImageDisplay implementation of the lidar.syncImageViewer.SyncImageViewer class. This class implements an image display tool. You can use this code as a starting point for creating your own tools.

    edit SyncImageDisplay

Version History

Introduced in R2020b

See Also

Apps