Main Content

removeBoundaries

Remove lane boundaries from lane boundary segment object

Since R2024a

Description

example

lbsegmentUpdated = removeBoundaries(lbsegment,boundaryIDs) removes the lane boundaries with the specified boundary IDs boundaryIDs, and their relative boundary information, from the laneBoundarySegment object lbsegment, and returns an updated laneBoundarySegment object, lbsegmentUpdated.

Note

This function requires the Scenario Builder for Automated Driving Toolbox™ support package. You can install the Scenario Builder for Automated Driving Toolbox support package from the Add-On Explorer. For more information about installing add-ons, see Get and Manage Add-Ons.

Examples

collapse all

Load lane boundary segment data into the workspace.

data = load("laneBoundarySegmentData.mat","lbsegment");

Display the loaded lane boundary segment object.

lbsegment = data.lbsegment
lbsegment = 
  laneBoundarySegment with properties:

       BoundaryIDs: [4×1 string]
    BoundaryPoints: {4×1 cell}
      BoundaryInfo: []
     NumBoundaries: 4
         NumPoints: 128
      GeoReference: []

Remove the lane boundary with the ID 3 from the loaded lane boundary segment object. Display the lane boundary segment object.

lbsegment = removeBoundaries(lbsegment,"3")
lbsegment = 
  laneBoundarySegment with properties:

       BoundaryIDs: [3×1 string]
    BoundaryPoints: {3×1 cell}
      BoundaryInfo: []
     NumBoundaries: 3
         NumPoints: 128
      GeoReference: []

Input Arguments

collapse all

Lane boundary segment, specified as a laneBoundarySegment object.

Lane boundary IDs, specified as an N-by-1 string array. N is the number of lane boundaries.

Note

Each lane boundary ID value must be unique.

Data Types: string

Output Arguments

collapse all

Updated lane boundary segment, returned as a laneBoundarySegment object.

The returned laneBoundarySegment object lbsegmentUpdated does not contain the lane boundaries removed from the input laneBoundarySegment object lbsegment.

Version History

Introduced in R2024a