Unity+Autoware Maptool Box plug-in draws vector Lanelet2 map

Preface

I recently started learning to make Lanelet2 vector maps for limited area autonomous driving projects. The records are as follows. Everyone is welcome to discuss and learn together:
##Referenced the following blogs: https://blog.csdn.net/So____/article/details/129566492< /span> https://blog.csdn.net/qq_33971022/article/details/ 109013661 https://blog.csdn.net/weixin_44570248/article/details/118463199
https://blog.csdn.net/ck784101777/article/details/108229534


1. Platform and software/plug-in installation

I am using Windows 11 + Unity Hub 3.3.0-c9 + Unity 2022.3.5f1c1 + Autoware Maptool Box plug-in. It is recommended to install Unity Hub first, and then install the recommended long-term support version of Unity in Unity Hub (the default version of Unity installed in this way installed on C drive).

1、Unity Hub :

Download the Windows version directly fromUnit Hub official websitehttps://unity.com/cn/download, and install it with the default options;< /span>Insert image description here

2、Unity:

Run Unity Hub, click Install in the left menu bar, select version installation;
You also need to activate Unity, set in the upper left corner----License Activation Personal Edition;
Insert image description here

3、Autoware Maptool Box :

Download the compressed package directly atGithub addresshttps://github.com/autocore-ai/MapToolbox/tree/vector_map, and then unzip it That’s it (the storage path cannot contain Chinese characters).

2. Configure Unity

Create Unity project and import Autoware Maptool Box

1. Create a new project:

Open Unity Hub----Project----New Project----3D, set the project name and storage location (Chinese cannot appear), uncheck "Enable version management and agree to policy terms", Then click Create Project;;
Wait for a few minutes and the interface will be as follows:
Insert image description here

2. Import Auoware Maptool Box

Click Window----Package Manager in the menu bar above the project interface, then click the "+" in the upper left corner of the pop-up interface----Add package from disk, and select the package in the Autoware Maptool Box decompression path .json file, wait half a minute, the loading is complete, that is, the plug-in import is completed.
Insert image description here
Insert image description here
Insert image description here
After the import is completed, right-click on the blank space of the left toolbar and the Autoware----AutowareADASMap tool will appear. After clicking, the lane lines, stop lines, and roads will be inserted in the right toolbar. Along with other tools.
Insert image description here

Notice:

In my version, after importing the plug-in, I right-clicked and the Autoware----AutowareADASMap toolkit did not appear. I later found that an error occurred after importing the plug-in:

Library\PackageCache\[email protected]\Editor\*******\:error

Find the Jobs----Version History----Updata update in Window----Package Manager, and you can add the Autoware----AutowareADASMap tool package.
Insert image description here

3. Create Lanelet2 vector map

1. Load pcd point cloud map

Add the pcd point cloud map in Project----Assets----Import New Asset in the lower left part of the project. After the loading is completed, the loaded map will appear in the scene below. Drag the map to the toolbar, and then adjust it to the appropriate Perspective, load the Maptool toolkit.
Insert image description here

2. Drawing

Take the road edge element as an example. Click Add Road Edge on the right side, and two overlapping coordinate axes will appear in the interface. At this time, you need to adjust the appropriate perspective and height value to keep the added road element at the same height. and record the height value.

Note: If the height error is too large, the position of the two coordinate axes will be set at one position, and the position will be misaligned if the angle of view is moved.

Insert image description here
Then adjust the angle of view so that x faces right and z faces upward (there is a lock where you adjust the angle of view for easy operation). After moving the two coordinate axes to the preset curb position, click AddAfter to continue adding the next paragraph. , if the added curb is a curve, first move the two coordinate axes to the starting point and end point of the curve, and then click Subdivision. Two coordinate axes will appear between the starting point and the end point. Adjust the curvature by adjusting these two coordinate axes.
Insert image description here

Elements such as the lane line (White Line) and Stop Line (Stop Line) are consistent with the above method. When drawing the Lane line, you need to pay attention to the direction consistent with the driving direction of the lane. Just fill in the height value directly.
Insert image description here
Insert image description here

Guess you like

Origin blog.csdn.net/yz2630570484/article/details/132685103