Main Content

reset

Reset the CurrentTime property of velodyneFileReader object to the default value

Description

example

reset(veloReader) resets the CurrentTime property of velodyneFileReader to the default value. The default value is the StartTime property of velodyneFileReader.

Examples

collapse all

Construct velodyneFileReader object.

veloReader = velodyneFileReader('lidarData_ConstructionRoad.pcap','PuckLITE');

Inspect the properties of the velodyneFileReader object to know the CurrentTime. The default value of CurrentTime is the value of StartTime.

veloReader
veloReader = 
  velodyneFileReader with properties:

           FileName: '/mathworks/devel/bat/filer/batfs1904-0/Bdoc24a.2528353/build/matlab/toolbox/vision/visiondata/lidarData_ConstructionRoad.pcap'
        DeviceModel: 'PuckLITE'
    CalibrationFile: '/mathworks/devel/bat/filer/batfs1904-0/Bdoc24a.2528353/build/matlab/toolbox/shared/pointclouds/utilities/velodyneFileReaderConfiguration/PuckLITE.xml'
     OrganizePoints: 1
     NumberOfFrames: 40
           Duration: 1.9982 sec
          StartTime: 1145.1 sec
            EndTime: 1147.1 sec
         Timestamps: [1145.1 sec    1145.1 sec    1145.2 sec    1145.2 sec    1145.3 sec    1145.3 sec    1145.4 sec    1145.4 sec    1145.5 sec    1145.5 sec    1145.6 sec    1145.6 sec    1145.7 sec    1145.7 sec    ...    ] (1x40 duration)
    HasPositionData: 1
        CurrentTime: 1145.1 sec

Use readFrame to read a point cloud frame from the velodyneFileReader object.

frameNumber = 30;
ptCloud = readFrame(veloReader,frameNumber);

Inspect the CurrentTime property of velodyneFileReader object.

veloReader.CurrentTime
ans = duration
   1146.6 sec

Reset the CurrentTime property of velodyneFileReader object.

reset(veloReader)

Inspect the CurrentTime property and verify that its value is reset to the default value.

veloReader.CurrentTime
ans = duration
   1145.1 sec

Input Arguments

collapse all

Velodyne file reader, specified as a velodyneFileReader object.

Version History

Introduced in R2018a