Merge branch 'dev' into lidar-branch
This commit is contained in:
commit
fe97b0b7a3
10
CHANGELOG.md
10
CHANGELOG.md
|
@ -1,6 +1,14 @@
|
||||||
## Latest Changes
|
## Latest Changes
|
||||||
* Prevent from segfault on failing SignalReference identification when loading OpenDrive files
|
* Prevent from segfault on failing SignalReference identification when loading OpenDrive files
|
||||||
* Added vehicle doors to the recorder
|
* Added vehicle doors to the recorder
|
||||||
|
* Added functions to get actor' components transform
|
||||||
|
* Added posibility to Digital Twins to work with local files (osm and xodr)
|
||||||
|
* Enable proper material merging for Building in Digital Twins
|
||||||
|
* Added functions to get actor' bones transforms
|
||||||
|
* Added functions to get actor' bones and components names
|
||||||
|
* Added functions to get actor' sockets transforms
|
||||||
|
* make PythonAPI Windows: Fixed incompatibility issue with Anaconda due `py` command.
|
||||||
|
* Fixed bug in python agents when vehicle list was empty causing a check on all vehicles (BasicAgent.py) and detected pedestrians as vehicles if no pedestrains are present (BehaviourAgent.py)
|
||||||
|
|
||||||
## CARLA 0.9.15
|
## CARLA 0.9.15
|
||||||
|
|
||||||
|
|
|
@ -59,7 +59,7 @@ As a reminder, the feature is only available for the Linux build so far.
|
||||||
|
|
||||||
### Dependencies
|
### Dependencies
|
||||||
|
|
||||||
There are additional prerequisites required for building RSS and its dependencies. Take a look at the [official documentation](https://intel.github.io/ad-rss-lib/BUILDING)) to know more about this.
|
There are additional prerequisites required for building RSS and its dependencies. Take a look at the [official documentation](https://intel.github.io/ad-rss-lib/BUILDING) to know more about this.
|
||||||
|
|
||||||
Dependencies provided by Ubunutu (>= 16.04).
|
Dependencies provided by Ubunutu (>= 16.04).
|
||||||
```sh
|
```sh
|
||||||
|
|
|
@ -365,7 +365,7 @@ CARLA forum</a>
|
||||||
|
|
||||||
>In Windows it will be the default Python version for:
|
>In Windows it will be the default Python version for:
|
||||||
|
|
||||||
> py -3 --version
|
> python --version
|
||||||
|
|
||||||
>Make sure you are running your scripts with the version of Python that corresponds to your `.egg` file.
|
>Make sure you are running your scripts with the version of Python that corresponds to your `.egg` file.
|
||||||
>In Linux, you may also need to set your Python path to point to the CARLA `.egg`. To do this, run the following command:
|
>In Linux, you may also need to set your Python path to point to the CARLA `.egg`. To do this, run the following command:
|
||||||
|
|
|
@ -48,6 +48,16 @@ wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key|sudo apt-key add
|
||||||
|
|
||||||
To avoid compatibility issues between Unreal Engine and the CARLA dependencies, use the same compiler version and C++ runtime library to compile everything. The CARLA team uses clang-8 (or clang-10 in Ubuntu 20.04) and LLVM's libc++. Change the default clang version to compile Unreal Engine and the CARLA dependencies.
|
To avoid compatibility issues between Unreal Engine and the CARLA dependencies, use the same compiler version and C++ runtime library to compile everything. The CARLA team uses clang-8 (or clang-10 in Ubuntu 20.04) and LLVM's libc++. Change the default clang version to compile Unreal Engine and the CARLA dependencies.
|
||||||
|
|
||||||
|
__Ubuntu 22.04__.
|
||||||
|
```sh
|
||||||
|
sudo apt-add-repository "deb http://archive.ubuntu.com/ubuntu focal main universe"
|
||||||
|
sudo apt-get update
|
||||||
|
sudo apt-get install build-essential clang-10 lld-10 g++-7 cmake ninja-build libvulkan1 python python3 python3-dev python3-pip libpng-dev libtiff5-dev libjpeg-dev tzdata sed curl unzip autoconf libtool rsync libxml2-dev git git-lfs
|
||||||
|
sudo update-alternatives --install /usr/bin/clang++ clang++ /usr/lib/llvm-10/bin/clang++ 180 &&
|
||||||
|
sudo update-alternatives --install /usr/bin/clang clang /usr/lib/llvm-10/bin/clang 180 &&
|
||||||
|
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-7 180
|
||||||
|
```
|
||||||
|
|
||||||
__Ubuntu 20.04__.
|
__Ubuntu 20.04__.
|
||||||
```sh
|
```sh
|
||||||
sudo apt-add-repository "deb http://apt.llvm.org/focal/ llvm-toolchain-focal main"
|
sudo apt-add-repository "deb http://apt.llvm.org/focal/ llvm-toolchain-focal main"
|
||||||
|
|
|
@ -1,13 +1,13 @@
|
||||||
# Update CARLA
|
# Update CARLA
|
||||||
|
|
||||||
* [__Update commands summary__](#update-commands-summary)
|
* [__Update commands summary__](#update-commands-summary)
|
||||||
* [__Get the lastest binary release__](#get-latest-binary-release)
|
* [__Get the lastest binary release__](#get-latest-binary-release)
|
||||||
* [__Update Linux and Windows build__](#update-linux-and-windows-build)
|
* [__Update Linux and Windows build__](#update-linux-and-windows-build)
|
||||||
* [Clean the build](#clean-the-build)
|
* [Clean the build](#clean-the-build)
|
||||||
* [Pull from origin](#pull-from-origin)
|
* [Pull from origin](#pull-from-origin)
|
||||||
* [Download the assets](#download-the-assets)
|
* [Download the assets](#download-the-assets)
|
||||||
* [Launch the server](#launch-the-server)
|
* [Launch the server](#launch-the-server)
|
||||||
* [__Get development assets__](#get-development-assets)
|
* [__Get development assets__](#get-development-assets)
|
||||||
|
|
||||||
To post unexpected issues, doubts or suggestions, feel free to login in the CARLA forum.
|
To post unexpected issues, doubts or suggestions, feel free to login in the CARLA forum.
|
||||||
|
|
||||||
|
@ -25,30 +25,30 @@ CARLA forum</a>
|
||||||
<summary> Show command lines to update CARLA</summary>
|
<summary> Show command lines to update CARLA</summary>
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
# Update a CARLA packaged release.
|
# Update a CARLA packaged release.
|
||||||
# 1. Delete the current one.
|
# 1. Delete the current one.
|
||||||
# 2. Follow the Quick start installation to get the one desired.
|
# 2. Follow the Quick start installation to get the one desired.
|
||||||
|
|
||||||
|
|
||||||
# Update Linux build.
|
# Update Linux build.
|
||||||
git checkout master
|
git checkout master
|
||||||
make clean
|
make clean
|
||||||
git pull origin master
|
git pull origin master
|
||||||
./Update.sh
|
./Update.sh
|
||||||
|
|
||||||
|
|
||||||
# Update Windows build.
|
# Update Windows build.
|
||||||
git checkout master
|
git checkout master
|
||||||
make clean
|
make clean
|
||||||
git pull origin master
|
git pull origin master
|
||||||
# Erase the content in `Unreal\CarlaUE4\Content\Carla`.
|
# Erase the content in `Unreal\CarlaUE4\Content\Carla`.
|
||||||
# Go to `\Util\ContentVersions.txt`.
|
# Go to `\Util\ContentVersions.txt`.
|
||||||
# Download the latest content.
|
# Download the latest content.
|
||||||
# Extract the new content in `Unreal\CarlaUE4\Content\Carla`.
|
# Extract the new content in `Unreal\CarlaUE4\Content\Carla`.
|
||||||
|
|
||||||
|
|
||||||
# Get development assets.
|
# Get development assets.
|
||||||
# Delete the `/Carla` folder containing previous assets.
|
# Delete the `/Carla` folder containing previous assets.
|
||||||
# Go to the main carla folder.
|
# Go to the main carla folder.
|
||||||
git clone https://bitbucket.org/carla-simulator/carla-content Unreal/CarlaUE4/Content/Carla
|
git clone https://bitbucket.org/carla-simulator/carla-content Unreal/CarlaUE4/Content/Carla
|
||||||
|
|
||||||
|
@ -56,11 +56,11 @@ git clone https://bitbucket.org/carla-simulator/carla-content Unreal/CarlaUE4/Co
|
||||||
</details>
|
</details>
|
||||||
|
|
||||||
---
|
---
|
||||||
## Get latest binary release
|
## Get latest binary release
|
||||||
|
|
||||||
Binary releases are prepackaged and thus, tied to a specific version of CARLA. To get the latest, erase the previous and follow the [quick start installation](start_quickstart.md) to get the one desired.
|
Binary releases are prepackaged and thus, tied to a specific version of CARLA. To get the latest, erase the previous and follow the [quick start installation](start_quickstart.md) to get the one desired.
|
||||||
|
|
||||||
Releases are listed in __Development__ in the CARLA repository. There is also a highly experimental __Nightly build__ containing the current state of CARLA up to date.
|
Releases are listed in __Development__ in the CARLA repository. There is also a highly experimental __Nightly build__ containing the current state of CARLA up to date.
|
||||||
|
|
||||||
<div class="build-buttons">
|
<div class="build-buttons">
|
||||||
<p>
|
<p>
|
||||||
|
@ -69,22 +69,22 @@ Releases are listed in __Development__ in the CARLA repository. There is also a
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
<a href="http://carla-releases.s3.amazonaws.com/Linux/Dev/CARLA_Latest.tar.gz" target="_blank" class="btn btn-neutral" title="Go to the linux nightly CARLA build">
|
<a href="https://carla-releases.s3.us-east-005.backblazeb2.com/Linux/Dev/CARLA_Latest.tar.gz" target="_blank" class="btn btn-neutral" title="Go to the linux nightly CARLA build">
|
||||||
<span class="icon fa-cloud-download"></span> Get the linux nightly build</a>
|
<span class="icon fa-cloud-download"></span> Get the linux nightly build</a>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
<a href="http://carla-releases.s3.amazonaws.com/Linux/Dev/AdditionalMaps_Latest.tar.gz" target="_blank" class="btn btn-neutral" title="Go to the linux nightly AdditionalMaps build">
|
<a href="https://carla-releases.s3.us-east-005.backblazeb2.com/Linux/Dev/AdditionalMaps_Latest.tar.gz" target="_blank" class="btn btn-neutral" title="Go to the linux nightly AdditionalMaps build">
|
||||||
<span class="icon fa-cloud-download"></span> Get the linux nightly build additional maps</a>
|
<span class="icon fa-cloud-download"></span> Get the linux nightly build additional maps</a>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
<a href="http://carla-releases.s3.amazonaws.com/Windows/Dev/CARLA_Latest.zip" target="_blank" class="btn btn-neutral" title="Go to the windows nightly CARLA build">
|
<a href="https://carla-releases.s3.us-east-005.backblazeb2.com/Windows/Dev/CARLA_Latest.zip" target="_blank" class="btn btn-neutral" title="Go to the windows nightly CARLA build">
|
||||||
<span class="icon fa-cloud-download"></span> Get the windows nightly build</a>
|
<span class="icon fa-cloud-download"></span> Get the windows nightly build</a>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
<a href="http://carla-releases.s3.amazonaws.com/Windows/Dev/AdditionalMaps_Latest.zip" target="_blank" class="btn btn-neutral" title="Go to the windows nightly AdditionalMaps build">
|
<a href="https://carla-releases.s3.us-east-005.backblazeb2.com/Windows/Dev/AdditionalMaps_Latest.zip" target="_blank" class="btn btn-neutral" title="Go to the windows nightly AdditionalMaps build">
|
||||||
<span class="icon fa-cloud-download"></span> Get the windows nightly build additional maps</a>
|
<span class="icon fa-cloud-download"></span> Get the windows nightly build additional maps</a>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
|
@ -93,22 +93,22 @@ Releases are listed in __Development__ in the CARLA repository. There is also a
|
||||||
---
|
---
|
||||||
## Update Linux and Windows build
|
## Update Linux and Windows build
|
||||||
|
|
||||||
Make sure to be in the local `master` branch before the update. Then, merge or rebase the changes to other branches and solve possible conflicts.
|
Make sure to be in the local `master` branch before the update. Then, merge or rebase the changes to other branches and solve possible conflicts.
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
git checkout master
|
git checkout master
|
||||||
```
|
```
|
||||||
|
|
||||||
### Clean the build
|
### Clean the build
|
||||||
|
|
||||||
Go to the main CARLA folder and delete binaries and temporals generated by the previous build.
|
Go to the main CARLA folder and delete binaries and temporals generated by the previous build.
|
||||||
```sh
|
```sh
|
||||||
make clean
|
make clean
|
||||||
```
|
```
|
||||||
|
|
||||||
### Pull from origin
|
### Pull from origin
|
||||||
|
|
||||||
Get the current version from `master` in the CARLA repository.
|
Get the current version from `master` in the CARLA repository.
|
||||||
```sh
|
```sh
|
||||||
git pull origin master
|
git pull origin master
|
||||||
```
|
```
|
||||||
|
@ -120,19 +120,19 @@ __Linux.__
|
||||||
./Update.sh
|
./Update.sh
|
||||||
```
|
```
|
||||||
|
|
||||||
__Windows.__
|
__Windows.__
|
||||||
|
|
||||||
__1.__ Erase the previous content in `Unreal\CarlaUE4\Content\Carla`.
|
__1.__ Erase the previous content in `Unreal\CarlaUE4\Content\Carla`.
|
||||||
__2.__ Go to `\Util\ContentVersions.txt`.
|
__2.__ Go to `\Util\ContentVersions.txt`.
|
||||||
__3.__ Download the content for `latest`.
|
__3.__ Download the content for `latest`.
|
||||||
__4.__ Extract the new content in `Unreal\CarlaUE4\Content\Carla`.
|
__4.__ Extract the new content in `Unreal\CarlaUE4\Content\Carla`.
|
||||||
|
|
||||||
!!! Note
|
!!! Note
|
||||||
In order to work with that the CARLA team is devleoping, go to __get development assets__ below.
|
In order to work with that the CARLA team is devleoping, go to __get development assets__ below.
|
||||||
|
|
||||||
### Launch the server
|
### Launch the server
|
||||||
|
|
||||||
Run the server in spectator view to make sure that everything worked properly.
|
Run the server in spectator view to make sure that everything worked properly.
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
make launch
|
make launch
|
||||||
|
@ -141,18 +141,18 @@ make launch
|
||||||
---
|
---
|
||||||
## Get development assets
|
## Get development assets
|
||||||
|
|
||||||
The CARLA team works with assets still in development. These models and maps have a [public git repository][contentrepolink] where the CARLA team regularly pushes latest updates. Assets are still unfinished, using them is only recommended for developers.
|
The CARLA team works with assets still in development. These models and maps have a [public git repository][contentrepolink] where the CARLA team regularly pushes latest updates. Assets are still unfinished, using them is only recommended for developers.
|
||||||
|
|
||||||
In order to handle this repository it is advisted to install [git-lfs][gitlfslink]. The repository is modified regularly, and git-lfs works faster with large binary files.
|
In order to handle this repository it is advisted to install [git-lfs][gitlfslink]. The repository is modified regularly, and git-lfs works faster with large binary files.
|
||||||
|
|
||||||
To clone the repository, __go to the main CARLA directory__ and run the following command.
|
To clone the repository, __go to the main CARLA directory__ and run the following command.
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
git clone https://bitbucket.org/carla-simulator/carla-content Unreal/CarlaUE4/Content/Carla
|
git clone https://bitbucket.org/carla-simulator/carla-content Unreal/CarlaUE4/Content/Carla
|
||||||
```
|
```
|
||||||
|
|
||||||
!!! Warning
|
!!! Warning
|
||||||
Delete the `/Carla` folder containing the assets before cloning the repository. Otherwise, an error will show.
|
Delete the `/Carla` folder containing the assets before cloning the repository. Otherwise, an error will show.
|
||||||
|
|
||||||
[contentrepolink]: https://bitbucket.org/carla-simulator/carla-content
|
[contentrepolink]: https://bitbucket.org/carla-simulator/carla-content
|
||||||
[gitlfslink]: https://github.com/git-lfs/git-lfs/wiki/Installation
|
[gitlfslink]: https://github.com/git-lfs/git-lfs/wiki/Installation
|
||||||
|
|
|
@ -40,7 +40,7 @@ In this section you will find details of system requirements, minor and major so
|
||||||
|
|
||||||
#### Minor installations
|
#### Minor installations
|
||||||
|
|
||||||
* [__CMake__](https://cmake.org/download/) generates standard build files from simple configuration files.
|
* [__CMake__](https://cmake.org/download/) generates standard build files from simple configuration files. __We recommend you use version 3.15+__.
|
||||||
* [__Git__](https://git-scm.com/downloads) is a version control system to manage CARLA repositories.
|
* [__Git__](https://git-scm.com/downloads) is a version control system to manage CARLA repositories.
|
||||||
* [__Make__](http://gnuwin32.sourceforge.net/packages/make.htm) generates the executables. It is necessary to use __Make version 3.81__, otherwise the build may fail. If you have multiple versions of Make installed, check that you are using version 3.81 in your PATH when building CARLA. You can check your default version of Make by running `make --version`.
|
* [__Make__](http://gnuwin32.sourceforge.net/packages/make.htm) generates the executables. It is necessary to use __Make version 3.81__, otherwise the build may fail. If you have multiple versions of Make installed, check that you are using version 3.81 in your PATH when building CARLA. You can check your default version of Make by running `make --version`.
|
||||||
* [__7Zip__](https://www.7-zip.org/) is a file compression software. This is required for automatic decompression of asset files and prevents errors during build time due to large files being extracted incorrectly or partially.
|
* [__7Zip__](https://www.7-zip.org/) is a file compression software. This is required for automatic decompression of asset files and prevents errors during build time due to large files being extracted incorrectly or partially.
|
||||||
|
|
|
@ -10,10 +10,10 @@
|
||||||
> branch. It contains the very latest fixes and features that will be part of the
|
> branch. It contains the very latest fixes and features that will be part of the
|
||||||
> next release, but also some experimental changes. Use at your own risk!
|
> next release, but also some experimental changes. Use at your own risk!
|
||||||
|
|
||||||
- [CARLA Nightly Build (Linux)](https://carla-releases.s3.eu-west-3.amazonaws.com/Linux/Dev/CARLA_Latest.tar.gz)
|
- [CARLA Nightly Build (Linux)](https://carla-releases.s3.us-east-005.backblazeb2.com/Linux/Dev/CARLA_Latest.tar.gz)
|
||||||
- [AdditionalMaps Nightly Build (Linux)](https://carla-releases.s3.eu-west-3.amazonaws.com/Linux/Dev/AdditionalMaps_Latest.tar.gz)
|
- [AdditionalMaps Nightly Build (Linux)](https://carla-releases.s3.us-east-005.backblazeb2.com/Linux/Dev/AdditionalMaps_Latest.tar.gz)
|
||||||
- [CARLA Nightly Build (Windows)](https://carla-releases.s3.eu-west-3.amazonaws.com/Windows/Dev/CARLA_Latest.zip)
|
- [CARLA Nightly Build (Windows)](https://carla-releases.s3.us-east-005.backblazeb2.com/Windows/Dev/CARLA_Latest.zip)
|
||||||
- [AdditionalMaps Nightly Build (Windows)](https://carla-releases.s3.eu-west-3.amazonaws.com/Windows/Dev/AdditionalMaps_Latest.zip)
|
- [AdditionalMaps Nightly Build (Windows)](https://carla-releases.s3.us-east-005.backblazeb2.com/Windows/Dev/AdditionalMaps_Latest.zip)
|
||||||
|
|
||||||
### Versions 0.9.x
|
### Versions 0.9.x
|
||||||
|
|
||||||
|
|
|
@ -711,34 +711,39 @@ This raw [carla.Image](python_api.md#carla.Image) can be stored and converted it
|
||||||
raw_image.save_to_disk("path/to/save/converted/image",carla.ColorConverter.cityScapesPalette)
|
raw_image.save_to_disk("path/to/save/converted/image",carla.ColorConverter.cityScapesPalette)
|
||||||
```
|
```
|
||||||
|
|
||||||
The following tags are currently available:
|
The following tags are currently available (Note, tags changed from version 0.9.13 to 0.9.14):
|
||||||
|
|
||||||
| Value | Tag | Converted color | Description |
|
| Value | Tag | Converted color | Description |
|
||||||
| ----------------------------------- | ----------------------------------- | ----------------------------------- | ----------------------------------- |
|
| ----------------------------------- | ----------------------------------- | ----------------------------------- | ----------------------------------- |
|
||||||
| `0` | Unlabeled | `(0, 0, 0)` | Elements that have not been categorized are considered `Unlabeled`. This category is meant to be empty or at least contain elements with no collisions. |
|
| `0` | Unlabeled | `(0, 0, 0)` | Elements that have not been categorized are considered `Unlabeled`. This category is meant to be empty or at least contain elements with no collisions. |
|
||||||
| `1` | Building | `(70, 70, 70)` | Buildings like houses, skyscrapers,... and the elements attached to them. <br> E.g. air conditioners, scaffolding, awning or ladders and much more. |
|
| `1` | Roads | `(128, 64, 128)` | Part of ground on which cars usually drive. <br> E.g. lanes in any directions, and streets. |
|
||||||
| `2` | Fence | `(100, 40, 40)` | Barriers, railing, or other upright structures. Basically wood or wire assemblies that enclose an area of ground. |
|
| `2` | SideWalks | `(244, 35, 232)` | Part of ground designated for pedestrians or cyclists. Delimited from the road by some obstacle (such as curbs or poles), not only by markings. This label includes a possibly delimiting curb, traffic islands (the walkable part), and pedestrian zones. |
|
||||||
| `3` | Other | `(55, 90, 80)` | Everything that does not belong to any other category. |
|
| `3` | Building | `(70, 70, 70)` | Buildings like houses, skyscrapers,... and the elements attached to them. <br> E.g. air conditioners, scaffolding, awning or ladders and much more. |
|
||||||
| `4` | Pedestrian | `(220, 20, 60)` | Humans that walk or ride/drive any kind of vehicle or mobility system. <br> E.g. bicycles or scooters, skateboards, horses, roller-blades, wheel-chairs, etc. |
|
| `4` | Wall | `(102, 102, 156)` | Individual standing walls. Not part of a building. |
|
||||||
| `5` | Pole | `(153, 153, 153)` | Small mainly vertically oriented pole. If the pole has a horizontal part (often for traffic light poles) this is also considered pole. <br> E.g. sign pole, traffic light poles. |
|
| `5` | Fence | `(190, 153, 153)` | Barriers, railing, or other upright structures. Basically wood or wire assemblies that enclose an area of ground. |
|
||||||
| `6` | RoadLine | `(157, 234, 50)` | The markings on the road. |
|
| `6` | Pole | `(153, 153, 153)` | Small mainly vertically oriented pole. If the pole has a horizontal part (often for traffic light poles) this is also considered pole. <br> E.g. sign pole, traffic light poles. |
|
||||||
| `7` | Road | `(128, 64, 128)` | Part of ground on which cars usually drive. <br> E.g. lanes in any directions, and streets. |
|
| `7` | TrafficLight | `(250, 170, 30)` | Traffic light boxes without their poles. |
|
||||||
| `8` | SideWalk | `(244, 35, 232)` | Part of ground designated for pedestrians or cyclists. Delimited from the road by some obstacle (such as curbs or poles), not only by markings. This label includes a possibly delimiting curb, traffic islands (the walkable part), and pedestrian zones. |
|
| `8` | TrafficSign | `(220, 220, 0)` | Signs installed by the state/city authority, usually for traffic regulation. This category does not include the poles where signs are attached to. <br> E.g. traffic- signs, parking signs, direction signs... |
|
||||||
| `9` | Vegetation | `(107, 142, 35)` | Trees, hedges, all kinds of vertical vegetation. Ground-level vegetation is considered `Terrain`. |
|
| `9` | Vegetation | `(107, 142, 35)` | Trees, hedges, all kinds of vertical vegetation. Ground-level vegetation is considered `Terrain`. |
|
||||||
| `10` | Vehicles | `(0, 0, 142)` | Cars, vans, trucks, motorcycles, bikes, buses, trains. |
|
| `10` | Terrain | `(152, 251, 152)` | Grass, ground-level vegetation, soil or sand. These areas are not meant to be driven on. This label includes a possibly delimiting curb. |
|
||||||
| `11` | Wall | `(102, 102, 156)` | Individual standing walls. Not part of a building. |
|
| `11` | Sky | `(70, 130, 180)` | Open sky. Includes clouds and the sun. |
|
||||||
| `12` | TrafficSign | `(220, 220, 0)` | Signs installed by the state/city authority, usually for traffic regulation. This category does not include the poles where signs are attached to. <br> E.g. traffic- signs, parking signs, direction signs... |
|
| `12` | Pedestrian | `(220, 20, 60)` | Humans that walk |
|
||||||
| `13` | Sky | `(70, 130, 180)` | Open sky. Includes clouds and the sun. |
|
| `13` | Rider | `(255, 0, 0)` | Humans that ride/drive any kind of vehicle or mobility system <br> E.g. bicycles or scooters, skateboards, horses, roller-blades, wheel-chairs, etc. . |
|
||||||
| `14` | Ground | `(81, 0, 81)` | Any horizontal ground-level structures that does not match any other category. For example areas shared by vehicles and pedestrians, or flat roundabouts delimited from the road by a curb. |
|
| `14` | Car | `(0, 0, 142)` | Cars, vans |
|
||||||
| `15` | Bridge | `(150, 100, 100)` | Only the structure of the bridge. Fences, people, vehicles, an other elements on top of it are labeled separately. |
|
| `15` | Truck | `(0, 0, 70)` | Trucks |
|
||||||
| `16` | RailTrack | `(230, 150, 140)` | All kind of rail tracks that are non-drivable by cars. <br> E.g. subway and train rail tracks. |
|
| `16` | Bus | `(0, 60, 100)` | Busses |
|
||||||
| `17` | GuardRail | `(180, 165, 180)` | All types of guard rails/crash barriers. |
|
| `17` | Train | `(0, 60, 100)` | Trains |
|
||||||
| `18` | TrafficLight | `(250, 170, 30)` | Traffic light boxes without their poles. |
|
| `18` | Motorcycle | `(0, 0, 230)` | Motorcycle, Motorbike |
|
||||||
| `19` | Static | `(110, 190, 160)` | Elements in the scene and props that are immovable. <br> E.g. fire hydrants, fixed benches, fountains, bus stops, etc. |
|
| `19` | Bicycle | `(119, 11, 32)` | Bicylces |
|
||||||
| `20` | Dynamic | `(170, 120, 50)` | Elements whose position is susceptible to change over time. <br> E.g. Movable trash bins, buggies, bags, wheelchairs, animals, etc. |
|
| `20` | Static | `(110, 190, 160)` | Elements in the scene and props that are immovable. <br> E.g. fire hydrants, fixed benches, fountains, bus stops, etc. |
|
||||||
| `21` | Water | `(45, 60, 150)` | Horizontal water surfaces. <br> E.g. Lakes, sea, rivers. |
|
| `21` | Dynamic | `(170, 120, 50)` | Elements whose position is susceptible to change over time. <br> E.g. Movable trash bins, buggies, bags, wheelchairs, animals, etc. |
|
||||||
| `22` | Terrain | `(145, 170, 100)` | Grass, ground-level vegetation, soil or sand. These areas are not meant to be driven on. This label includes a possibly delimiting curb. |
|
| `22` | Other | `(55, 90, 80)` | Everything that does not belong to any other category. |
|
||||||
|
| `23` | Water | `(45, 60, 150)` | Horizontal water surfaces. <br> E.g. Lakes, sea, rivers. |
|
||||||
|
| `24` | RoadLine | `(157, 234, 50)` | The markings on the road. |
|
||||||
|
| `25` | Ground | `(81, 0, 81)` | Any horizontal ground-level structures that does not match any other category. For example areas shared by vehicles and pedestrians, or flat roundabouts delimited from the road by a curb. |
|
||||||
|
| `26` | Bridge | `(150, 100, 100)` | Only the structure of the bridge. Fences, people, vehicles, an other elements on top of it are labeled separately. |
|
||||||
|
| `27` | RailTrack | `(230, 150, 140)` | All kind of rail tracks that are non-drivable by cars. <br> E.g. subway and train rail tracks. |
|
||||||
|
| `28` | GuardRail | `(180, 165, 180)` | All types of guard rails/crash barriers. |
|
||||||
<br>
|
<br>
|
||||||
|
|
||||||
!!! Note
|
!!! Note
|
||||||
|
|
|
@ -13,7 +13,7 @@ This tutorial details how to add a new vehicle to CARLA. There are two sections,
|
||||||
---
|
---
|
||||||
## Add a 4 wheeled vehicle
|
## Add a 4 wheeled vehicle
|
||||||
|
|
||||||
Vehicles added to CARLA need to use a __common base skeleton__ which is found [__here__](https://carla-assets.s3.eu-west-3.amazonaws.com/fbx/VehicleSkeleton.rar). This link will download a folder called `VehicleSkeleton.rar` which contains the base skeleton in two different `.fbx` formats, one in ASCII and the other in binary. The format you use will depend on your 3D modeling software requirements.
|
Vehicles added to CARLA need to use a __common base skeleton__ which is found [__here__](https://carla-assets.s3.us-east-005.backblazeb2.com/fbx/VehicleSkeleton.rar). This link will download a folder called `VehicleSkeleton.rar` which contains the base skeleton in two different `.fbx` formats, one in ASCII and the other in binary. The format you use will depend on your 3D modeling software requirements.
|
||||||
|
|
||||||
__The positions of the skeleton bones can be changed but any other manipulation such as rotation, addition of new bones, or changing the current hierarchy will lead to errors. __
|
__The positions of the skeleton bones can be changed but any other manipulation such as rotation, addition of new bones, or changing the current hierarchy will lead to errors. __
|
||||||
|
|
||||||
|
@ -52,7 +52,7 @@ We recommend that you divide the vehicle into the following materials:
|
||||||
- __Lights__: Headlights, indicator lights, etc.
|
- __Lights__: Headlights, indicator lights, etc.
|
||||||
- __LightGlass_Ext__: A layer of glass that allows visibility from the outside to the inside of the light.
|
- __LightGlass_Ext__: A layer of glass that allows visibility from the outside to the inside of the light.
|
||||||
- __LightGlass_Int__: A layer of glass that allows visibility from the inside to the outside of the light.
|
- __LightGlass_Int__: A layer of glass that allows visibility from the inside to the outside of the light.
|
||||||
- __LicensePlate__: A rectangular plane of 29x12 cm. You can use the CARLA provided `.fbx` for best results, download it [here](https://carla-assets.s3.eu-west-3.amazonaws.com/fbx/LicensePlate.rar). The texture will be assigned automatically in Unreal Engine.
|
- __LicensePlate__: A rectangular plane of 29x12 cm. You can use the CARLA provided `.fbx` for best results, download it [here](https://carla-assets.s3.us-east-005.backblazeb2.com/fbx/LicensePlate.rar). The texture will be assigned automatically in Unreal Engine.
|
||||||
- __Interior__: Any other details that don't fit in the above sections can go into _Interior_.
|
- __Interior__: Any other details that don't fit in the above sections can go into _Interior_.
|
||||||
|
|
||||||
Materials should be named using the format `M_CarPart_CarName`, e.g., `M_Bodywork_Mustang`.
|
Materials should be named using the format `M_CarPart_CarName`, e.g., `M_Bodywork_Mustang`.
|
||||||
|
@ -278,7 +278,7 @@ All other parameters such as engine, transmission, steering curve, are the same
|
||||||
---
|
---
|
||||||
## Add a 2 wheeled vehicle
|
## Add a 2 wheeled vehicle
|
||||||
|
|
||||||
Adding 2 wheeled vehicles is similar to adding a 4 wheeled one but due to the complexity of the animation you'll need to set up aditional bones to guide the driver's animation. [Here](https://carla-assets.s3.eu-west-3.amazonaws.com/fbx/BikeSkeleton.rar) is the link to the reference skeleton for 2 wheeled vehicles.
|
Adding 2 wheeled vehicles is similar to adding a 4 wheeled one but due to the complexity of the animation you'll need to set up aditional bones to guide the driver's animation. [Here](https://carla-assets.s3.us-east-005.backblazeb2.com/fbx/BikeSkeleton.rar) is the link to the reference skeleton for 2 wheeled vehicles.
|
||||||
|
|
||||||
As with the 4 wheeled vehicles, orient the model towards positive "x" and every bone axis towards
|
As with the 4 wheeled vehicles, orient the model towards positive "x" and every bone axis towards
|
||||||
positive x and with the z axis facing upwards.
|
positive x and with the z axis facing upwards.
|
||||||
|
|
|
@ -23,9 +23,9 @@ In CARLA, there is a set of master materials that are used as templates for the
|
||||||
* __M_CarInterior_Master__ — Material applied to the inside of the car.
|
* __M_CarInterior_Master__ — Material applied to the inside of the car.
|
||||||
* __M_CarLightsGlass_Master__ — Material applied to the glass covering car lights.
|
* __M_CarLightsGlass_Master__ — Material applied to the glass covering car lights.
|
||||||
* __M_CarWindows_Master__ — Material applied to the windows.
|
* __M_CarWindows_Master__ — Material applied to the windows.
|
||||||
* __M_CarLicensePlate_Master__ — Material applied to the license plate.
|
* __M_LicensePlate_Master__ — Material applied to the license plate.
|
||||||
* __M_CarVehicleLights_Master__ — Material applied to the car lights as an emissive texure.
|
* __M_VehicleLights_Master__ — Material applied to the car lights as an emissive texure.
|
||||||
* __M_CarVehicleLigthsSirens_Master__ — Material applied to the sirens, if applicable.
|
* __M_VehicleLights_Sirens_Master__ — Material applied to the sirens, if applicable.
|
||||||
|
|
||||||
---
|
---
|
||||||
## Customize car materials
|
## Customize car materials
|
||||||
|
@ -142,7 +142,7 @@ Similarly to car materials, a building material can be greatly changed if desire
|
||||||
* `Color` — Tint to be applied based on the white area on the __Diffuse__ `Alpha` texture.
|
* `Color` — Tint to be applied based on the white area on the __Diffuse__ `Alpha` texture.
|
||||||
* `Emissive Texture` — Enable the usage of an __Emissive__ texture.
|
* `Emissive Texture` — Enable the usage of an __Emissive__ texture.
|
||||||
* `EmissiveColor` — Tint to be applied based on the white area on the __ORME__ `Emissive mask` texture.
|
* `EmissiveColor` — Tint to be applied based on the white area on the __ORME__ `Emissive mask` texture.
|
||||||
* `Emissive atenuance` — Factor that divides the intensity stated in __BP_Lights__ to obtain proper emissive values.
|
* `Emissive attenuance` — Factor that divides the intensity stated in __BP_Lights__ to obtain proper emissive values.
|
||||||
* `RoughnessCorrection` — Changes the intensity of the roughness map.
|
* `RoughnessCorrection` — Changes the intensity of the roughness map.
|
||||||
* `MetallicCorrection` — Changes the intensity of the metallic map.
|
* `MetallicCorrection` — Changes the intensity of the metallic map.
|
||||||
* `NormalFlatness` — Changes the intensity of the normal map.
|
* `NormalFlatness` — Changes the intensity of the normal map.
|
||||||
|
|
|
@ -67,7 +67,7 @@ __4.3__ Press `Compile` in the toolbar above and save the changes.
|
||||||
## Physics colliders
|
## Physics colliders
|
||||||
|
|
||||||
!!! Important
|
!!! Important
|
||||||
This tutorial is based on a [contribution](https://bitbucket.org/yankagan/carla-content/wiki/Home) made by __[yankagan](https://github.com/yankagan)__! The contributor also wants to aknowledge __Francisco E__ for the tutorial on [how to import custom collisions in UE](https://www.youtube.com/watch?v=SEH4f0HrCDM).
|
This tutorial is based on a [contribution](https://bitbucket.org/yankagan/carla-content/wiki/Home) made by __[yankagan](https://github.com/yankagan)__! The contributor also wants to acknowledge __Francisco E__ for the tutorial on [how to import custom collisions in UE](https://www.youtube.com/watch?v=SEH4f0HrCDM).
|
||||||
|
|
||||||
[This video](https://www.youtube.com/watch?v=CXK2M2cNQ4Y) shows the results achieved after following this tutorial.
|
[This video](https://www.youtube.com/watch?v=CXK2M2cNQ4Y) shows the results achieved after following this tutorial.
|
||||||
|
|
||||||
|
|
|
@ -25,7 +25,7 @@ This page shows you how to generate a `.sim` file, explains how vehicle dimensio
|
||||||
__For Ubuntu__:
|
__For Ubuntu__:
|
||||||
|
|
||||||
1. Download the plugin [here](https://www.carsim.com/users/unreal_plugin/unreal_plugin_2020_0.php).
|
1. Download the plugin [here](https://www.carsim.com/users/unreal_plugin/unreal_plugin_2020_0.php).
|
||||||
2. Replace the file `CarSim.Build.cs` with the file found [here](https://carla-releases.s3.eu-west-3.amazonaws.com/Backup/CarSim.Build.cs) in order to use the correct solver for Ubuntu.
|
2. Replace the file `CarSim.Build.cs` with the file found [here](https://carla-assets.s3.us-east-005.backblazeb2.com/Backup/CarSim.Build.cs) in order to use the correct solver for Ubuntu.
|
||||||
|
|
||||||
3. This step can be skipped if you are using the packaged version of CARLA. The packaged version has already been compiled using this flag but if you are building CARLA from source then you will need to compile the server with the `--carsim` flag.
|
3. This step can be skipped if you are using the packaged version of CARLA. The packaged version has already been compiled using this flag but if you are building CARLA from source then you will need to compile the server with the `--carsim` flag.
|
||||||
|
|
||||||
|
|
|
@ -147,7 +147,7 @@ def build_projection_matrix(w, h, fov):
|
||||||
|
|
||||||
## Build the skeleton
|
## Build the skeleton
|
||||||
|
|
||||||
Now we can put the moving parts together. First, gather the bone coordinates from the simulation using `pedestrian.get_bones()` and then put together the skeleton and project it onto the 2D imaging plane of the camera sensor. The bones are joined into the complete skeleton using the pairs defined in __skeleton.txt__ that can be downloaded [__here__](https://carla-assets.s3.eu-west-3.amazonaws.com/fbx/skeleton.txt).
|
Now we can put the moving parts together. First, gather the bone coordinates from the simulation using `pedestrian.get_bones()` and then put together the skeleton and project it onto the 2D imaging plane of the camera sensor. The bones are joined into the complete skeleton using the pairs defined in __skeleton.txt__ that can be downloaded [__here__](https://carla-assets.s3.us-east-005.backblazeb2.com/fbx/skeleton.txt).
|
||||||
|
|
||||||
We need a function to iterate through the bone pairs defined in __skeleton.txt__ and join the bone coordinates into lines that can be overlayed onto a camera sensor image.
|
We need a function to iterate through the bone pairs defined in __skeleton.txt__ and join the bone coordinates into lines that can be overlayed onto a camera sensor image.
|
||||||
|
|
||||||
|
|
|
@ -568,7 +568,7 @@ The script places the sensor on the hood of the car, and rotated a bit upwards.
|
||||||
The callback is a bit more complex this time, showing more of its capabilities. It will draw the points captured by the radar on the fly. The points will be colored depending on their velocity regarding the ego vehicle.
|
The callback is a bit more complex this time, showing more of its capabilities. It will draw the points captured by the radar on the fly. The points will be colored depending on their velocity regarding the ego vehicle.
|
||||||
|
|
||||||
* __Blue__ for points approaching the vehicle.
|
* __Blue__ for points approaching the vehicle.
|
||||||
* __Read__ for points moving away from it.
|
* __Red__ for points moving away from it.
|
||||||
* __White__ for points static regarding the ego vehicle.
|
* __White__ for points static regarding the ego vehicle.
|
||||||
|
|
||||||
```py
|
```py
|
||||||
|
|
|
@ -8,7 +8,7 @@ Firstly, we need to load the Unreal Editor and load a CARLA map, follow the inst
|
||||||
|
|
||||||
![select_building](../img/tuto_G_texture_streaming/building_selected.png)
|
![select_building](../img/tuto_G_texture_streaming/building_selected.png)
|
||||||
|
|
||||||
We have selected __BP_Apartment04_v5_Opt__ for texture manipulation, the name can be seen in the World Outliner panel. __Make sure to hover over the name in the World Outliner and use the name defined in the tooltip__. The the internal name may differ from the title displayed in the list. In this case, the internal name is actually __BP_Apartment04_v5_Opt_2__.
|
We have selected __BP_Apartment04_v05_Opt__ for texture manipulation, the name can be seen in the World Outliner panel. __Make sure to hover over the name in the World Outliner and use the name defined in the tooltip__. The the internal name may differ from the title displayed in the list. In this case, the internal name is actually __BP_Apartment04_v05_Opt_2__.
|
||||||
|
|
||||||
![tooltip](../img/tuto_G_texture_streaming/tooltip.png)
|
![tooltip](../img/tuto_G_texture_streaming/tooltip.png)
|
||||||
|
|
||||||
|
|
|
@ -78,6 +78,10 @@ __6.__ A `<mapName>.bin` file will be created. This file contains the informatio
|
||||||
|
|
||||||
__7.__ Test the pedestrian navigation by starting a simulation and running the example script `generate_traffic.py` in `PythonAPI/examples`.
|
__7.__ Test the pedestrian navigation by starting a simulation and running the example script `generate_traffic.py` in `PythonAPI/examples`.
|
||||||
|
|
||||||
|
!!! note
|
||||||
|
**If you need to rebuild the pedestrian navigation** after updating the map, ensure to delete the CARLA cache. This is normally found in the home directory in Ubuntu (i.e. `cd ~`), or in the user directory in Windows (the directory assigned to the environment variable `USERPROFILE`), remove the folder named `carlaCache` and all of its contents, it is likely to be large in size.
|
||||||
|
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
If you have any questions about the process, then you can ask in the [forum](https://github.com/carla-simulator/carla/discussions).
|
If you have any questions about the process, then you can ask in the [forum](https://github.com/carla-simulator/carla/discussions).
|
||||||
|
|
|
@ -22,6 +22,9 @@ In this tutorial we will cover the process of creating a simple map for use with
|
||||||
* [Next steps](#next-steps)
|
* [Next steps](#next-steps)
|
||||||
* __[Trees and vegetation](#trees-and-vegetation)__
|
* __[Trees and vegetation](#trees-and-vegetation)__
|
||||||
* [Foliage tool](#foliage-tool)
|
* [Foliage tool](#foliage-tool)
|
||||||
|
* __[Exporting a map](#exporting-a-map)__
|
||||||
|
* [Exporting a map as a separate package](#exporting-a-map-as-a-separate-package)
|
||||||
|
* [Exporting a map as part of a complete CARLA package](#exporting-a-map-as-part-of-a-complete-carla-package)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -403,12 +406,56 @@ Navigate to the vegetation folder in the CARLA content library: `Carla > Static
|
||||||
|
|
||||||
A useful tool for trees and vegetation is the [__Unreal Engine foliage tool__](https://docs.unrealengine.com/4.27/en-US/BuildingWorlds/Foliage/). Activate the tool by selecting the `mode` from the mode dropdown in the toolbar.
|
A useful tool for trees and vegetation is the [__Unreal Engine foliage tool__](https://docs.unrealengine.com/4.27/en-US/BuildingWorlds/Foliage/). Activate the tool by selecting the `mode` from the mode dropdown in the toolbar.
|
||||||
|
|
||||||
![foliage_tool](img/tuto_content_authoring_maps/select_foliage_tool.png)
|
![foliage_tool](img/tuto_content_authoring_maps/select_foliage_tool.gif)
|
||||||
|
|
||||||
Drag your desired foliage item into the box labeled `+ Drop Foliage Here`. Set an appropriate density in the density field, then paint into the map with your foliage item.
|
Drag your desired foliage item into the box labeled `+ Drop Foliage Here`. Set an appropriate density in the density field, then paint into the map with your foliage item.
|
||||||
|
|
||||||
![foliage_paint](img/tuto_content_authoring_maps/foliage_paint.gif)
|
![foliage_paint](img/tuto_content_authoring_maps/foliage_paint.gif)
|
||||||
|
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Exporting a map
|
||||||
|
|
||||||
|
### Exporting a map as a separate package
|
||||||
|
|
||||||
|
To export a map as a map package that can be ingested into a standalone CARLA package installation, use the `make package` command as follows:
|
||||||
|
|
||||||
|
```sh
|
||||||
|
make package ARGS="--packages=<mapName>"
|
||||||
|
```
|
||||||
|
|
||||||
|
The `<mapName>` must point to a json file located in `CARLA_ROOT/Unreal/CarlaUE4/Content/Carla/Config` named *mapName.Package.json* which has the following structure:
|
||||||
|
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
"maps": [
|
||||||
|
{
|
||||||
|
"path": "/Game/Carla/Maps/",
|
||||||
|
"name": "MyMap",
|
||||||
|
"use_carla_materials": true
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"props": []
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
Your map should have been saved as `MyMap.umap` file in the `CARLA_ROOT/Unreal/CarlaUE4/Content/Carla/Maps` directory.
|
||||||
|
|
||||||
|
The exported map archive will be saved in the `Dist` folder on Linux and the `/Build/UE4Carla/` folder on Windows.
|
||||||
|
|
||||||
|
### Exporting a map as part of a complete CARLA package
|
||||||
|
|
||||||
|
To export the map as part of a complete CARLA package, such that the map is available on launch of the package, include the following line in the `DefaultGame.ini` file in `CARLA_ROOT/Unreal/CarlaUE4/Config/`:
|
||||||
|
|
||||||
|
```
|
||||||
|
+MapsToCook=(FilePath="/Game/Carla/Maps/MyMap")
|
||||||
|
```
|
||||||
|
|
||||||
|
This line should be added in the `[/Script/UnrealEd.ProjectPackagingSettings]` section, preferably next to the other `MapsToCook(...)` entries. Then run `make package` command to build a package containing your map. The exported CARLA package with your map will be saved in the `Dist` folder on Linux and the `/Build/UE4Carla/` folder on Windows.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
## Next steps
|
## Next steps
|
||||||
|
|
||||||
Continue customizing your map using the tools and guides below:
|
Continue customizing your map using the tools and guides below:
|
||||||
|
|
|
@ -1,36 +1,36 @@
|
||||||
# Content authoring - vehicles
|
# Content authoring - vehicles
|
||||||
|
|
||||||
CARLA provides a comprehensive set of vehicles out of the box in the blueprint library. CARLA allows the user to expand upon this with custom vehicles for maximum extensibility.
|
CARLA provides a comprehensive set of vehicles out of the box in the blueprint library. CARLA allows the user to expand upon this with custom vehicles for maximum extensibility.
|
||||||
|
|
||||||
3D modelling of detailed vehicles is highly complex and requires a significant degree of skill. We therefore refer the reader to alternative sources of documentation on 3D modelling, since this is beyond the scope of this guide. There are, however, numerous sources of vehicle models in both free and proprietary online repositories. Hence the user has many options to turn to for creating custom vehicles for use in CARLA.
|
3D modelling of detailed vehicles is highly complex and requires a significant degree of skill. We therefore refer the reader to alternative sources of documentation on 3D modelling, since this is beyond the scope of this guide. There are, however, numerous sources of vehicle models in both free and proprietary online repositories. Hence the user has many options to turn to for creating custom vehicles for use in CARLA.
|
||||||
|
|
||||||
The key factors in preparing a custom vehicle for CARLA lie in rigging the vehicle armature and then importing into the Unreal Engine. After rigging and importing, blueprints need to be set for the car and the wheels. Then apply materials and add the glass parts of the vehicle. We will cover these steps in the following guide.
|
The key factors in preparing a custom vehicle for CARLA lie in rigging the vehicle armature and then importing into the Unreal Engine. After rigging and importing, blueprints need to be set for the car and the wheels. Then apply materials and add the glass parts of the vehicle. We will cover these steps in the following guide.
|
||||||
|
|
||||||
* __[Modeling](#modeling)__
|
* __[Modeling](#modeling)__
|
||||||
* [Naming conventions](#naming-conventions)
|
* [Naming conventions](#naming-conventions)
|
||||||
* __[Rigging](#rigging-the-vehicle-using-an-armature)__
|
* __[Rigging](#rigging-the-vehicle-using-an-armature)__
|
||||||
* [Import](#import)
|
* [Import](#import)
|
||||||
* [Armature](#add-an-armature)
|
* [Armature](#add-an-armature)
|
||||||
* [Parenting](#parenting)
|
* [Parenting](#parenting)
|
||||||
* [Assignment](#assigning-car-parts-to-bones)
|
* [Assignment](#assigning-car-parts-to-bones)
|
||||||
* [Blender add-on](#blender-ue4-vehicle-rigging-add-on)
|
* [Blender add-on](#blender-ue4-vehicle-rigging-add-on)
|
||||||
* [Export](#export)
|
* [Export](#export)
|
||||||
* __[Import into Unreal Engine](#importing-into-unreal-engine)__
|
* __[Import into Unreal Engine](#importing-into-unreal-engine)__
|
||||||
* [Physics asset](#setting-the-physics-asset)
|
* [Physics asset](#setting-the-physics-asset)
|
||||||
* [Animation](#creating-the-animation)
|
* [Animation](#creating-the-animation)
|
||||||
* [Blueprint](#creating-the-blueprint)
|
* [Blueprint](#creating-the-blueprint)
|
||||||
* __[Materials](#materials)__
|
* __[Materials](#materials)__
|
||||||
* [Applying materials](#applying-a-material-to-your-vehicle)
|
* [Applying materials](#applying-a-material-to-your-vehicle)
|
||||||
* [Color](#color)
|
* [Color](#color)
|
||||||
* [Clear coat](#clear-coat)
|
* [Clear coat](#clear-coat)
|
||||||
* [Orange peel](#orange-peel)
|
* [Orange peel](#orange-peel)
|
||||||
* [Flakes](#flakes)
|
* [Flakes](#flakes)
|
||||||
* [Dust](#dust)
|
* [Dust](#dust)
|
||||||
* __[Glass](#glass)__
|
* __[Glass](#glass)__
|
||||||
* [Glass meshes](#glass-meshes)
|
* [Glass meshes](#glass-meshes)
|
||||||
* [Glass material](#glass-material)
|
* [Glass material](#glass-material)
|
||||||
* [Single layer glass](#single-layer-glass)
|
* [Single layer glass](#single-layer-glass)
|
||||||
* __[Wheels](#wheels)__
|
* __[Wheels](#wheels)__
|
||||||
* [Wheel blueprint](#wheel-blueprint)
|
* [Wheel blueprint](#wheel-blueprint)
|
||||||
* [Collision mesh](#collision-mesh)
|
* [Collision mesh](#collision-mesh)
|
||||||
* [Tire configuration](#tire-configuration)
|
* [Tire configuration](#tire-configuration)
|
||||||
|
@ -41,7 +41,7 @@ The key factors in preparing a custom vehicle for CARLA lie in rigging the vehic
|
||||||
|
|
||||||
## Modeling
|
## Modeling
|
||||||
|
|
||||||
Vehicles should have between 50,000 and 100,000 faces. We recommend triangulating the model prior to export as best practice. CARLA vehicles are modeled using the size and scale of actual cars as reference. Please ensure you pay careful attention to the units of your 3D application. Some work in centimeters while others work in meters.
|
Vehicles should have between 50,000 and 100,000 faces. We recommend triangulating the model prior to export as best practice. CARLA vehicles are modeled using the size and scale of actual cars as reference. Please ensure you pay careful attention to the units of your 3D application. Some work in centimeters while others work in meters.
|
||||||
|
|
||||||
### Naming conventions
|
### Naming conventions
|
||||||
|
|
||||||
|
@ -53,7 +53,7 @@ For ease and consistency we recommend that you divide the vehicle into the follo
|
||||||
- __Lights__: Headlights, indicator lights, etc.
|
- __Lights__: Headlights, indicator lights, etc.
|
||||||
- __LightGlass_Ext__: A layer of glass that allows visibility from the outside to the inside of the light.
|
- __LightGlass_Ext__: A layer of glass that allows visibility from the outside to the inside of the light.
|
||||||
- __LightGlass_Int__: A layer of glass that allows visibility from the inside to the outside of the light.
|
- __LightGlass_Int__: A layer of glass that allows visibility from the inside to the outside of the light.
|
||||||
- __LicensePlate__: A rectangular plane of 29x12 cm. You can use the CARLA provided `.fbx` for best results, download it [here](https://carla-assets.s3.eu-west-3.amazonaws.com/fbx/LicensePlate.rar). The texture will be assigned automatically in Unreal Engine.
|
- __LicensePlate__: A rectangular plane of 29x12 cm. You can use the CARLA provided `.fbx` for best results, download it [here](https://carla-assets.s3.us-east-005.backblazeb2.com/fbx/LicensePlate.rar). The texture will be assigned automatically in Unreal Engine.
|
||||||
- __Interior__: Any other details that don't fit in the above sections can go into _Interior_.
|
- __Interior__: Any other details that don't fit in the above sections can go into _Interior_.
|
||||||
|
|
||||||
Materials should be named using the format `M_CarPart_CarName`, e.g, `M_Bodywork_Mustang`.
|
Materials should be named using the format `M_CarPart_CarName`, e.g, `M_Bodywork_Mustang`.
|
||||||
|
@ -62,11 +62,11 @@ Textures should be named using the format `T_CarPart_CarName`, e.g, `T_Bodywork_
|
||||||
|
|
||||||
## Rigging the vehicle using an armature
|
## Rigging the vehicle using an armature
|
||||||
|
|
||||||
To look realistic within the simulation, the car needs to have rotating and wheels, the front pair of which can turn with steering inputs. Therefore to prepare a vehicle for CARLA, an armature needs to be rigged to the car to identify the wheels and allow their movement.
|
To look realistic within the simulation, the car needs to have rotating and wheels, the front pair of which can turn with steering inputs. Therefore to prepare a vehicle for CARLA, an armature needs to be rigged to the car to identify the wheels and allow their movement.
|
||||||
|
|
||||||
### Import
|
### Import
|
||||||
|
|
||||||
Import or model the vehicle model mesh in your 3D modelling application. In this guide we will use Blender 3D. Ensure that the wheels are separable from the main body. Each wheel must be accessible as a distinct object.
|
Import or model the vehicle model mesh in your 3D modelling application. In this guide we will use Blender 3D. Ensure that the wheels are separable from the main body. Each wheel must be accessible as a distinct object.
|
||||||
|
|
||||||
![model_in_blender](img/tuto_content_authoring_vehicles/import_model_blender.png)
|
![model_in_blender](img/tuto_content_authoring_vehicles/import_model_blender.png)
|
||||||
|
|
||||||
|
@ -74,23 +74,23 @@ It is important to ensure that the vehicle faces in the positive X direction, so
|
||||||
|
|
||||||
### Add an armature
|
### Add an armature
|
||||||
|
|
||||||
Now add an armature to the center of the vehicle, ensure the object is properly centered, the root of the armature bone should be set at the origin. Switch to edit mode and rotate the armature 90 around the x axis.
|
Now add an armature to the center of the vehicle, ensure the object is properly centered, the root of the armature bone should be set at the origin. Switch to edit mode and rotate the armature 90 around the x axis.
|
||||||
|
|
||||||
![armature_init](img/tuto_content_authoring_vehicles/vehicle_base_bone.png)
|
![armature_init](img/tuto_content_authoring_vehicles/vehicle_base_bone.png)
|
||||||
|
|
||||||
Now select the armature and add 4 more bones. Each of these bones needs to be located such that the root of the bone coincides with the centre of the each wheel. This can be achieved by locating the 3D cursor at the center of each wheel in edit mode. Select one of the wheels in object mode, select a vertex, press A to select all vertices then `Shift+S` and select `Cursor to selected`. This will locate the cursor in the center of the wheel. Then, in object mode, select the armature, switch to edit mode, select a bone and choose `Selection to cursor`. Your bone will now coincide with the wheel. Rotate each bone such that it lines up with the base of the armature.
|
Now select the armature and add 4 more bones. Each of these bones needs to be located such that the root of the bone coincides with the centre of the each wheel. This can be achieved by locating the 3D cursor at the center of each wheel in edit mode. Select one of the wheels in object mode, select a vertex, press A to select all vertices then `Shift+S` and select `Cursor to selected`. This will locate the cursor in the center of the wheel. Then, in object mode, select the armature, switch to edit mode, select a bone and choose `Selection to cursor`. Your bone will now coincide with the wheel. Rotate each bone such that it lines up with the base of the armature.
|
||||||
|
|
||||||
For each wheel, it is recommended to name the bone according to the wheel it needs to be coupled to, this will help in identification later when you need to assign vertex groups to each bone.
|
For each wheel, it is recommended to name the bone according to the wheel it needs to be coupled to, this will help in identification later when you need to assign vertex groups to each bone.
|
||||||
|
|
||||||
![armature_full](img/tuto_content_authoring_vehicles/all_vehicle_bones.png)
|
![armature_full](img/tuto_content_authoring_vehicles/all_vehicle_bones.png)
|
||||||
|
|
||||||
### Parenting
|
### Parenting
|
||||||
|
|
||||||
Now select all the parts of the body and all 4 wheels using shift or control in the project outliner, then control select the armature you have created (this order is important, it won't work if you select these in reverse order). Press `Ctrl+p` and select `With empty groups` to bind the mesh to the armature.
|
Now select all the parts of the body and all 4 wheels using shift or control in the project outliner, then control select the armature you have created (this order is important, it won't work if you select these in reverse order). Press `Ctrl+p` and select `With empty groups` to bind the mesh to the armature.
|
||||||
|
|
||||||
![bind_armature](img/tuto_content_authoring_vehicles/bind_armature.gif)
|
![bind_armature](img/tuto_content_authoring_vehicles/bind_armature.gif)
|
||||||
|
|
||||||
Now you have parented the mesh to the armature, you now need to assign each wheel to its respective bone. Select a wheel either in the outliner or the editor. Switch to edit mode, and select all the vertices of the wheel (shortcut - `a`).
|
Now you have parented the mesh to the armature, you now need to assign each wheel to its respective bone. Select a wheel either in the outliner or the editor. Switch to edit mode, and select all the vertices of the wheel (shortcut - `a`).
|
||||||
|
|
||||||
### Assigning car parts to bones
|
### Assigning car parts to bones
|
||||||
|
|
||||||
|
@ -108,9 +108,9 @@ There is a very useful add on for blender for rigging a vehicle for import into
|
||||||
|
|
||||||
### Export
|
### Export
|
||||||
|
|
||||||
Now we will export our rigged model into FBX format for import into Unreal Engine. Select `Export > FBX (.fbx)` from the File menu. In the `Object Types` section of the `Include` panel, shift select the `Armature` and `Mesh` options.
|
Now we will export our rigged model into FBX format for import into Unreal Engine. Select `Export > FBX (.fbx)` from the File menu. In the `Object Types` section of the `Include` panel, shift select the `Armature` and `Mesh` options.
|
||||||
|
|
||||||
In the `Transform` panel. Change `Forward` to `X Forward` and change `Up` to `Z Up`. This is important to ensure the vehicle is oriented correctly in the Unreal Engine.
|
In the `Transform` panel. Change `Forward` to `X Forward` and change `Up` to `Z Up`. This is important to ensure the vehicle is oriented correctly in the Unreal Engine.
|
||||||
|
|
||||||
In the `Armature` section uncheck `Add Leaf Bones` and uncheck `Bake Animation`.
|
In the `Armature` section uncheck `Add Leaf Bones` and uncheck `Bake Animation`.
|
||||||
|
|
||||||
|
@ -118,7 +118,7 @@ In the `Armature` section uncheck `Add Leaf Bones` and uncheck `Bake Animation`.
|
||||||
|
|
||||||
## Importing into unreal engine
|
## Importing into unreal engine
|
||||||
|
|
||||||
Launch the Unreal Editor with the `make launch` command from the CARLA root directory (the one where you have built CARLA from source). Open a content browser, set up an appropriate directory and right click and select `Import to ....`. Choose the FBX file that you previously exported from Blender (or another 3D modelling application). Import with default settings.
|
Launch the Unreal Editor with the `make launch` command from the CARLA root directory (the one where you have built CARLA from source). Open a content browser, set up an appropriate directory and right click and select `Import to ....`. Choose the FBX file that you previously exported from Blender (or another 3D modelling application). Import with default settings.
|
||||||
|
|
||||||
### Setting the physics asset
|
### Setting the physics asset
|
||||||
|
|
||||||
|
@ -130,7 +130,7 @@ First, select the main body, in the `Details` menu on the right, change the `Lin
|
||||||
|
|
||||||
![physics_details](img/tuto_content_authoring_vehicles/physics_details.png)
|
![physics_details](img/tuto_content_authoring_vehicles/physics_details.png)
|
||||||
|
|
||||||
Now select all the wheels (in the `Skeleton Tree` section on the left).
|
Now select all the wheels (in the `Skeleton Tree` section on the left).
|
||||||
|
|
||||||
![regenerate_wheels](img/tuto_content_authoring_vehicles/wheels_asset.png)
|
![regenerate_wheels](img/tuto_content_authoring_vehicles/wheels_asset.png)
|
||||||
|
|
||||||
|
@ -170,7 +170,7 @@ Select the `Vehicles` node and expand the `Vehicles` item in the `Default value`
|
||||||
|
|
||||||
![vehicle_factory](img/tuto_content_authoring_vehicles/vehicle_factory_page.png)
|
![vehicle_factory](img/tuto_content_authoring_vehicles/vehicle_factory_page.png)
|
||||||
|
|
||||||
Press the plus icon to add your new vehicle. Scroll down to the last entry and expand it, it should be empty. Name the make and model of your vehicle and under the class section find your blueprint class that you created in the previous section. Leave the number of wheels as 4 and put the generation as 2. Compile and save. Do a global save for safety and you are now..ready to run your vehicle in a simulation.
|
Press the plus icon to add your new vehicle. Scroll down to the last entry and expand it, it should be empty. Name the make and model of your vehicle and under the class section find your blueprint class that you created in the previous section. Leave the number of wheels as 4 and put the generation as 2. Compile and save. Do a global save for safety and you are now..ready to run your vehicle in a simulation.
|
||||||
|
|
||||||
Press play in the unreal toolbar to run the simulation. Once it is running, open a terminal and run the `manual_control.py` script with the filter option to specify your new vehicle model:
|
Press play in the unreal toolbar to run the simulation. Once it is running, open a terminal and run the `manual_control.py` script with the filter option to specify your new vehicle model:
|
||||||
|
|
||||||
|
@ -185,13 +185,13 @@ As it is, the vehicle currently has no textures or colors applied. The next step
|
||||||
|
|
||||||
Once you have your vehicle imported as a basic asset with the mesh and blueprints laid out, you now want to add materials to your vehicle to facilitate photorealistic rendering in the Unreal Engine, for maximum fidelity in your machine learning training data.
|
Once you have your vehicle imported as a basic asset with the mesh and blueprints laid out, you now want to add materials to your vehicle to facilitate photorealistic rendering in the Unreal Engine, for maximum fidelity in your machine learning training data.
|
||||||
|
|
||||||
The Unreal Editor boasts a comprehensive materials workflow that facilitates the creation of highly realistic materials. This does, however, add a significant degree of complexity to the process. For this reason, CARLA is provided with a large library of material prototypes for you to use without having to start from scratch.
|
The Unreal Editor boasts a comprehensive materials workflow that facilitates the creation of highly realistic materials. This does, however, add a significant degree of complexity to the process. For this reason, CARLA is provided with a large library of material prototypes for you to use without having to start from scratch.
|
||||||
|
|
||||||
### Applying a material to your vehicle
|
### Applying a material to your vehicle
|
||||||
|
|
||||||
CARLA provides a prototype material for replicating the glossy finish of vehicles that can mimic numerous different types of vehicle paint jobs and features. Open Unreal editor and in the content browser, locate the material in `Content > Carla > Static > GenericMaterials > 00_MastersOpt`. The basic material is called `M_CarPaint_Master`. Right click on this material and choose `Create Material Instance` from the context material. Name it and move it into the folder where your new vehicle content is stored.
|
CARLA provides a prototype material for replicating the glossy finish of vehicles that can mimic numerous different types of vehicle paint jobs and features. Open Unreal editor and in the content browser, locate the material in `Content > Carla > Static > GenericMaterials > 00_MastersOpt`. The basic material is called `M_CarPaint_Master`. Right click on this material and choose `Create Material Instance` from the context material. Name it and move it into the folder where your new vehicle content is stored.
|
||||||
|
|
||||||
In the Unreal Editor, move the spectator to a point near the floor and drag the skeletal mesh of the vehicle from the content browser into the scene, the body of your vehicle will now appear there.
|
In the Unreal Editor, move the spectator to a point near the floor and drag the skeletal mesh of the vehicle from the content browser into the scene, the body of your vehicle will now appear there.
|
||||||
|
|
||||||
![add_model](img/tuto_content_authoring_vehicles/add_model.gif)
|
![add_model](img/tuto_content_authoring_vehicles/add_model.gif)
|
||||||
|
|
||||||
|
@ -207,7 +207,7 @@ The color settings govern the overall color of the car. The base color is simply
|
||||||
|
|
||||||
![change_base_color](img/tuto_content_authoring_vehicles/change_base_color.gif)
|
![change_base_color](img/tuto_content_authoring_vehicles/change_base_color.gif)
|
||||||
|
|
||||||
#### __Clear coat__
|
#### __Clear coat__
|
||||||
|
|
||||||
The clear coat settings govern the appearance of the finish and how it reacts to light. The roughness uses a texture to apply imperfections to the vehicle surface, scattering light more with higher values to create a matte look. Subtle adjustments and low values are recommended for a realistic look. Generally, car paint jobs are smooth and reflective, however, this effect might be used more generously to model specialist matte finishes of custom paint jobs.
|
The clear coat settings govern the appearance of the finish and how it reacts to light. The roughness uses a texture to apply imperfections to the vehicle surface, scattering light more with higher values to create a matte look. Subtle adjustments and low values are recommended for a realistic look. Generally, car paint jobs are smooth and reflective, however, this effect might be used more generously to model specialist matte finishes of custom paint jobs.
|
||||||
|
|
||||||
|
@ -215,7 +215,7 @@ The clear coat settings govern the appearance of the finish and how it reacts to
|
||||||
|
|
||||||
An important parameter to govern the "shininess" or "glossiness" of your car is the `Clear Coat Intensity`. High values close to 1 will make the coat shiny and glossy.
|
An important parameter to govern the "shininess" or "glossiness" of your car is the `Clear Coat Intensity`. High values close to 1 will make the coat shiny and glossy.
|
||||||
|
|
||||||
#### __Orange peel__
|
#### __Orange peel__
|
||||||
|
|
||||||
Finishes on real cars (particularly on mass produced cars for the general market) tend to have imperfections that appear as slight ripples in the paint. The orange peel effect mimics this and makes cars look more realistic.
|
Finishes on real cars (particularly on mass produced cars for the general market) tend to have imperfections that appear as slight ripples in the paint. The orange peel effect mimics this and makes cars look more realistic.
|
||||||
|
|
||||||
|
@ -223,13 +223,13 @@ Finishes on real cars (particularly on mass produced cars for the general market
|
||||||
|
|
||||||
#### __Flakes__
|
#### __Flakes__
|
||||||
|
|
||||||
Some cars have paint jobs that include flakes of other material, such as metals or ceramics, to give the car a `metallic` or `pearlescant` appearance, adding extra glints and reflections that react in an attractive way to light. The flakes parameters allows CARLA to mimic this. To mimic metallic finishes, it would be
|
Some cars have paint jobs that include flakes of other material, such as metals or ceramics, to give the car a `metallic` or `pearlescant` appearance, adding extra glints and reflections that react in an attractive way to light. The flakes parameters allows CARLA to mimic this. To mimic metallic finishes, it would be
|
||||||
|
|
||||||
![flakes](img/tuto_content_authoring_vehicles/flakes.gif)
|
![flakes](img/tuto_content_authoring_vehicles/flakes.gif)
|
||||||
|
|
||||||
#### __Dust__
|
#### __Dust__
|
||||||
|
|
||||||
Cars often accumulate grease and dust on the body that adds additional texture to the paint, affecting the way it reflects the light. The dust parameters allow you to add patches of disruption to the coat to mimic foreign materials sticking to the paint.
|
Cars often accumulate grease and dust on the body that adds additional texture to the paint, affecting the way it reflects the light. The dust parameters allow you to add patches of disruption to the coat to mimic foreign materials sticking to the paint.
|
||||||
|
|
||||||
![dust](img/tuto_content_authoring_vehicles/change_dust.gif)
|
![dust](img/tuto_content_authoring_vehicles/change_dust.gif)
|
||||||
|
|
||||||
|
@ -245,15 +245,15 @@ Here we see the glass parts attached to the main bodywork (not the doors or othe
|
||||||
|
|
||||||
![main_glass](img/tuto_content_authoring_vehicles/glass.png)
|
![main_glass](img/tuto_content_authoring_vehicles/glass.png)
|
||||||
|
|
||||||
If we separate the constituent mesh parts, we can see that the glass profile is separated into 4 different layers.
|
If we separate the constituent mesh parts, we can see that the glass profile is separated into 4 different layers.
|
||||||
|
|
||||||
![main_glass_expanded](img/tuto_content_authoring_vehicles/glass_expanded.png)
|
![main_glass_expanded](img/tuto_content_authoring_vehicles/glass_expanded.png)
|
||||||
|
|
||||||
The 4 layers are separated into 2 groups, the exterior layers, with normals facing out of the vehicle and the interior layers, with mesh normals facing into the vehicle interior. The following diagram demonstrates
|
The 4 layers are separated into 2 groups, the exterior layers, with normals facing out of the vehicle and the interior layers, with mesh normals facing into the vehicle interior. The following diagram demonstrates
|
||||||
|
|
||||||
![glass_layers](img/tuto_content_authoring_vehicles/glass_layers.png)
|
![glass_layers](img/tuto_content_authoring_vehicles/glass_layers.png)
|
||||||
|
|
||||||
Once you have created your mesh layers, import them in the content browser into the Unreal Editor in the folder where you have stored your vehicle.
|
Once you have created your mesh layers, import them in the content browser into the Unreal Editor in the folder where you have stored your vehicle.
|
||||||
|
|
||||||
Shift select the 4 glass layers and drag them into the map so you can see them.
|
Shift select the 4 glass layers and drag them into the map so you can see them.
|
||||||
|
|
||||||
|
@ -288,7 +288,7 @@ For the wheels of CARLA vehicles, we need to set up a blueprint class for each w
|
||||||
|
|
||||||
### Wheel blueprint
|
### Wheel blueprint
|
||||||
|
|
||||||
Inside the folder where you have your new vehicle, right click and choose to create a new blueprint class. Search for
|
Inside the folder where you have your new vehicle, right click and choose to create a new blueprint class. Search for
|
||||||
|
|
||||||
![wheel_blueprint](img/tuto_content_authoring_vehicles/wheel_blueprint.png)
|
![wheel_blueprint](img/tuto_content_authoring_vehicles/wheel_blueprint.png)
|
||||||
|
|
||||||
|
@ -298,12 +298,12 @@ Double click on the blueprint to adjust it:
|
||||||
|
|
||||||
### Collision mesh
|
### Collision mesh
|
||||||
|
|
||||||
Firstly, the default cylinder used for the collision mesh has a high polygon count, so we should replace this with a low polygon version. In the content browser locate the `CollisionWheel` mesh inside `Content > Carla > Blueprints > Vehicles`. Drag it onto the
|
Firstly, the default cylinder used for the collision mesh has a high polygon count, so we should replace this with a low polygon version. In the content browser locate the `CollisionWheel` mesh inside `Content > Carla > Blueprints > Vehicles`. Drag it onto the
|
||||||
`Collision Mesh` slot in the details panel of the blueprint. This will improve performance without any noticeable deficit to physics simulation.
|
`Collision Mesh` slot in the details panel of the blueprint. This will improve performance without any noticeable deficit to physics simulation.
|
||||||
|
|
||||||
### Tire configuration
|
### Tire configuration
|
||||||
|
|
||||||
Next, we set the tire configuration. Inside `Content > Carla > Blueprints > Vehicles` locate the `CommonTireConfig` configuration and drag it onto the `Tire Config` section of the blueprint. If you double click on the Tire Config in the blueprint, you can adjust the Friction Scale, you can modify the behavior of the vehicle's road handling. By default it is set at 3.5, a value suitable for most vehicle use cases. However, if you wish to model for example a racing vehicle with slick tires, this would be the appropriate parameter to adjust.
|
Next, we set the tire configuration. Inside `Content > Carla > Blueprints > Vehicles` locate the `CommonTireConfig` configuration and drag it onto the `Tire Config` section of the blueprint. If you double click on the Tire Config in the blueprint, you can adjust the Friction Scale, you can modify the behavior of the vehicle's road handling. By default it is set at 3.5, a value suitable for most vehicle use cases. However, if you wish to model for example a racing vehicle with slick tires, this would be the appropriate parameter to adjust.
|
||||||
|
|
||||||
### Wheel dimensions
|
### Wheel dimensions
|
||||||
|
|
||||||
|
@ -316,24 +316,24 @@ Now plug these numbers into the `Wheel` section of the blueprint.Take care to re
|
||||||
![bp_wheel_dimensions](img/tuto_content_authoring_vehicles/bp_wheel_dimensions.png)
|
![bp_wheel_dimensions](img/tuto_content_authoring_vehicles/bp_wheel_dimensions.png)
|
||||||
|
|
||||||
|
|
||||||
`Affected by handbrake` should be checked for both rear wheels.
|
`Affected by handbrake` should be checked for both rear wheels.
|
||||||
|
|
||||||
`Steer angle` should be set to the maximum intended steer angle for both front wheels and set to zero for both rear wheels.
|
`Steer angle` should be set to the maximum intended steer angle for both front wheels and set to zero for both rear wheels.
|
||||||
|
|
||||||
### __Suspension characteristics__
|
### __Suspension characteristics__
|
||||||
|
|
||||||
The default values here provide a reasonable starting point. View [__this guide__](tuto_D_customize_vehicle_suspension.md) to set suspension characteristics appropriate to your vehicle type.
|
The default values here provide a reasonable starting point. View [__this guide__](tuto_D_customize_vehicle_suspension.md) to set suspension characteristics appropriate to your vehicle type.
|
||||||
|
|
||||||
|
|
||||||
## Lights
|
## Lights
|
||||||
|
|
||||||
The last element to complete a realistic vehicle for CARLA is the lights, headlights, brake lights, blinkers etc. In your 3D modelling application, you should model some shapes that resemble the lights of the vehicle you are replicating. This would be flat discs or flat cuboid structures for most headlights. Some vehicles may also have strips of LEDs.
|
The last element to complete a realistic vehicle for CARLA is the lights, headlights, brake lights, blinkers etc. In your 3D modelling application, you should model some shapes that resemble the lights of the vehicle you are replicating. This would be flat discs or flat cuboid structures for most headlights. Some vehicles may also have strips of LEDs.
|
||||||
|
|
||||||
![lights_blender](img/tuto_content_authoring_vehicles/lights_blender.png)
|
![lights_blender](img/tuto_content_authoring_vehicles/lights_blender.png)
|
||||||
|
|
||||||
### UV map
|
### UV map
|
||||||
|
|
||||||
The different types of lights (headlights, blinkers, brake lights, etc.) are distinguished using a texture. You need to create a UV map in your 3D modelling application and position the lights to match up with the relevant region of the texture.
|
The different types of lights (headlights, blinkers, brake lights, etc.) are distinguished using a texture. You need to create a UV map in your 3D modelling application and position the lights to match up with the relevant region of the texture.
|
||||||
|
|
||||||
![lights_uv](img/tuto_content_authoring_vehicles/lights_uv_map.png)
|
![lights_uv](img/tuto_content_authoring_vehicles/lights_uv_map.png)
|
||||||
|
|
||||||
|
|
|
@ -1,45 +1,45 @@
|
||||||
# Tutorials
|
# Tutorials
|
||||||
|
|
||||||
Here you will find the multitude of tutorials available to help you understand how to use CARLA's many features.
|
Here you will find the multitude of tutorials available to help you understand how to use CARLA's many features.
|
||||||
|
|
||||||
## General
|
## General
|
||||||
|
|
||||||
### CARLA features
|
### CARLA features
|
||||||
|
|
||||||
[__Retrieve simulation data__](tuto_G_retrieve_data.md) — A step by step guide to properly gather data using the recorder.
|
* [__Retrieve simulation data__](tuto_G_retrieve_data.md) — A step by step guide to properly gather data using the recorder.
|
||||||
[__Traffic manager__](tuto_G_traffic_manager.md) — How to use traffic manager to guide traffic around your town.
|
* [__Traffic manager__](tuto_G_traffic_manager.md) — How to use traffic manager to guide traffic around your town.
|
||||||
[__Texture streaming__](tuto_G_texture_streaming.md) — Modify textures of map objects in real time to add variation.
|
* [__Texture streaming__](tuto_G_texture_streaming.md) — Modify textures of map objects in real time to add variation.
|
||||||
[__Instance segmentation camera__](tuto_G_instance_segmentation_sensor.md) — Use an instance segmentation camera to distinguish objects of the same class.
|
* [__Instance segmentation camera__](tuto_G_instance_segmentation_sensor.md) — Use an instance segmentation camera to distinguish objects of the same class.
|
||||||
[__Bounding boxes__](tuto_G_bounding_boxes.md) — Project bounding boxes from CARLA objects into the camera.
|
* [__Bounding boxes__](tuto_G_bounding_boxes.md) — Project bounding boxes from CARLA objects into the camera.
|
||||||
[__Pedestrian bones__](tuto_G_pedestrian_bones.md) — Project pedestrian skeleton into camera plane.
|
* [__Pedestrian bones__](tuto_G_pedestrian_bones.md) — Project pedestrian skeleton into camera plane.
|
||||||
[__Control walker skeletons__](tuto_G_control_walker_skeletons.md) — Animate walkers using skeletons.
|
* [__Control walker skeletons__](tuto_G_control_walker_skeletons.md) — Animate walkers using skeletons.
|
||||||
|
|
||||||
### Building and integration
|
### Building and integration
|
||||||
|
|
||||||
[__Build Unreal Engine and CARLA in Docker__](build_docker_unreal.md) — Build Unreal Engine and CARLA in Docker.
|
* [__Build Unreal Engine and CARLA in Docker__](build_docker_unreal.md) — Build Unreal Engine and CARLA in Docker.
|
||||||
[__CarSim Integration__](tuto_G_carsim_integration.md) — Tutorial on how to run a simulation using the CarSim vehicle dynamics engine.
|
* [__CarSim Integration__](tuto_G_carsim_integration.md) — Tutorial on how to run a simulation using the CarSim vehicle dynamics engine.
|
||||||
[__RLlib Integration__](tuto_G_rllib_integration.md) — Find out how to run your own experiment using the RLlib library.
|
* [__RLlib Integration__](tuto_G_rllib_integration.md) — Find out how to run your own experiment using the RLlib library.
|
||||||
[__Chrono Integration__](tuto_G_chrono.md) — Use the Chrono integration to simulation physics.
|
* [__Chrono Integration__](tuto_G_chrono.md) — Use the Chrono integration to simulation physics.
|
||||||
[__PyGame control__](tuto_G_pygame.md) — Use PyGame to display the output of camera sensors.
|
* [__PyGame control__](tuto_G_pygame.md) — Use PyGame to display the output of camera sensors.
|
||||||
|
|
||||||
## Assets and maps
|
## Assets and maps
|
||||||
|
|
||||||
[__Generate maps with OpenStreetMap__](tuto_G_openstreetmap.md) — Use OpenStreetMap to generate maps for use in simulations.
|
* [__Generate maps with OpenStreetMap__](tuto_G_openstreetmap.md) — Use OpenStreetMap to generate maps for use in simulations.
|
||||||
[__Add a new vehicle__](tuto_A_add_vehicle.md) — Prepare a vehicle to be used in CARLA.
|
* [__Add a new vehicle__](tuto_A_add_vehicle.md) — Prepare a vehicle to be used in CARLA.
|
||||||
[__Add new props__](tuto_A_add_props.md) — Import additional props into CARLA.
|
* [__Add new props__](tuto_A_add_props.md) — Import additional props into CARLA.
|
||||||
[__Create standalone packages__](tuto_A_create_standalone.md) — Generate and handle standalone packages for assets.
|
* [__Create standalone packages__](tuto_A_create_standalone.md) — Generate and handle standalone packages for assets.
|
||||||
[__Material customization__](tuto_A_material_customization.md) — Edit vehicle and building materials.
|
* [__Material customization__](tuto_A_material_customization.md) — Edit vehicle and building materials.
|
||||||
|
|
||||||
## Developers
|
## Developers
|
||||||
|
|
||||||
[__How to upgrade content__](tuto_D_contribute_assets.md) — Add new content to CARLA.
|
* [__How to upgrade content__](tuto_D_contribute_assets.md) — Add new content to CARLA.
|
||||||
[__Create a sensor__](tuto_D_create_sensor.md) — Develop a new sensor to be used in CARLA.
|
* [__Create a sensor__](tuto_D_create_sensor.md) — Develop a new sensor to be used in CARLA.
|
||||||
[__Create semantic tags__](tuto_D_create_semantic_tags.md) — Define customized tags for semantic segmentation.
|
* [__Create semantic tags__](tuto_D_create_semantic_tags.md) — Define customized tags for semantic segmentation.
|
||||||
[__Customize vehicle suspension__](tuto_D_customize_vehicle_suspension.md) — Modify the suspension system of a vehicle.
|
* [__Customize vehicle suspension__](tuto_D_customize_vehicle_suspension.md) — Modify the suspension system of a vehicle.
|
||||||
[__Generate detailed colliders__](tuto_D_generate_colliders.md) — Create detailed colliders for vehicles.
|
* [__Generate detailed colliders__](tuto_D_generate_colliders.md) — Create detailed colliders for vehicles.
|
||||||
[__Make a release__](tuto_D_make_release.md) — How to make a release of CARLA
|
* [__Make a release__](tuto_D_make_release.md) — How to make a release of CARLA
|
||||||
|
|
||||||
## Video tutorials
|
## Video tutorials
|
||||||
|
|
||||||
[__Fundamentals__](https://www.youtube.com/watch?v=pONr1R1dy88) — Learn the fundamental concepts of CARLA and start your first script. [__CODE__](https://carla-releases.s3.eu-west-3.amazonaws.com/Docs/Fundamentals.ipynb)
|
* [__Fundamentals__](https://www.youtube.com/watch?v=pONr1R1dy88) — Learn the fundamental concepts of CARLA and start your first script. [__CODE__](https://carla-releases.s3.us-east-005.backblazeb2.com/Docs/Fundamentals.ipynb)
|
||||||
[__An in depth look at CARLA's sensors__](https://www.youtube.com/watch?v=om8klsBj4rc) — An in depth look at CARLA's sensors and how to use them. [__CODE__](https://carla-releases.s3.eu-west-3.amazonaws.com/Docs/Sensors_code.zip)
|
* [__An in depth look at CARLA's sensors__](https://www.youtube.com/watch?v=om8klsBj4rc) — An in depth look at CARLA's sensors and how to use them. [__CODE__](https://carla-releases.s3.us-east-005.backblazeb2.com/Docs/Sensors_code.zip)
|
||||||
|
|
|
@ -11,91 +11,177 @@ pipeline
|
||||||
|
|
||||||
stages
|
stages
|
||||||
{
|
{
|
||||||
stage('Creating nodes')
|
//stage('Building CARLA')
|
||||||
{
|
//{
|
||||||
agent { label "master" }
|
//parallel
|
||||||
steps
|
//{
|
||||||
{
|
|
||||||
script
|
|
||||||
{
|
|
||||||
JOB_ID = "${env.BUILD_TAG}"
|
|
||||||
jenkinsLib = load("/home/jenkins/jenkins_426.groovy")
|
|
||||||
|
|
||||||
jenkinsLib.CreateUbuntuBuildNode(JOB_ID)
|
|
||||||
jenkinsLib.CreateWindowsBuildNode(JOB_ID)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
stage('Building CARLA')
|
|
||||||
{
|
|
||||||
parallel
|
|
||||||
{
|
|
||||||
stage('ubuntu')
|
stage('ubuntu')
|
||||||
{
|
{
|
||||||
agent { label "ubuntu && build && ${JOB_ID}" }
|
agent { label "gpu" }
|
||||||
environment
|
environment
|
||||||
{
|
{
|
||||||
UE4_ROOT = '/home/jenkins/UnrealEngine_4.26'
|
UE4_ROOT = '/home/jenkins/UnrealEngine_4.26'
|
||||||
}
|
}
|
||||||
stages
|
stages
|
||||||
{
|
{
|
||||||
stage('ubuntu setup')
|
stage('stash dependencies')
|
||||||
{
|
{
|
||||||
|
agent{ label 'cache' }
|
||||||
|
options{skipDefaultCheckout()}
|
||||||
steps
|
steps
|
||||||
{
|
{
|
||||||
sh 'git update-index --skip-worktree Unreal/CarlaUE4/CarlaUE4.uproject'
|
sh "echo ${BRANCH_NAME}"
|
||||||
sh 'make setup ARGS="--python-version=3.7,2 --target-wheel-platform=manylinux_2_27_x86_64 --chrono"'
|
sh "set"
|
||||||
|
sh "cp ../../Build_Linux.tar.gz ."
|
||||||
|
stash includes: 'Build_Linux.tar.gz', name: 'build_cache'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
stage('ubuntu build')
|
stage('prepare environment')
|
||||||
{
|
{
|
||||||
steps
|
parallel
|
||||||
{
|
{
|
||||||
sh 'make LibCarla'
|
stage('generate libs')
|
||||||
sh 'make PythonAPI ARGS="--python-version=3.7,2 --target-wheel-platform=manylinux_2_27_x86_64"'
|
|
||||||
sh 'make CarlaUE4Editor ARGS="--chrono"'
|
|
||||||
sh 'make plugins'
|
|
||||||
sh 'make examples'
|
|
||||||
}
|
|
||||||
post
|
|
||||||
{
|
|
||||||
always
|
|
||||||
{
|
{
|
||||||
archiveArtifacts 'PythonAPI/carla/dist/*.egg'
|
stages
|
||||||
archiveArtifacts 'PythonAPI/carla/dist/*.whl'
|
{
|
||||||
stash includes: 'PythonAPI/carla/dist/*.egg', name: 'ubuntu_eggs'
|
stage('ubuntu setup')
|
||||||
stash includes: 'PythonAPI/carla/dist/*.whl', name: 'ubuntu_wheels'
|
{
|
||||||
|
steps
|
||||||
|
{
|
||||||
|
unstash name: 'build_cache'
|
||||||
|
sh 'tar -xvzf Build_Linux.tar.gz'
|
||||||
|
sh 'git update-index --skip-worktree Unreal/CarlaUE4/CarlaUE4.uproject'
|
||||||
|
sh 'make setup ARGS="--python-version=3.8,2 --target-wheel-platform=manylinux_2_27_x86_64 --chrono"'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
stage('ubuntu build')
|
||||||
|
{
|
||||||
|
steps
|
||||||
|
{
|
||||||
|
sh 'make LibCarla'
|
||||||
|
sh 'make PythonAPI ARGS="--python-version=3.8,2 --target-wheel-platform=manylinux_2_27_x86_64"'
|
||||||
|
sh 'make CarlaUE4Editor ARGS="--chrono"'
|
||||||
|
sh 'make plugins'
|
||||||
|
sh 'make examples'
|
||||||
|
}
|
||||||
|
post
|
||||||
|
{
|
||||||
|
always
|
||||||
|
{
|
||||||
|
archiveArtifacts 'PythonAPI/carla/dist/*.egg'
|
||||||
|
archiveArtifacts 'PythonAPI/carla/dist/*.whl'
|
||||||
|
stash includes: 'PythonAPI/carla/dist/*.egg', name: 'ubuntu_eggs'
|
||||||
|
stash includes: 'PythonAPI/carla/dist/*.whl', name: 'ubuntu_wheels'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
stage('ubuntu unit tests')
|
||||||
|
{
|
||||||
|
steps
|
||||||
|
{
|
||||||
|
sh 'make check ARGS="--all --xml --python-version=3.8,2 --target-wheel-platform=manylinux_2_27_x86_64"'
|
||||||
|
}
|
||||||
|
post
|
||||||
|
{
|
||||||
|
always
|
||||||
|
{
|
||||||
|
junit 'Build/test-results/*.xml'
|
||||||
|
archiveArtifacts 'profiler.csv'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
stage('Download additional resources')
|
||||||
}
|
|
||||||
stage('ubuntu unit tests')
|
|
||||||
{
|
|
||||||
steps
|
|
||||||
{
|
|
||||||
sh 'make check ARGS="--all --xml --python-version=3.7,2 --target-wheel-platform=manylinux_2_27_x86_64"'
|
|
||||||
}
|
|
||||||
post
|
|
||||||
{
|
|
||||||
always
|
|
||||||
{
|
{
|
||||||
junit 'Build/test-results/*.xml'
|
stages
|
||||||
archiveArtifacts 'profiler.csv'
|
{
|
||||||
|
stage('TEST: Checkout Doxygen repo')
|
||||||
|
{
|
||||||
|
when { branch "ruben/jenkins_migration"; }
|
||||||
|
steps
|
||||||
|
{
|
||||||
|
|
||||||
|
dir('doc_repo')
|
||||||
|
{
|
||||||
|
checkout scmGit(
|
||||||
|
branches: [[name: '*/ruben/jenkins_migration']],
|
||||||
|
extensions: [
|
||||||
|
cleanBeforeCheckout(),
|
||||||
|
checkoutOption(120),
|
||||||
|
localBranch("**"),
|
||||||
|
cloneOption(noTags:false, reference:'', shallow: false, timeout:120)
|
||||||
|
],
|
||||||
|
userRemoteConfigs: [
|
||||||
|
[
|
||||||
|
credentialsId: 'github_token_as_pwd_2',
|
||||||
|
url: 'https://github.com/carla-simulator/carla-simulator.github.io.git'
|
||||||
|
]
|
||||||
|
]
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
stage('Checkout Doxygen repo')
|
||||||
|
{
|
||||||
|
when { anyOf { branch "master"; branch "dev"; buildingTag() } }
|
||||||
|
steps
|
||||||
|
{
|
||||||
|
|
||||||
|
dir('doc_repo')
|
||||||
|
{
|
||||||
|
checkout scmGit(
|
||||||
|
branches: [[name: '*/master']],
|
||||||
|
extensions: [
|
||||||
|
cleanBeforeCheckout(),
|
||||||
|
checkoutOption(120),
|
||||||
|
localBranch("**"),
|
||||||
|
cloneOption(noTags:false, reference:'', shallow: false, timeout:120)
|
||||||
|
],
|
||||||
|
userRemoteConfigs: [
|
||||||
|
[
|
||||||
|
credentialsId: 'github_token_as_pwd_2',
|
||||||
|
url: 'https://github.com/carla-simulator/carla-simulator.github.io.git'
|
||||||
|
]
|
||||||
|
]
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
stage('ubuntu retrieve content')
|
||||||
|
{
|
||||||
|
steps
|
||||||
|
{
|
||||||
|
sh './Update.sh'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
stage('ubuntu retrieve content')
|
|
||||||
{
|
|
||||||
steps
|
|
||||||
{
|
|
||||||
sh './Update.sh'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
stage('ubuntu package')
|
stage('ubuntu package')
|
||||||
{
|
{
|
||||||
steps
|
steps
|
||||||
{
|
{
|
||||||
sh 'make package ARGS="--python-version=3.7,2 --target-wheel-platform=manylinux_2_27_x86_64 --chrono"'
|
sh 'make package ARGS="--python-version=3.8,2 --target-wheel-platform=manylinux_2_27_x86_64 --chrono"'
|
||||||
sh 'make package ARGS="--packages=AdditionalMaps,Town06_Opt,Town07_Opt,Town11,Town12,Town13,Town15 --target-archive=AdditionalMaps --clean-intermediate --python-version=3.7,2 --target-wheel-platform=manylinux_2_27_x86_64"'
|
sh '''
|
||||||
|
prefix="PR-"
|
||||||
|
case "$BRANCH_NAME" in
|
||||||
|
("$prefix"*)
|
||||||
|
echo "This is a pull request, skipping complete package"
|
||||||
|
;;
|
||||||
|
(*)
|
||||||
|
echo "Generating complete package"
|
||||||
|
make package ARGS="--packages=AdditionalMaps,Town06_Opt,Town07_Opt,Town11,Town12,Town13,Town15 --target-archive=AdditionalMaps --clean-intermediate --python-version=3.8,2 --target-wheel-platform=manylinux_2_27_x86_64"
|
||||||
|
tar -czf CarlaUE4_logs.tar.gz Unreal/CarlaUE4/Saved/Logs/
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
'''
|
||||||
sh 'make examples ARGS="localhost 3654"'
|
sh 'make examples ARGS="localhost 3654"'
|
||||||
}
|
}
|
||||||
post
|
post
|
||||||
|
@ -103,105 +189,161 @@ pipeline
|
||||||
always
|
always
|
||||||
{
|
{
|
||||||
archiveArtifacts 'Dist/*.tar.gz'
|
archiveArtifacts 'Dist/*.tar.gz'
|
||||||
|
archiveArtifacts artifacts:'CarlaUE4_logs.tar.gz',
|
||||||
|
allowEmptyArchive: true
|
||||||
stash includes: 'Dist/CARLA*.tar.gz', name: 'ubuntu_package'
|
stash includes: 'Dist/CARLA*.tar.gz', name: 'ubuntu_package'
|
||||||
// stash includes: 'Dist/AdditionalMaps*.tar.gz', name: 'ubuntu_package2'
|
|
||||||
stash includes: 'Examples/', name: 'ubuntu_examples'
|
stash includes: 'Examples/', name: 'ubuntu_examples'
|
||||||
}
|
}
|
||||||
success
|
}
|
||||||
{
|
}
|
||||||
node('master')
|
|
||||||
{
|
|
||||||
script
|
|
||||||
{
|
|
||||||
JOB_ID = "${env.BUILD_TAG}"
|
|
||||||
jenkinsLib = load("/home/jenkins/jenkins_426.groovy")
|
|
||||||
|
|
||||||
jenkinsLib.CreateUbuntuTestNode(JOB_ID)
|
stage('Testing and documentation')
|
||||||
|
{
|
||||||
|
parallel
|
||||||
|
{
|
||||||
|
stage('Testing')
|
||||||
|
{
|
||||||
|
stages
|
||||||
|
{
|
||||||
|
stage('ubuntu smoke tests')
|
||||||
|
{
|
||||||
|
steps
|
||||||
|
{
|
||||||
|
unstash name: 'ubuntu_eggs'
|
||||||
|
unstash name: 'ubuntu_wheels'
|
||||||
|
unstash name: 'ubuntu_package'
|
||||||
|
unstash name: 'ubuntu_examples'
|
||||||
|
sh 'tar -xvzf Dist/CARLA*.tar.gz -C Dist/'
|
||||||
|
sh 'DISPLAY= ./Dist/CarlaUE4.sh -nullrhi -RenderOffScreen --carla-rpc-port=3654 --carla-streaming-port=0 -nosound > CarlaUE4.log &'
|
||||||
|
sh 'make smoke_tests ARGS="--xml --python-version=3.8 --target-wheel-platform=manylinux_2_27_x86_64"'
|
||||||
|
sh 'make run-examples ARGS="localhost 3654"'
|
||||||
|
}
|
||||||
|
post
|
||||||
|
{
|
||||||
|
always
|
||||||
|
{
|
||||||
|
archiveArtifacts 'CarlaUE4.log'
|
||||||
|
junit 'Build/test-results/smoke-tests-*.xml'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
stage('Generate documentation')
|
||||||
|
{
|
||||||
|
stages
|
||||||
|
{
|
||||||
|
stage('ubuntu Doxygen generation')
|
||||||
|
{
|
||||||
|
when { anyOf { branch "master"; branch "dev"; buildingTag() } }
|
||||||
|
steps
|
||||||
|
{
|
||||||
|
sh 'make docs'
|
||||||
|
sh 'tar -czf carla_doc.tar.gz ./Doxygen'
|
||||||
|
stash includes: 'carla_doc.tar.gz', name: 'carla_docs'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
stage('TEST: ubuntu Doxygen generation')
|
||||||
|
{
|
||||||
|
when { branch "ruben/jenkins_migration"; }
|
||||||
|
steps
|
||||||
|
{
|
||||||
|
sh 'make docs'
|
||||||
|
sh 'tar -czf carla_doc.tar.gz ./Doxygen'
|
||||||
|
stash includes: 'carla_doc.tar.gz', name: 'carla_docs'
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
stage('ubuntu smoke tests')
|
|
||||||
{
|
|
||||||
agent { label "ubuntu && gpu && ${JOB_ID}" }
|
|
||||||
steps
|
|
||||||
{
|
|
||||||
unstash name: 'ubuntu_eggs'
|
|
||||||
unstash name: 'ubuntu_wheels'
|
|
||||||
unstash name: 'ubuntu_package'
|
|
||||||
// unstash name: 'ubuntu_package2'
|
|
||||||
unstash name: 'ubuntu_examples'
|
|
||||||
sh 'tar -xvzf Dist/CARLA*.tar.gz -C Dist/'
|
|
||||||
// sh 'tar -xvzf Dist/AdditionalMaps*.tar.gz -C Dist/'
|
|
||||||
sh 'DISPLAY= ./Dist/CarlaUE4.sh -nullrhi -RenderOffScreen --carla-rpc-port=3654 --carla-streaming-port=0 -nosound > CarlaUE4.log &'
|
|
||||||
sh 'make smoke_tests ARGS="--xml --python-version=3.7 --target-wheel-platform=manylinux_2_27_x86_64"'
|
|
||||||
sh 'make run-examples ARGS="localhost 3654"'
|
|
||||||
}
|
|
||||||
post
|
|
||||||
{
|
|
||||||
always
|
|
||||||
{
|
|
||||||
archiveArtifacts 'CarlaUE4.log'
|
|
||||||
junit 'Build/test-results/smoke-tests-*.xml'
|
|
||||||
deleteDir()
|
|
||||||
node('master')
|
|
||||||
{
|
|
||||||
script
|
|
||||||
{
|
|
||||||
JOB_ID = "${env.BUILD_TAG}"
|
|
||||||
jenkinsLib = load("/home/jenkins/jenkins_426.groovy")
|
|
||||||
|
|
||||||
jenkinsLib.DeleteUbuntuTestNode(JOB_ID)
|
stage('Deployment and documentation publishing')
|
||||||
|
{
|
||||||
|
parallel
|
||||||
|
{
|
||||||
|
stage('Release Deployment')
|
||||||
|
{
|
||||||
|
stages
|
||||||
|
{
|
||||||
|
stage('TEST: ubuntu deploy sim')
|
||||||
|
{
|
||||||
|
when { branch "ruben/jenkins_migration"; }
|
||||||
|
steps
|
||||||
|
{
|
||||||
|
sh 'git checkout .'
|
||||||
|
sh 'make deploy ARGS="--test"'
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
stage('ubuntu deploy dev')
|
||||||
|
{
|
||||||
|
when { branch "dev"; }
|
||||||
|
steps
|
||||||
|
{
|
||||||
|
sh 'git checkout .'
|
||||||
|
sh 'make deploy ARGS="--replace-latest"'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
stage('ubuntu deploy master')
|
||||||
|
{
|
||||||
|
when { anyOf { branch "master"; buildingTag() } }
|
||||||
|
steps
|
||||||
|
{
|
||||||
|
sh 'git checkout .'
|
||||||
|
sh 'make deploy ARGS="--replace-latest --docker-push"'
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
stage('Publish documentation')
|
||||||
}
|
|
||||||
stage('ubuntu deploy dev')
|
|
||||||
{
|
|
||||||
when { branch "dev"; }
|
|
||||||
steps
|
|
||||||
{
|
|
||||||
sh 'git checkout .'
|
|
||||||
sh 'make deploy ARGS="--replace-latest"'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
stage('ubuntu deploy master')
|
|
||||||
{
|
|
||||||
when { anyOf { branch "master"; buildingTag() } }
|
|
||||||
steps
|
|
||||||
{
|
|
||||||
sh 'git checkout .'
|
|
||||||
sh 'make deploy ARGS="--replace-latest --docker-push"'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
stage('ubuntu Doxygen')
|
|
||||||
{
|
|
||||||
when { anyOf { branch "master"; branch "dev"; buildingTag() } }
|
|
||||||
steps
|
|
||||||
{
|
|
||||||
sh 'rm -rf ~/carla-simulator.github.io/Doxygen'
|
|
||||||
sh '''
|
|
||||||
cd ~/carla-simulator.github.io
|
|
||||||
git remote set-url origin git@docs:carla-simulator/carla-simulator.github.io.git
|
|
||||||
git fetch
|
|
||||||
git checkout -B master origin/master
|
|
||||||
'''
|
|
||||||
sh 'make docs'
|
|
||||||
sh 'cp -rf ./Doxygen ~/carla-simulator.github.io/'
|
|
||||||
sh '''
|
|
||||||
cd ~/carla-simulator.github.io
|
|
||||||
git add Doxygen
|
|
||||||
git commit -m "Updated c++ docs" || true
|
|
||||||
git push
|
|
||||||
'''
|
|
||||||
}
|
|
||||||
post
|
|
||||||
{
|
|
||||||
always
|
|
||||||
{
|
{
|
||||||
deleteDir()
|
stages
|
||||||
|
{
|
||||||
|
stage('ubuntu Doxygen upload')
|
||||||
|
{
|
||||||
|
when { anyOf { branch "master"; branch "dev"; buildingTag() } }
|
||||||
|
steps
|
||||||
|
{
|
||||||
|
dir('doc_repo')
|
||||||
|
{
|
||||||
|
unstash name: 'carla_docs'
|
||||||
|
withCredentials([gitUsernamePassword(credentialsId: 'github_token_as_pwd_2', gitToolName: 'git-tool')]) {
|
||||||
|
sh '''
|
||||||
|
tar -xvzf carla_doc.tar.gz
|
||||||
|
git add Doxygen
|
||||||
|
git commit -m "Updated c++ docs" || true
|
||||||
|
git push --set-upstream origin ruben/jenkins_migration
|
||||||
|
'''
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
stage('TEST: ubuntu Doxygen upload')
|
||||||
|
{
|
||||||
|
when { branch "ruben/jenkins_migration"; }
|
||||||
|
steps
|
||||||
|
{
|
||||||
|
dir('doc_repo')
|
||||||
|
{
|
||||||
|
unstash name: 'carla_docs'
|
||||||
|
withCredentials([gitUsernamePassword(credentialsId: 'github_token_as_pwd_2', gitToolName: 'git-tool')]) {
|
||||||
|
sh '''
|
||||||
|
tar -xvzf carla_doc.tar.gz
|
||||||
|
git add Doxygen
|
||||||
|
git commit -m "Updated c++ docs" || true
|
||||||
|
git push --set-upstream origin ruben/jenkins_migration
|
||||||
|
'''
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -211,23 +353,14 @@ pipeline
|
||||||
always
|
always
|
||||||
{
|
{
|
||||||
deleteDir()
|
deleteDir()
|
||||||
|
|
||||||
node('master')
|
|
||||||
{
|
|
||||||
script
|
|
||||||
{
|
|
||||||
JOB_ID = "${env.BUILD_TAG}"
|
|
||||||
jenkinsLib = load("/home/jenkins/jenkins_426.groovy")
|
|
||||||
|
|
||||||
jenkinsLib.DeleteUbuntuBuildNode(JOB_ID)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
/*
|
||||||
stage('windows')
|
stage('windows')
|
||||||
{
|
{
|
||||||
agent { label "windows && build && ${JOB_ID}" }
|
|
||||||
|
agent { label "windows" }
|
||||||
environment
|
environment
|
||||||
{
|
{
|
||||||
UE4_ROOT = 'C:\\UE_4.26'
|
UE4_ROOT = 'C:\\UE_4.26'
|
||||||
|
@ -239,11 +372,11 @@ pipeline
|
||||||
steps
|
steps
|
||||||
{
|
{
|
||||||
bat """
|
bat """
|
||||||
call ../setEnv64.bat
|
call C:\\Users\\jenkins\\setEnv64.bat
|
||||||
git update-index --skip-worktree Unreal/CarlaUE4/CarlaUE4.uproject
|
git update-index --skip-worktree Unreal/CarlaUE4/CarlaUE4.uproject
|
||||||
"""
|
"""
|
||||||
bat """
|
bat """
|
||||||
call ../setEnv64.bat
|
call C:\\Users\\jenkins\\setEnv64.bat
|
||||||
make setup ARGS="--chrono"
|
make setup ARGS="--chrono"
|
||||||
"""
|
"""
|
||||||
}
|
}
|
||||||
|
@ -253,19 +386,19 @@ pipeline
|
||||||
steps
|
steps
|
||||||
{
|
{
|
||||||
bat """
|
bat """
|
||||||
call ../setEnv64.bat
|
call C:\\Users\\jenkins\\setEnv64.bat
|
||||||
make LibCarla
|
make LibCarla
|
||||||
"""
|
"""
|
||||||
bat """
|
bat """
|
||||||
call ../setEnv64.bat
|
call C:\\Users\\jenkins\\setEnv64.bat
|
||||||
make PythonAPI
|
make PythonAPI
|
||||||
"""
|
"""
|
||||||
bat """
|
bat """
|
||||||
call ../setEnv64.bat
|
call C:\\Users\\jenkins\\setEnv64.bat
|
||||||
make CarlaUE4Editor ARGS="--chrono"
|
make CarlaUE4Editor ARGS="--chrono"
|
||||||
"""
|
"""
|
||||||
bat """
|
bat """
|
||||||
call ../setEnv64.bat
|
call C:\\Users\\jenkins\\setEnv64.bat
|
||||||
make plugins
|
make plugins
|
||||||
"""
|
"""
|
||||||
}
|
}
|
||||||
|
@ -283,7 +416,7 @@ pipeline
|
||||||
steps
|
steps
|
||||||
{
|
{
|
||||||
bat """
|
bat """
|
||||||
call ../setEnv64.bat
|
call C:\\Users\\jenkins\\setEnv64.bat
|
||||||
call Update.bat
|
call Update.bat
|
||||||
"""
|
"""
|
||||||
}
|
}
|
||||||
|
@ -293,11 +426,11 @@ pipeline
|
||||||
steps
|
steps
|
||||||
{
|
{
|
||||||
bat """
|
bat """
|
||||||
call ../setEnv64.bat
|
call C:\\Users\\jenkins\\setEnv64.bat
|
||||||
make package ARGS="--chrono"
|
make package ARGS="--chrono"
|
||||||
"""
|
"""
|
||||||
bat """
|
bat """
|
||||||
call ../setEnv64.bat
|
call C:\\Users\\jenkins\\setEnv64.bat
|
||||||
make package ARGS="--packages=AdditionalMaps,Town06_Opt,Town07_Opt,Town11,Town12,Town13,Town15 --target-archive=AdditionalMaps --clean-intermediate"
|
make package ARGS="--packages=AdditionalMaps,Town06_Opt,Town07_Opt,Town11,Town12,Town13,Town15 --target-archive=AdditionalMaps --clean-intermediate"
|
||||||
"""
|
"""
|
||||||
}
|
}
|
||||||
|
@ -307,38 +440,30 @@ pipeline
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
stage('windows deploy')
|
stage('windows deploy')
|
||||||
{
|
{
|
||||||
when { anyOf { branch "master"; branch "dev"; buildingTag() } }
|
when { anyOf { branch "master"; branch "dev"; buildingTag() } }
|
||||||
steps {
|
steps {
|
||||||
bat """
|
bat """
|
||||||
call ../setEnv64.bat
|
call C:\\Users\\jenkins\\setEnv64.bat
|
||||||
git checkout .
|
git checkout .
|
||||||
make deploy ARGS="--replace-latest"
|
REM make deploy ARGS="--replace-latest"
|
||||||
"""
|
"""
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
post
|
post
|
||||||
{
|
{
|
||||||
always
|
always
|
||||||
{
|
{
|
||||||
deleteDir()
|
deleteDir()
|
||||||
|
|
||||||
node('master')
|
|
||||||
{
|
|
||||||
script
|
|
||||||
{
|
|
||||||
JOB_ID = "${env.BUILD_TAG}"
|
|
||||||
jenkinsLib = load("/home/jenkins/jenkins_426.groovy")
|
|
||||||
|
|
||||||
jenkinsLib.DeleteWindowsBuildNode(JOB_ID)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}*/
|
||||||
}
|
|
||||||
}
|
//}
|
||||||
|
//}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -32,6 +32,38 @@ namespace client {
|
||||||
return GetEpisode().Lock()->GetActorAcceleration(*this);
|
return GetEpisode().Lock()->GetActorAcceleration(*this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
geom::Transform Actor::GetComponentWorldTransform(const std::string componentName) const {
|
||||||
|
return GetEpisode().Lock()->GetActorComponentWorldTransform(*this, componentName);
|
||||||
|
}
|
||||||
|
|
||||||
|
geom::Transform Actor::GetComponentRelativeTransform(const std::string componentName) const {
|
||||||
|
return GetEpisode().Lock()->GetActorComponentRelativeTransform(*this, componentName);
|
||||||
|
}
|
||||||
|
|
||||||
|
std::vector<geom::Transform> Actor::GetBoneWorldTransforms() const {
|
||||||
|
return GetEpisode().Lock()->GetActorBoneWorldTransforms(*this);
|
||||||
|
}
|
||||||
|
|
||||||
|
std::vector<geom::Transform> Actor::GetBoneRelativeTransforms() const {
|
||||||
|
return GetEpisode().Lock()->GetActorBoneRelativeTransforms(*this);
|
||||||
|
}
|
||||||
|
|
||||||
|
std::vector<std::string> Actor::GetComponentNames() const {
|
||||||
|
return GetEpisode().Lock()->GetActorComponentNames(*this);
|
||||||
|
}
|
||||||
|
|
||||||
|
std::vector<std::string> Actor::GetBoneNames() const {
|
||||||
|
return GetEpisode().Lock()->GetActorBoneNames(*this);
|
||||||
|
}
|
||||||
|
|
||||||
|
std::vector<geom::Transform> Actor::GetSocketWorldTransforms() const {
|
||||||
|
return GetEpisode().Lock()->GetActorSocketWorldTransforms(*this);
|
||||||
|
}
|
||||||
|
|
||||||
|
std::vector<geom::Transform> Actor::GetSocketRelativeTransforms() const {
|
||||||
|
return GetEpisode().Lock()->GetActorSocketRelativeTransforms(*this);
|
||||||
|
}
|
||||||
|
|
||||||
void Actor::SetLocation(const geom::Location &location) {
|
void Actor::SetLocation(const geom::Location &location) {
|
||||||
GetEpisode().Lock()->SetActorLocation(*this, location);
|
GetEpisode().Lock()->SetActorLocation(*this, location);
|
||||||
}
|
}
|
||||||
|
|
|
@ -60,6 +60,22 @@ namespace client {
|
||||||
/// acceleration calculated after the actor's velocity.
|
/// acceleration calculated after the actor's velocity.
|
||||||
geom::Vector3D GetAcceleration() const;
|
geom::Vector3D GetAcceleration() const;
|
||||||
|
|
||||||
|
geom::Transform GetComponentWorldTransform(const std::string componentName) const;
|
||||||
|
|
||||||
|
geom::Transform GetComponentRelativeTransform(const std::string componentName) const;
|
||||||
|
|
||||||
|
std::vector<geom::Transform> GetBoneWorldTransforms() const;
|
||||||
|
|
||||||
|
std::vector<geom::Transform> GetBoneRelativeTransforms() const;
|
||||||
|
|
||||||
|
std::vector<std::string> GetComponentNames() const;
|
||||||
|
|
||||||
|
std::vector<std::string> GetBoneNames() const;
|
||||||
|
|
||||||
|
std::vector<geom::Transform> GetSocketWorldTransforms() const;
|
||||||
|
|
||||||
|
std::vector<geom::Transform> GetSocketRelativeTransforms() const;
|
||||||
|
|
||||||
/// Teleport the actor to @a location.
|
/// Teleport the actor to @a location.
|
||||||
void SetLocation(const geom::Location &location);
|
void SetLocation(const geom::Location &location);
|
||||||
|
|
||||||
|
|
|
@ -119,17 +119,19 @@ namespace client {
|
||||||
const ActorBlueprint &blueprint,
|
const ActorBlueprint &blueprint,
|
||||||
const geom::Transform &transform,
|
const geom::Transform &transform,
|
||||||
Actor *parent_actor,
|
Actor *parent_actor,
|
||||||
rpc::AttachmentType attachment_type) {
|
rpc::AttachmentType attachment_type,
|
||||||
return _episode.Lock()->SpawnActor(blueprint, transform, parent_actor, attachment_type);
|
const std::string& socket_name) {
|
||||||
|
return _episode.Lock()->SpawnActor(blueprint, transform, parent_actor, attachment_type, GarbageCollectionPolicy::Inherit, socket_name);
|
||||||
}
|
}
|
||||||
|
|
||||||
SharedPtr<Actor> World::TrySpawnActor(
|
SharedPtr<Actor> World::TrySpawnActor(
|
||||||
const ActorBlueprint &blueprint,
|
const ActorBlueprint &blueprint,
|
||||||
const geom::Transform &transform,
|
const geom::Transform &transform,
|
||||||
Actor *parent_actor,
|
Actor *parent_actor,
|
||||||
rpc::AttachmentType attachment_type) noexcept {
|
rpc::AttachmentType attachment_type,
|
||||||
|
const std::string& socket_name) noexcept {
|
||||||
try {
|
try {
|
||||||
return SpawnActor(blueprint, transform, parent_actor, attachment_type);
|
return SpawnActor(blueprint, transform, parent_actor, attachment_type, socket_name);
|
||||||
} catch (const std::exception &) {
|
} catch (const std::exception &) {
|
||||||
return nullptr;
|
return nullptr;
|
||||||
}
|
}
|
||||||
|
|
|
@ -29,6 +29,7 @@
|
||||||
#include "carla/rpc/Texture.h"
|
#include "carla/rpc/Texture.h"
|
||||||
#include "carla/rpc/MaterialParameter.h"
|
#include "carla/rpc/MaterialParameter.h"
|
||||||
|
|
||||||
|
#include <string>
|
||||||
#include <boost/optional.hpp>
|
#include <boost/optional.hpp>
|
||||||
|
|
||||||
namespace carla {
|
namespace carla {
|
||||||
|
@ -112,7 +113,8 @@ namespace client {
|
||||||
const ActorBlueprint &blueprint,
|
const ActorBlueprint &blueprint,
|
||||||
const geom::Transform &transform,
|
const geom::Transform &transform,
|
||||||
Actor *parent = nullptr,
|
Actor *parent = nullptr,
|
||||||
rpc::AttachmentType attachment_type = rpc::AttachmentType::Rigid);
|
rpc::AttachmentType attachment_type = rpc::AttachmentType::Rigid,
|
||||||
|
const std::string& socket_name = "");
|
||||||
|
|
||||||
/// Same as SpawnActor but return nullptr on failure instead of throwing an
|
/// Same as SpawnActor but return nullptr on failure instead of throwing an
|
||||||
/// exception.
|
/// exception.
|
||||||
|
@ -120,7 +122,8 @@ namespace client {
|
||||||
const ActorBlueprint &blueprint,
|
const ActorBlueprint &blueprint,
|
||||||
const geom::Transform &transform,
|
const geom::Transform &transform,
|
||||||
Actor *parent = nullptr,
|
Actor *parent = nullptr,
|
||||||
rpc::AttachmentType attachment_type = rpc::AttachmentType::Rigid) noexcept;
|
rpc::AttachmentType attachment_type = rpc::AttachmentType::Rigid,
|
||||||
|
const std::string& socket_name = "") noexcept;
|
||||||
|
|
||||||
/// Block calling thread until a world tick is received.
|
/// Block calling thread until a world tick is received.
|
||||||
WorldSnapshot WaitForTick(time_duration timeout) const;
|
WorldSnapshot WaitForTick(time_duration timeout) const;
|
||||||
|
|
|
@ -326,11 +326,12 @@ namespace detail {
|
||||||
return _pimpl->CallAndWait<rpc::Actor>("spawn_actor", description, transform);
|
return _pimpl->CallAndWait<rpc::Actor>("spawn_actor", description, transform);
|
||||||
}
|
}
|
||||||
|
|
||||||
rpc::Actor Client::SpawnActorWithParent(
|
rpc::Actor Client::SpawnActorWithParent(
|
||||||
const rpc::ActorDescription &description,
|
const rpc::ActorDescription &description,
|
||||||
const geom::Transform &transform,
|
const geom::Transform &transform,
|
||||||
rpc::ActorId parent,
|
rpc::ActorId parent,
|
||||||
rpc::AttachmentType attachment_type) {
|
rpc::AttachmentType attachment_type,
|
||||||
|
const std::string& socket_name) {
|
||||||
|
|
||||||
if (attachment_type == rpc::AttachmentType::SpringArm ||
|
if (attachment_type == rpc::AttachmentType::SpringArm ||
|
||||||
attachment_type == rpc::AttachmentType::SpringArmGhost)
|
attachment_type == rpc::AttachmentType::SpringArmGhost)
|
||||||
|
@ -348,7 +349,8 @@ namespace detail {
|
||||||
description,
|
description,
|
||||||
transform,
|
transform,
|
||||||
parent,
|
parent,
|
||||||
attachment_type);
|
attachment_type,
|
||||||
|
socket_name);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool Client::DestroyActor(rpc::ActorId actor) {
|
bool Client::DestroyActor(rpc::ActorId actor) {
|
||||||
|
@ -408,6 +410,44 @@ namespace detail {
|
||||||
_pimpl->AsyncCall("add_actor_torque", actor, vector);
|
_pimpl->AsyncCall("add_actor_torque", actor, vector);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
geom::Transform Client::GetActorComponentWorldTransform(rpc::ActorId actor, const std::string componentName) {
|
||||||
|
return _pimpl->CallAndWait<geom::Transform>("get_actor_component_world_transform", actor, componentName);
|
||||||
|
}
|
||||||
|
|
||||||
|
geom::Transform Client::GetActorComponentRelativeTransform(rpc::ActorId actor, const std::string componentName) {
|
||||||
|
return _pimpl->CallAndWait<geom::Transform>("get_actor_component_relative_transform", actor, componentName);
|
||||||
|
}
|
||||||
|
|
||||||
|
std::vector<geom::Transform> Client::GetActorBoneWorldTransforms(rpc::ActorId actor) {
|
||||||
|
using return_t = std::vector<geom::Transform>;
|
||||||
|
return _pimpl->CallAndWait<return_t>("get_actor_bone_world_transforms", actor);
|
||||||
|
}
|
||||||
|
|
||||||
|
std::vector<geom::Transform> Client::GetActorBoneRelativeTransforms(rpc::ActorId actor) {
|
||||||
|
using return_t = std::vector<geom::Transform>;
|
||||||
|
return _pimpl->CallAndWait<return_t>("get_actor_bone_relative_transforms", actor);
|
||||||
|
}
|
||||||
|
|
||||||
|
std::vector<std::string> Client::GetActorComponentNames(rpc::ActorId actor) {
|
||||||
|
using return_t = std::vector<std::string>;
|
||||||
|
return _pimpl->CallAndWait<return_t>("get_actor_component_names", actor);
|
||||||
|
}
|
||||||
|
|
||||||
|
std::vector<std::string> Client::GetActorBoneNames(rpc::ActorId actor) {
|
||||||
|
using return_t = std::vector<std::string>;
|
||||||
|
return _pimpl->CallAndWait<return_t>("get_actor_bone_names", actor);
|
||||||
|
}
|
||||||
|
|
||||||
|
std::vector<geom::Transform> Client::GetActorSocketWorldTransforms(rpc::ActorId actor) {
|
||||||
|
using return_t = std::vector<geom::Transform>;
|
||||||
|
return _pimpl->CallAndWait<return_t>("get_actor_socket_world_transforms", actor);
|
||||||
|
}
|
||||||
|
|
||||||
|
std::vector<geom::Transform> Client::GetActorSocketRelativeTransforms(rpc::ActorId actor) {
|
||||||
|
using return_t = std::vector<geom::Transform>;
|
||||||
|
return _pimpl->CallAndWait<return_t>("get_actor_socket_relative_transforms", actor);
|
||||||
|
}
|
||||||
|
|
||||||
void Client::SetActorSimulatePhysics(rpc::ActorId actor, const bool enabled) {
|
void Client::SetActorSimulatePhysics(rpc::ActorId actor, const bool enabled) {
|
||||||
_pimpl->CallAndWait<void>("set_actor_simulate_physics", actor, enabled);
|
_pimpl->CallAndWait<void>("set_actor_simulate_physics", actor, enabled);
|
||||||
}
|
}
|
||||||
|
|
|
@ -179,7 +179,8 @@ namespace detail {
|
||||||
const rpc::ActorDescription &description,
|
const rpc::ActorDescription &description,
|
||||||
const geom::Transform &transform,
|
const geom::Transform &transform,
|
||||||
rpc::ActorId parent,
|
rpc::ActorId parent,
|
||||||
rpc::AttachmentType attachment_type);
|
rpc::AttachmentType attachment_type,
|
||||||
|
const std::string& socket_name = "");
|
||||||
|
|
||||||
bool DestroyActor(rpc::ActorId actor);
|
bool DestroyActor(rpc::ActorId actor);
|
||||||
|
|
||||||
|
@ -232,6 +233,32 @@ namespace detail {
|
||||||
rpc::ActorId actor,
|
rpc::ActorId actor,
|
||||||
const geom::Vector3D &vector);
|
const geom::Vector3D &vector);
|
||||||
|
|
||||||
|
geom::Transform GetActorComponentWorldTransform(
|
||||||
|
rpc::ActorId actor,
|
||||||
|
const std::string componentName);
|
||||||
|
|
||||||
|
geom::Transform GetActorComponentRelativeTransform(
|
||||||
|
rpc::ActorId actor,
|
||||||
|
const std::string componentName);
|
||||||
|
|
||||||
|
std::vector<geom::Transform> GetActorBoneWorldTransforms(
|
||||||
|
rpc::ActorId actor);
|
||||||
|
|
||||||
|
std::vector<geom::Transform> GetActorBoneRelativeTransforms(
|
||||||
|
rpc::ActorId actor);
|
||||||
|
|
||||||
|
std::vector<std::string> GetActorComponentNames(
|
||||||
|
rpc::ActorId actor);
|
||||||
|
|
||||||
|
std::vector<std::string> GetActorBoneNames(
|
||||||
|
rpc::ActorId actor);
|
||||||
|
|
||||||
|
std::vector<geom::Transform> GetActorSocketWorldTransforms(
|
||||||
|
rpc::ActorId actor);
|
||||||
|
|
||||||
|
std::vector<geom::Transform> GetActorSocketRelativeTransforms(
|
||||||
|
rpc::ActorId actor);
|
||||||
|
|
||||||
void SetActorSimulatePhysics(
|
void SetActorSimulatePhysics(
|
||||||
rpc::ActorId actor,
|
rpc::ActorId actor,
|
||||||
bool enabled);
|
bool enabled);
|
||||||
|
|
|
@ -342,19 +342,21 @@ EpisodeProxy Simulator::GetCurrentEpisode() {
|
||||||
// -- General operations with actors -----------------------------------------
|
// -- General operations with actors -----------------------------------------
|
||||||
// ===========================================================================
|
// ===========================================================================
|
||||||
|
|
||||||
SharedPtr<Actor> Simulator::SpawnActor(
|
SharedPtr<Actor> Simulator::SpawnActor(
|
||||||
const ActorBlueprint &blueprint,
|
const ActorBlueprint &blueprint,
|
||||||
const geom::Transform &transform,
|
const geom::Transform &transform,
|
||||||
Actor *parent,
|
Actor *parent,
|
||||||
rpc::AttachmentType attachment_type,
|
rpc::AttachmentType attachment_type,
|
||||||
GarbageCollectionPolicy gc) {
|
GarbageCollectionPolicy gc,
|
||||||
|
const std::string& socket_name) {
|
||||||
rpc::Actor actor;
|
rpc::Actor actor;
|
||||||
if (parent != nullptr) {
|
if (parent != nullptr) {
|
||||||
actor = _client.SpawnActorWithParent(
|
actor = _client.SpawnActorWithParent(
|
||||||
blueprint.MakeActorDescription(),
|
blueprint.MakeActorDescription(),
|
||||||
transform,
|
transform,
|
||||||
parent->GetId(),
|
parent->GetId(),
|
||||||
attachment_type);
|
attachment_type,
|
||||||
|
socket_name);
|
||||||
} else {
|
} else {
|
||||||
actor = _client.SpawnActor(
|
actor = _client.SpawnActor(
|
||||||
blueprint.MakeActorDescription(),
|
blueprint.MakeActorDescription(),
|
||||||
|
|
|
@ -357,7 +357,8 @@ namespace detail {
|
||||||
const geom::Transform &transform,
|
const geom::Transform &transform,
|
||||||
Actor *parent = nullptr,
|
Actor *parent = nullptr,
|
||||||
rpc::AttachmentType attachment_type = rpc::AttachmentType::Rigid,
|
rpc::AttachmentType attachment_type = rpc::AttachmentType::Rigid,
|
||||||
GarbageCollectionPolicy gc = GarbageCollectionPolicy::Inherit);
|
GarbageCollectionPolicy gc = GarbageCollectionPolicy::Inherit,
|
||||||
|
const std::string& socket_name = "");
|
||||||
|
|
||||||
bool DestroyActor(Actor &actor);
|
bool DestroyActor(Actor &actor);
|
||||||
|
|
||||||
|
@ -438,6 +439,38 @@ namespace detail {
|
||||||
return GetActorSnapshot(actor).acceleration;
|
return GetActorSnapshot(actor).acceleration;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
geom::Transform GetActorComponentWorldTransform(const Actor &actor, const std::string componentName) {
|
||||||
|
return _client.GetActorComponentWorldTransform(actor.GetId(), componentName);
|
||||||
|
}
|
||||||
|
|
||||||
|
geom::Transform GetActorComponentRelativeTransform(const Actor &actor, std::string componentName) {
|
||||||
|
return _client.GetActorComponentRelativeTransform(actor.GetId(), componentName);
|
||||||
|
}
|
||||||
|
|
||||||
|
std::vector<geom::Transform> GetActorBoneWorldTransforms(const Actor &actor) {
|
||||||
|
return _client.GetActorBoneWorldTransforms(actor.GetId());
|
||||||
|
}
|
||||||
|
|
||||||
|
std::vector<geom::Transform> GetActorBoneRelativeTransforms(const Actor &actor) {
|
||||||
|
return _client.GetActorBoneRelativeTransforms(actor.GetId());
|
||||||
|
}
|
||||||
|
|
||||||
|
std::vector<std::string> GetActorComponentNames(const Actor &actor) {
|
||||||
|
return _client.GetActorComponentNames(actor.GetId());
|
||||||
|
}
|
||||||
|
|
||||||
|
std::vector<std::string> GetActorBoneNames(const Actor &actor) {
|
||||||
|
return _client.GetActorBoneNames(actor.GetId());
|
||||||
|
}
|
||||||
|
|
||||||
|
std::vector<geom::Transform> GetActorSocketWorldTransforms(const Actor &actor) {
|
||||||
|
return _client.GetActorSocketWorldTransforms(actor.GetId());
|
||||||
|
}
|
||||||
|
|
||||||
|
std::vector<geom::Transform> GetActorSocketRelativeTransforms(const Actor &actor) {
|
||||||
|
return _client.GetActorSocketRelativeTransforms(actor.GetId());
|
||||||
|
}
|
||||||
|
|
||||||
void SetActorLocation(Actor &actor, const geom::Location &location) {
|
void SetActorLocation(Actor &actor, const geom::Location &location) {
|
||||||
_client.SetActorLocation(actor.GetId(), location);
|
_client.SetActorLocation(actor.GetId(), location);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1232,12 +1232,17 @@ namespace road {
|
||||||
while(s_current < s_end){
|
while(s_current < s_end){
|
||||||
if(lane->GetWidth(s_current) != 0.0f){
|
if(lane->GetWidth(s_current) != 0.0f){
|
||||||
const auto edges = lane->GetCornerPositions(s_current, 0);
|
const auto edges = lane->GetCornerPositions(s_current, 0);
|
||||||
|
if (edges.first == edges.second) continue;
|
||||||
geom::Vector3D director = edges.second - edges.first;
|
geom::Vector3D director = edges.second - edges.first;
|
||||||
geom::Vector3D treeposition = edges.first - director.MakeUnitVector() * distancefromdrivinglineborder;
|
geom::Vector3D treeposition = edges.first - director.MakeUnitVector() * distancefromdrivinglineborder;
|
||||||
geom::Transform lanetransform = lane->ComputeTransform(s_current);
|
geom::Transform lanetransform = lane->ComputeTransform(s_current);
|
||||||
geom::Transform treeTransform(treeposition, lanetransform.rotation);
|
geom::Transform treeTransform(treeposition, lanetransform.rotation);
|
||||||
const carla::road::element::RoadInfoSpeed* roadinfo = lane->GetInfo<carla::road::element::RoadInfoSpeed>(s_current);
|
const carla::road::element::RoadInfoSpeed* roadinfo = lane->GetInfo<carla::road::element::RoadInfoSpeed>(s_current);
|
||||||
transforms.push_back(std::make_pair(treeTransform,roadinfo->GetType()));
|
if(roadinfo){
|
||||||
|
transforms.push_back(std::make_pair(treeTransform, roadinfo->GetType()));
|
||||||
|
}else{
|
||||||
|
transforms.push_back(std::make_pair(treeTransform, "urban"));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
s_current += distancebetweentrees;
|
s_current += distancebetweentrees;
|
||||||
}
|
}
|
||||||
|
|
|
@ -761,14 +761,11 @@ std::map<road::Lane::LaneType , std::vector<std::unique_ptr<Mesh>>> MeshFactory:
|
||||||
case carla::road::element::LaneMarking::Type::Solid: {
|
case carla::road::element::LaneMarking::Type::Solid: {
|
||||||
size_t currentIndex = out_mesh.GetVertices().size() + 1;
|
size_t currentIndex = out_mesh.GetVertices().size() + 1;
|
||||||
|
|
||||||
std::pair<geom::Vector3D, geom::Vector3D> edges = lane.GetCornerPositions(s_current, 0);
|
std::pair<geom::Vector3D, geom::Vector3D> edges =
|
||||||
|
ComputeEdgesForLanemark(lane_section, lane, s_current, lane_mark_info.width);
|
||||||
geom::Vector3D director = edges.second - edges.first;
|
|
||||||
director /= director.Length();
|
|
||||||
geom::Vector3D endmarking = edges.first + director * lane_mark_info.width;
|
|
||||||
|
|
||||||
out_mesh.AddVertex(edges.first);
|
out_mesh.AddVertex(edges.first);
|
||||||
out_mesh.AddVertex(endmarking);
|
out_mesh.AddVertex(edges.second);
|
||||||
|
|
||||||
out_mesh.AddIndex(currentIndex);
|
out_mesh.AddIndex(currentIndex);
|
||||||
out_mesh.AddIndex(currentIndex + 1);
|
out_mesh.AddIndex(currentIndex + 1);
|
||||||
|
@ -784,30 +781,23 @@ std::map<road::Lane::LaneType , std::vector<std::unique_ptr<Mesh>>> MeshFactory:
|
||||||
case carla::road::element::LaneMarking::Type::Broken: {
|
case carla::road::element::LaneMarking::Type::Broken: {
|
||||||
size_t currentIndex = out_mesh.GetVertices().size() + 1;
|
size_t currentIndex = out_mesh.GetVertices().size() + 1;
|
||||||
|
|
||||||
std::pair<geom::Vector3D, geom::Vector3D> edges =
|
std::pair<geom::Vector3D, geom::Vector3D> edges =
|
||||||
lane.GetCornerPositions(s_current, road_param.extra_lane_width);
|
ComputeEdgesForLanemark(lane_section, lane, s_current, lane_mark_info.width);
|
||||||
|
|
||||||
geom::Vector3D director = edges.second - edges.first;
|
|
||||||
director /= director.Length();
|
|
||||||
geom::Vector3D endmarking = edges.first + director * lane_mark_info.width;
|
|
||||||
|
|
||||||
out_mesh.AddVertex(edges.first);
|
out_mesh.AddVertex(edges.first);
|
||||||
out_mesh.AddVertex(endmarking);
|
out_mesh.AddVertex(edges.second);
|
||||||
|
|
||||||
s_current += road_param.resolution * 3;
|
s_current += road_param.resolution * 3;
|
||||||
if (s_current > s_end)
|
if (s_current > s_end)
|
||||||
{
|
{
|
||||||
s_current = s_end;
|
s_current = s_end;
|
||||||
}
|
}
|
||||||
edges = lane.GetCornerPositions(s_current, road_param.extra_lane_width);
|
|
||||||
|
|
||||||
director = edges.second - edges.first;
|
edges = ComputeEdgesForLanemark(lane_section, lane, s_current, lane_mark_info.width);
|
||||||
director /= director.Length();
|
|
||||||
endmarking = edges.first + director * lane_mark_info.width;
|
|
||||||
|
|
||||||
out_mesh.AddVertex(edges.first);
|
out_mesh.AddVertex(edges.first);
|
||||||
out_mesh.AddVertex(endmarking);
|
out_mesh.AddVertex(edges.second);
|
||||||
|
|
||||||
out_mesh.AddIndex(currentIndex);
|
out_mesh.AddIndex(currentIndex);
|
||||||
out_mesh.AddIndex(currentIndex + 1);
|
out_mesh.AddIndex(currentIndex + 1);
|
||||||
out_mesh.AddIndex(currentIndex + 2);
|
out_mesh.AddIndex(currentIndex + 2);
|
||||||
|
@ -864,13 +854,12 @@ std::map<road::Lane::LaneType , std::vector<std::unique_ptr<Mesh>>> MeshFactory:
|
||||||
const carla::road::element::RoadInfoMarkRecord* road_info_mark = lane.GetInfo<carla::road::element::RoadInfoMarkRecord>(s_current);
|
const carla::road::element::RoadInfoMarkRecord* road_info_mark = lane.GetInfo<carla::road::element::RoadInfoMarkRecord>(s_current);
|
||||||
if (road_info_mark != nullptr) {
|
if (road_info_mark != nullptr) {
|
||||||
carla::road::element::LaneMarking lane_mark_info(*road_info_mark);
|
carla::road::element::LaneMarking lane_mark_info(*road_info_mark);
|
||||||
std::pair<geom::Vector3D, geom::Vector3D> edges = lane.GetCornerPositions(s_end, 0);
|
|
||||||
geom::Vector3D director = edges.second - edges.first;
|
std::pair<geom::Vector3D, geom::Vector3D> edges =
|
||||||
director /= director.Length();
|
ComputeEdgesForLanemark(lane_section, lane, s_end, lane_mark_info.width);
|
||||||
geom::Vector3D endmarking = edges.first + director * lane_mark_info.width;
|
|
||||||
|
|
||||||
out_mesh.AddVertex(edges.first);
|
out_mesh.AddVertex(edges.first);
|
||||||
out_mesh.AddVertex(endmarking);
|
out_mesh.AddVertex(edges.second);
|
||||||
}
|
}
|
||||||
inout.push_back(std::make_unique<Mesh>(out_mesh));
|
inout.push_back(std::make_unique<Mesh>(out_mesh));
|
||||||
}
|
}
|
||||||
|
@ -927,29 +916,21 @@ std::map<road::Lane::LaneType , std::vector<std::unique_ptr<Mesh>>> MeshFactory:
|
||||||
case carla::road::element::LaneMarking::Type::Broken: {
|
case carla::road::element::LaneMarking::Type::Broken: {
|
||||||
size_t currentIndex = out_mesh.GetVertices().size() + 1;
|
size_t currentIndex = out_mesh.GetVertices().size() + 1;
|
||||||
|
|
||||||
std::pair<geom::Vector3D, geom::Vector3D> edges =
|
std::pair<geom::Vector3D, geom::Vector3D> edges =
|
||||||
lane.GetCornerPositions(s_current, road_param.extra_lane_width);
|
ComputeEdgesForLanemark(lane_section, lane, s_current, lane_mark_info.width);
|
||||||
|
|
||||||
geom::Vector3D director = edges.second - edges.first;
|
|
||||||
director /= director.Length();
|
|
||||||
geom::Vector3D endmarking = edges.first + director * lane_mark_info.width;
|
|
||||||
|
|
||||||
out_mesh.AddVertex(edges.first);
|
out_mesh.AddVertex(edges.first);
|
||||||
out_mesh.AddVertex(endmarking);
|
out_mesh.AddVertex(edges.second);
|
||||||
|
|
||||||
s_current += road_param.resolution * 3;
|
s_current += road_param.resolution * 3;
|
||||||
if (s_current > s_end) {
|
if (s_current > s_end) {
|
||||||
s_current = s_end;
|
s_current = s_end;
|
||||||
}
|
}
|
||||||
|
|
||||||
edges = lane.GetCornerPositions(s_current, road_param.extra_lane_width);
|
edges = ComputeEdgesForLanemark(lane_section, lane, s_current, lane_mark_info.width);
|
||||||
|
|
||||||
director = edges.second - edges.first;
|
|
||||||
director /= director.Length();
|
|
||||||
endmarking = edges.first + director * lane_mark_info.width;
|
|
||||||
|
|
||||||
out_mesh.AddVertex(edges.first);
|
out_mesh.AddVertex(edges.first);
|
||||||
out_mesh.AddVertex(endmarking);
|
out_mesh.AddVertex(edges.second);
|
||||||
|
|
||||||
out_mesh.AddIndex(currentIndex);
|
out_mesh.AddIndex(currentIndex);
|
||||||
out_mesh.AddIndex(currentIndex + 1);
|
out_mesh.AddIndex(currentIndex + 1);
|
||||||
|
@ -1150,6 +1131,33 @@ std::map<road::Lane::LaneType , std::vector<std::unique_ptr<Mesh>>> MeshFactory:
|
||||||
return std::make_unique<Mesh>(out_mesh);
|
return std::make_unique<Mesh>(out_mesh);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
std::pair<geom::Vector3D, geom::Vector3D> MeshFactory::ComputeEdgesForLanemark(
|
||||||
|
const road::LaneSection& lane_section,
|
||||||
|
const road::Lane& lane,
|
||||||
|
const double s_current,
|
||||||
|
const double lanemark_width) const {
|
||||||
|
std::pair<geom::Vector3D, geom::Vector3D> edges =
|
||||||
|
lane.GetCornerPositions(s_current, road_param.extra_lane_width);
|
||||||
|
|
||||||
|
geom::Vector3D director;
|
||||||
|
if (edges.first != edges.second) {
|
||||||
|
director = edges.second - edges.first;
|
||||||
|
director /= director.Length();
|
||||||
|
} else {
|
||||||
|
const std::map<road::LaneId, road::Lane> & lanes = lane_section.GetLanes();
|
||||||
|
for (const auto& lane_pair : lanes) {
|
||||||
|
std::pair<geom::Vector3D, geom::Vector3D> another_edge =
|
||||||
|
lane_pair.second.GetCornerPositions(s_current, road_param.extra_lane_width);
|
||||||
|
if (another_edge.first != another_edge.second) {
|
||||||
|
director = another_edge.second - another_edge.first;
|
||||||
|
director /= director.Length();
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
geom::Vector3D endmarking = edges.first + director * lanemark_width;
|
||||||
|
return std::make_pair(edges.first, endmarking);
|
||||||
|
}
|
||||||
|
|
||||||
} // namespace geom
|
} // namespace geom
|
||||||
} // namespace carla
|
} // namespace carla
|
||||||
|
|
|
@ -148,6 +148,15 @@ namespace geom {
|
||||||
|
|
||||||
RoadParameters road_param;
|
RoadParameters road_param;
|
||||||
|
|
||||||
|
private:
|
||||||
|
|
||||||
|
// Calculate the points on both sides of the lane mark for the specified s_current
|
||||||
|
std::pair<geom::Vector3D, geom::Vector3D> ComputeEdgesForLanemark(
|
||||||
|
const road::LaneSection& lane_section,
|
||||||
|
const road::Lane& lane,
|
||||||
|
const double s_current,
|
||||||
|
const double lanemark_width) const;
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace geom
|
} // namespace geom
|
||||||
|
|
|
@ -10,6 +10,7 @@
|
||||||
#include "carla/MsgPackAdaptors.h"
|
#include "carla/MsgPackAdaptors.h"
|
||||||
#include "carla/geom/Transform.h"
|
#include "carla/geom/Transform.h"
|
||||||
#include "carla/rpc/ActorDescription.h"
|
#include "carla/rpc/ActorDescription.h"
|
||||||
|
#include "carla/rpc/AttachmentType.h"
|
||||||
#include "carla/rpc/ActorId.h"
|
#include "carla/rpc/ActorId.h"
|
||||||
#include "carla/rpc/TrafficLightState.h"
|
#include "carla/rpc/TrafficLightState.h"
|
||||||
#include "carla/rpc/VehicleAckermannControl.h"
|
#include "carla/rpc/VehicleAckermannControl.h"
|
||||||
|
@ -18,6 +19,8 @@
|
||||||
#include "carla/rpc/VehicleLightState.h"
|
#include "carla/rpc/VehicleLightState.h"
|
||||||
#include "carla/rpc/WalkerControl.h"
|
#include "carla/rpc/WalkerControl.h"
|
||||||
|
|
||||||
|
#include <string>
|
||||||
|
|
||||||
#ifdef _MSC_VER
|
#ifdef _MSC_VER
|
||||||
#pragma warning(push)
|
#pragma warning(push)
|
||||||
#pragma warning(disable:4583)
|
#pragma warning(disable:4583)
|
||||||
|
@ -59,11 +62,19 @@ namespace rpc {
|
||||||
: description(std::move(description)),
|
: description(std::move(description)),
|
||||||
transform(transform),
|
transform(transform),
|
||||||
parent(parent) {}
|
parent(parent) {}
|
||||||
|
SpawnActor(ActorDescription description, const geom::Transform &transform, ActorId parent, AttachmentType attachment_type, const std::string& bone)
|
||||||
|
: description(std::move(description)),
|
||||||
|
transform(transform),
|
||||||
|
parent(parent),
|
||||||
|
attachment_type(attachment_type),
|
||||||
|
socket_name(bone) {}
|
||||||
ActorDescription description;
|
ActorDescription description;
|
||||||
geom::Transform transform;
|
geom::Transform transform;
|
||||||
boost::optional<ActorId> parent;
|
boost::optional<ActorId> parent;
|
||||||
|
AttachmentType attachment_type;
|
||||||
|
std::string socket_name;
|
||||||
std::vector<Command> do_after;
|
std::vector<Command> do_after;
|
||||||
MSGPACK_DEFINE_ARRAY(description, transform, parent, do_after);
|
MSGPACK_DEFINE_ARRAY(description, transform, parent, attachment_type, socket_name, do_after);
|
||||||
};
|
};
|
||||||
|
|
||||||
struct DestroyActor : CommandBase<DestroyActor> {
|
struct DestroyActor : CommandBase<DestroyActor> {
|
||||||
|
|
|
@ -345,12 +345,14 @@ class BasicAgent(object):
|
||||||
return None
|
return None
|
||||||
|
|
||||||
return Polygon(route_bb)
|
return Polygon(route_bb)
|
||||||
|
|
||||||
if self._ignore_vehicles:
|
if self._ignore_vehicles:
|
||||||
return (False, None, -1)
|
return (False, None, -1)
|
||||||
|
|
||||||
if not vehicle_list:
|
if vehicle_list is None:
|
||||||
vehicle_list = self._world.get_actors().filter("*vehicle*")
|
vehicle_list = self._world.get_actors().filter("*vehicle*")
|
||||||
|
if len(vehicle_list) == 0:
|
||||||
|
return (False, None, -1)
|
||||||
|
|
||||||
if not max_distance:
|
if not max_distance:
|
||||||
max_distance = self._base_vehicle_threshold
|
max_distance = self._base_vehicle_threshold
|
||||||
|
|
|
@ -113,6 +113,14 @@ void export_actor() {
|
||||||
.def("get_velocity", &cc::Actor::GetVelocity)
|
.def("get_velocity", &cc::Actor::GetVelocity)
|
||||||
.def("get_angular_velocity", &cc::Actor::GetAngularVelocity)
|
.def("get_angular_velocity", &cc::Actor::GetAngularVelocity)
|
||||||
.def("get_acceleration", &cc::Actor::GetAcceleration)
|
.def("get_acceleration", &cc::Actor::GetAcceleration)
|
||||||
|
.def("get_component_world_transform", &cc::Actor::GetComponentWorldTransform, (arg("component_name")))
|
||||||
|
.def("get_component_relative_transform", &cc::Actor::GetComponentRelativeTransform, (arg("component_name")))
|
||||||
|
.def("get_bone_world_transforms", CALL_RETURNING_LIST(cc::Actor,GetBoneWorldTransforms))
|
||||||
|
.def("get_bone_relative_transforms", CALL_RETURNING_LIST(cc::Actor,GetBoneRelativeTransforms))
|
||||||
|
.def("get_component_names", CALL_RETURNING_LIST(cc::Actor,GetComponentNames))
|
||||||
|
.def("get_bone_names", CALL_RETURNING_LIST(cc::Actor,GetBoneNames))
|
||||||
|
.def("get_socket_world_transforms", CALL_RETURNING_LIST(cc::Actor,GetSocketWorldTransforms))
|
||||||
|
.def("get_socket_relative_transforms", CALL_RETURNING_LIST(cc::Actor,GetSocketRelativeTransforms))
|
||||||
.def("set_location", &cc::Actor::SetLocation, (arg("location")))
|
.def("set_location", &cc::Actor::SetLocation, (arg("location")))
|
||||||
.def("set_transform", &cc::Actor::SetTransform, (arg("transform")))
|
.def("set_transform", &cc::Actor::SetTransform, (arg("transform")))
|
||||||
.def("set_target_velocity", &cc::Actor::SetTargetVelocity, (arg("velocity")))
|
.def("set_target_velocity", &cc::Actor::SetTargetVelocity, (arg("velocity")))
|
||||||
|
|
|
@ -82,9 +82,15 @@ void export_commands() {
|
||||||
"__init__",
|
"__init__",
|
||||||
&command_impl::CustomSpawnActorInit<cc::ActorBlueprint, cg::Transform, ActorPtr>,
|
&command_impl::CustomSpawnActorInit<cc::ActorBlueprint, cg::Transform, ActorPtr>,
|
||||||
(arg("blueprint"), arg("transform"), arg("parent")))
|
(arg("blueprint"), arg("transform"), arg("parent")))
|
||||||
|
.def(
|
||||||
|
"__init__",
|
||||||
|
&command_impl::CustomSpawnActorInit<cc::ActorBlueprint, cg::Transform, ActorPtr, cr::AttachmentType, std::string>,
|
||||||
|
(arg("blueprint"), arg("transform"), arg("parent"), arg("attachment_type"), arg("socket_name")))
|
||||||
.def(init<cr::Command::SpawnActor>())
|
.def(init<cr::Command::SpawnActor>())
|
||||||
.def_readwrite("transform", &cr::Command::SpawnActor::transform)
|
.def_readwrite("transform", &cr::Command::SpawnActor::transform)
|
||||||
.def_readwrite("parent_id", &cr::Command::SpawnActor::parent)
|
.def_readwrite("parent_id", &cr::Command::SpawnActor::parent)
|
||||||
|
.def_readwrite("attachment_type", &cr::Command::SpawnActor::attachment_type)
|
||||||
|
.def_readwrite("socket_name", &cr::Command::SpawnActor::socket_name)
|
||||||
.def("then", &command_impl::Then, (arg("command")))
|
.def("then", &command_impl::Then, (arg("command")))
|
||||||
;
|
;
|
||||||
|
|
||||||
|
|
|
@ -11,6 +11,8 @@
|
||||||
#include <carla/rpc/EnvironmentObject.h>
|
#include <carla/rpc/EnvironmentObject.h>
|
||||||
#include <carla/rpc/ObjectLabel.h>
|
#include <carla/rpc/ObjectLabel.h>
|
||||||
|
|
||||||
|
#include <string>
|
||||||
|
|
||||||
#include <boost/python/suite/indexing/vector_indexing_suite.hpp>
|
#include <boost/python/suite/indexing/vector_indexing_suite.hpp>
|
||||||
|
|
||||||
namespace carla {
|
namespace carla {
|
||||||
|
@ -293,15 +295,17 @@ void export_world() {
|
||||||
const cc::ActorBlueprint &blueprint, \
|
const cc::ActorBlueprint &blueprint, \
|
||||||
const cg::Transform &transform, \
|
const cg::Transform &transform, \
|
||||||
cc::Actor *parent, \
|
cc::Actor *parent, \
|
||||||
cr::AttachmentType attachment_type) { \
|
cr::AttachmentType attachment_type, \
|
||||||
|
const std::string& bone) { \
|
||||||
carla::PythonUtil::ReleaseGIL unlock; \
|
carla::PythonUtil::ReleaseGIL unlock; \
|
||||||
return self.fn(blueprint, transform, parent, attachment_type); \
|
return self.fn(blueprint, transform, parent, attachment_type, bone); \
|
||||||
}, \
|
}, \
|
||||||
( \
|
( \
|
||||||
arg("blueprint"), \
|
arg("blueprint"), \
|
||||||
arg("transform"), \
|
arg("transform"), \
|
||||||
arg("attach_to")=carla::SharedPtr<cc::Actor>(), \
|
arg("attach_to")=carla::SharedPtr<cc::Actor>(), \
|
||||||
arg("attachment_type")=cr::AttachmentType::Rigid)
|
arg("attachment_type")=cr::AttachmentType::Rigid, \
|
||||||
|
arg("bone")=std::string())
|
||||||
|
|
||||||
class_<cc::World>("World", no_init)
|
class_<cc::World>("World", no_init)
|
||||||
.add_property("id", &cc::World::GetId)
|
.add_property("id", &cc::World::GetId)
|
||||||
|
|
|
@ -0,0 +1,34 @@
|
||||||
|
import glob
|
||||||
|
import os
|
||||||
|
import sys
|
||||||
|
|
||||||
|
try:
|
||||||
|
sys.path.append(glob.glob('../carla/dist/carla-*%d.%d-%s.egg' % (
|
||||||
|
sys.version_info.major,
|
||||||
|
sys.version_info.minor,
|
||||||
|
'win-amd64' if os.name == 'nt' else 'linux-x86_64'))[0])
|
||||||
|
except IndexError:
|
||||||
|
pass
|
||||||
|
|
||||||
|
|
||||||
|
# ==============================================================================
|
||||||
|
# -- imports -------------------------------------------------------------------
|
||||||
|
# ==============================================================================
|
||||||
|
|
||||||
|
|
||||||
|
import carla
|
||||||
|
|
||||||
|
client = carla.Client('localhost', 2000)
|
||||||
|
world = client.get_world()
|
||||||
|
|
||||||
|
location = carla.Location(200.0, 200.0, 200.0)
|
||||||
|
rotation = carla.Rotation(0.0, 0.0, 0.0)
|
||||||
|
transform = carla.Transform(location, rotation)
|
||||||
|
|
||||||
|
bp_library = world.get_blueprint_library()
|
||||||
|
bp_audi = bp_library.find('vehicle.audi.tt')
|
||||||
|
audi = world.spawn_actor(bp_audi, transform)
|
||||||
|
|
||||||
|
component_transform = audi.get_component_world_transform('front-blinker-r-1')
|
||||||
|
print(component_transform)
|
||||||
|
|
12
README.md
12
README.md
|
@ -19,17 +19,17 @@ environmental conditions.
|
||||||
### Download CARLA
|
### Download CARLA
|
||||||
|
|
||||||
Linux:
|
Linux:
|
||||||
* [**Get CARLA overnight build**](http://carla-releases.s3.amazonaws.com/Linux/Dev/CARLA_Latest.tar.gz)
|
* [**Get CARLA overnight build**](https://carla-releases.s3.us-east-005.backblazeb2.com/Linux/Dev/CARLA_Latest.tar.gz)
|
||||||
* [**Get AdditionalMaps overnight build**](http://carla-releases.s3.amazonaws.com/Linux/Dev/AdditionalMaps_Latest.tar.gz)
|
* [**Get AdditionalMaps overnight build**](https://carla-releases.s3.us-east-005.backblazeb2.com/Linux/Dev/AdditionalMaps_Latest.tar.gz)
|
||||||
|
|
||||||
Windows:
|
Windows:
|
||||||
* [**Get CARLA overnight build**](http://carla-releases.s3.amazonaws.com/Windows/Dev/CARLA_Latest.zip)
|
* [**Get CARLA overnight build**](https://carla-releases.s3.us-east-005.backblazeb2.com/Windows/Dev/CARLA_Latest.zip)
|
||||||
* [**Get AdditionalMaps overnight build**](http://carla-releases.s3.amazonaws.com/Windows/Dev/AdditionalMaps_Latest.zip)
|
* [**Get AdditionalMaps overnight build**](https://carla-releases.s3.us-east-005.backblazeb2.com/Windows/Dev/AdditionalMaps_Latest.zip)
|
||||||
|
|
||||||
### Recommended system
|
### Recommended system
|
||||||
|
|
||||||
* Intel i7 gen 9th - 11th / Intel i9 gen 9th - 11th / AMD ryzen 7 / AMD ryzen 9
|
* Intel i7 gen 9th - 11th / Intel i9 gen 9th - 11th / AMD ryzen 7 / AMD ryzen 9
|
||||||
* +32 GB RAM memory
|
* +32 GB RAM memory
|
||||||
* NVIDIA RTX 3070 / NVIDIA RTX 3080 / NVIDIA RTX 4090
|
* NVIDIA RTX 3070 / NVIDIA RTX 3080 / NVIDIA RTX 4090
|
||||||
* Ubuntu 20.04
|
* Ubuntu 20.04
|
||||||
|
|
||||||
|
@ -54,7 +54,7 @@ Repositories associated with the CARLA simulation platform:
|
||||||
* [**Conditional Imitation-Learning**](https://github.com/felipecode/coiltraine): Training and testing Conditional Imitation Learning models in CARLA
|
* [**Conditional Imitation-Learning**](https://github.com/felipecode/coiltraine): Training and testing Conditional Imitation Learning models in CARLA
|
||||||
* [**AutoWare AV stack**](https://github.com/carla-simulator/carla-autoware): Bridge to connect AutoWare AV stack to CARLA
|
* [**AutoWare AV stack**](https://github.com/carla-simulator/carla-autoware): Bridge to connect AutoWare AV stack to CARLA
|
||||||
* [**Reinforcement-Learning**](https://github.com/carla-simulator/reinforcement-learning): Code for running Conditional Reinforcement Learning models in CARLA
|
* [**Reinforcement-Learning**](https://github.com/carla-simulator/reinforcement-learning): Code for running Conditional Reinforcement Learning models in CARLA
|
||||||
* [**RoadRunner**](https://www.mathworks.com/products/roadrunner.html): MATLAB GUI based application to create road networks in OpenDrive format
|
* [**RoadRunner**](https://www.mathworks.com/products/roadrunner.html): MATLAB GUI based application to create road networks in OpenDrive format
|
||||||
* [**Map Editor**](https://github.com/carla-simulator/carla-map-editor): Standalone GUI application to enhance RoadRunner maps with traffic lights and traffic signs information
|
* [**Map Editor**](https://github.com/carla-simulator/carla-map-editor): Standalone GUI application to enhance RoadRunner maps with traffic lights and traffic signs information
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -105,7 +105,7 @@ bool UCarlaEpisode::LoadNewEpisode(const FString &MapString, bool ResetSettings)
|
||||||
UGameplayStatics::OpenLevel(GetWorld(), *FinalPath, true);
|
UGameplayStatics::OpenLevel(GetWorld(), *FinalPath, true);
|
||||||
if (ResetSettings)
|
if (ResetSettings)
|
||||||
ApplySettings(FEpisodeSettings{});
|
ApplySettings(FEpisodeSettings{});
|
||||||
|
|
||||||
// send 'LOAD_MAP' command to all secondary servers (if any)
|
// send 'LOAD_MAP' command to all secondary servers (if any)
|
||||||
if (bIsPrimaryServer)
|
if (bIsPrimaryServer)
|
||||||
{
|
{
|
||||||
|
@ -114,7 +114,7 @@ bool UCarlaEpisode::LoadNewEpisode(const FString &MapString, bool ResetSettings)
|
||||||
{
|
{
|
||||||
FCarlaEngine *CarlaEngine = GameInstance->GetCarlaEngine();
|
FCarlaEngine *CarlaEngine = GameInstance->GetCarlaEngine();
|
||||||
auto SecondaryServer = CarlaEngine->GetSecondaryServer();
|
auto SecondaryServer = CarlaEngine->GetSecondaryServer();
|
||||||
if (SecondaryServer->HasClientsConnected())
|
if (SecondaryServer->HasClientsConnected())
|
||||||
{
|
{
|
||||||
SecondaryServer->GetCommander().SendLoadMap(std::string(TCHAR_TO_UTF8(*FinalPath)));
|
SecondaryServer->GetCommander().SendLoadMap(std::string(TCHAR_TO_UTF8(*FinalPath)));
|
||||||
}
|
}
|
||||||
|
@ -294,11 +294,12 @@ carla::rpc::Actor UCarlaEpisode::SerializeActor(AActor* Actor) const
|
||||||
void UCarlaEpisode::AttachActors(
|
void UCarlaEpisode::AttachActors(
|
||||||
AActor *Child,
|
AActor *Child,
|
||||||
AActor *Parent,
|
AActor *Parent,
|
||||||
EAttachmentType InAttachmentType)
|
EAttachmentType InAttachmentType,
|
||||||
|
const FString& SocketName)
|
||||||
{
|
{
|
||||||
Child->AddActorWorldOffset(FVector(CurrentMapOrigin));
|
Child->AddActorWorldOffset(FVector(CurrentMapOrigin));
|
||||||
|
|
||||||
UActorAttacher::AttachActors(Child, Parent, InAttachmentType);
|
UActorAttacher::AttachActors(Child, Parent, InAttachmentType, SocketName);
|
||||||
|
|
||||||
if (bIsPrimaryServer)
|
if (bIsPrimaryServer)
|
||||||
{
|
{
|
||||||
|
|
|
@ -245,7 +245,8 @@ public:
|
||||||
void AttachActors(
|
void AttachActors(
|
||||||
AActor *Child,
|
AActor *Child,
|
||||||
AActor *Parent,
|
AActor *Parent,
|
||||||
EAttachmentType InAttachmentType = EAttachmentType::Rigid);
|
EAttachmentType InAttachmentType = EAttachmentType::Rigid,
|
||||||
|
const FString& SocketName = "");
|
||||||
|
|
||||||
/// @copydoc FActorDispatcher::DestroyActor(AActor*)
|
/// @copydoc FActorDispatcher::DestroyActor(AActor*)
|
||||||
UFUNCTION(BlueprintCallable)
|
UFUNCTION(BlueprintCallable)
|
||||||
|
|
|
@ -9,6 +9,11 @@
|
||||||
#include "Carla/Server/CarlaServerResponse.h"
|
#include "Carla/Server/CarlaServerResponse.h"
|
||||||
#include "Carla/Traffic/TrafficLightGroup.h"
|
#include "Carla/Traffic/TrafficLightGroup.h"
|
||||||
#include "EngineUtils.h"
|
#include "EngineUtils.h"
|
||||||
|
#include "Components/SkeletalMeshComponent.h"
|
||||||
|
#include "Components/SkinnedMeshComponent.h"
|
||||||
|
#include "Components/SceneComponent.h"
|
||||||
|
#include "Engine/SkeletalMesh.h"
|
||||||
|
#include "Engine/SkeletalMeshSocket.h"
|
||||||
|
|
||||||
#include "Carla/OpenDrive/OpenDrive.h"
|
#include "Carla/OpenDrive/OpenDrive.h"
|
||||||
#include "Carla/Util/DebugShapeDrawer.h"
|
#include "Carla/Util/DebugShapeDrawer.h"
|
||||||
|
@ -706,7 +711,8 @@ void FCarlaServer::FPimpl::BindActions()
|
||||||
cr::ActorDescription Description,
|
cr::ActorDescription Description,
|
||||||
const cr::Transform &Transform,
|
const cr::Transform &Transform,
|
||||||
cr::ActorId ParentId,
|
cr::ActorId ParentId,
|
||||||
cr::AttachmentType InAttachmentType) -> R<cr::Actor>
|
cr::AttachmentType InAttachmentType,
|
||||||
|
const std::string& socket_name) -> R<cr::Actor>
|
||||||
{
|
{
|
||||||
REQUIRE_CARLA_EPISODE();
|
REQUIRE_CARLA_EPISODE();
|
||||||
|
|
||||||
|
@ -760,7 +766,8 @@ void FCarlaServer::FPimpl::BindActions()
|
||||||
Episode->AttachActors(
|
Episode->AttachActors(
|
||||||
CarlaActor->GetActor(),
|
CarlaActor->GetActor(),
|
||||||
ParentCarlaActor->GetActor(),
|
ParentCarlaActor->GetActor(),
|
||||||
static_cast<EAttachmentType>(InAttachmentType));
|
static_cast<EAttachmentType>(InAttachmentType),
|
||||||
|
FString(socket_name.c_str()));
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -1274,6 +1281,305 @@ BIND_SYNC(is_sensor_enabled_for_ros) << [this](carla::streaming::detail::stream_
|
||||||
return R<void>::Success();
|
return R<void>::Success();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
BIND_SYNC(get_actor_component_world_transform) << [this](
|
||||||
|
cr::ActorId ActorId,
|
||||||
|
const std::string componentName) -> R<cr::Transform>
|
||||||
|
{
|
||||||
|
REQUIRE_CARLA_EPISODE();
|
||||||
|
FCarlaActor* CarlaActor = Episode->FindCarlaActor(ActorId);
|
||||||
|
if (!CarlaActor)
|
||||||
|
{
|
||||||
|
return RespondError(
|
||||||
|
"get_actor_component_world_transform",
|
||||||
|
ECarlaServerResponse::ActorNotFound,
|
||||||
|
" Actor Id: " + FString::FromInt(ActorId));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
TArray<UActorComponent*> Components;
|
||||||
|
CarlaActor->GetActor()->GetComponents(Components);
|
||||||
|
|
||||||
|
USceneComponent* Component = nullptr;
|
||||||
|
for(auto Cmp : Components)
|
||||||
|
{
|
||||||
|
if(USceneComponent* SCMP = Cast<USceneComponent>(Cmp))
|
||||||
|
{
|
||||||
|
if(SCMP->GetName() == componentName.c_str())
|
||||||
|
{
|
||||||
|
Component = SCMP;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if(!Component)
|
||||||
|
{
|
||||||
|
return RespondError(
|
||||||
|
"get_actor_component_world_transform",
|
||||||
|
ECarlaServerResponse::ComponentNotFound,
|
||||||
|
" Component Name: " + FString(componentName.c_str()));
|
||||||
|
}
|
||||||
|
|
||||||
|
FTransform ComponentWorldTransform = Component->GetComponentTransform();
|
||||||
|
return cr::Transform(ComponentWorldTransform);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
BIND_SYNC(get_actor_component_relative_transform) << [this](
|
||||||
|
cr::ActorId ActorId,
|
||||||
|
const std::string componentName) -> R<cr::Transform>
|
||||||
|
{
|
||||||
|
REQUIRE_CARLA_EPISODE();
|
||||||
|
FCarlaActor* CarlaActor = Episode->FindCarlaActor(ActorId);
|
||||||
|
if (!CarlaActor)
|
||||||
|
{
|
||||||
|
return RespondError(
|
||||||
|
"get_actor_component_relative_transform",
|
||||||
|
ECarlaServerResponse::ActorNotFound,
|
||||||
|
" Actor Id: " + FString::FromInt(ActorId));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
TArray<UActorComponent*> Components;
|
||||||
|
CarlaActor->GetActor()->GetComponents(Components);
|
||||||
|
|
||||||
|
USceneComponent* Component = nullptr;
|
||||||
|
for(auto Cmp : Components)
|
||||||
|
{
|
||||||
|
if(USceneComponent* SCMP = Cast<USceneComponent>(Cmp))
|
||||||
|
{
|
||||||
|
if(SCMP->GetName() == componentName.c_str())
|
||||||
|
{
|
||||||
|
Component = SCMP;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if(!Component)
|
||||||
|
{
|
||||||
|
return RespondError(
|
||||||
|
"get_actor_component_world_transform",
|
||||||
|
ECarlaServerResponse::ComponentNotFound,
|
||||||
|
" Component Name: " + FString(componentName.c_str()));
|
||||||
|
}
|
||||||
|
|
||||||
|
FTransform ComponentRelativeTransform = Component->GetRelativeTransform();
|
||||||
|
return cr::Transform(ComponentRelativeTransform);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
BIND_SYNC(get_actor_bone_world_transforms) << [this](
|
||||||
|
cr::ActorId ActorId) -> R<std::vector<cr::Transform>>
|
||||||
|
{
|
||||||
|
REQUIRE_CARLA_EPISODE();
|
||||||
|
FCarlaActor* CarlaActor = Episode->FindCarlaActor(ActorId);
|
||||||
|
if (!CarlaActor)
|
||||||
|
{
|
||||||
|
return RespondError(
|
||||||
|
"get_actor_bone_world_transform",
|
||||||
|
ECarlaServerResponse::ActorNotFound,
|
||||||
|
" Actor Id: " + FString::FromInt(ActorId));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
TArray<FTransform> BoneWorldTransforms;
|
||||||
|
TArray<USkinnedMeshComponent*> SkinnedMeshComponents;
|
||||||
|
CarlaActor->GetActor()->GetComponents<USkinnedMeshComponent>(SkinnedMeshComponents);
|
||||||
|
if(!SkinnedMeshComponents[0])
|
||||||
|
{
|
||||||
|
return RespondError(
|
||||||
|
"get_actor_bone_relative_transforms",
|
||||||
|
ECarlaServerResponse::ComponentNotFound,
|
||||||
|
" Component Name: SkinnedMeshComponent ");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
for(USkinnedMeshComponent* SkinnedMeshComponent : SkinnedMeshComponents)
|
||||||
|
{
|
||||||
|
const int32 NumBones = SkinnedMeshComponent->GetNumBones();
|
||||||
|
for (int32 BoneIndex = 0; BoneIndex < NumBones; ++BoneIndex)
|
||||||
|
{
|
||||||
|
FTransform WorldTransform = SkinnedMeshComponent->GetComponentTransform();
|
||||||
|
FTransform BoneTransform = SkinnedMeshComponent->GetBoneTransform(BoneIndex, WorldTransform);
|
||||||
|
BoneWorldTransforms.Add(BoneTransform);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return MakeVectorFromTArray<cr::Transform>(BoneWorldTransforms);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
BIND_SYNC(get_actor_bone_relative_transforms) << [this](
|
||||||
|
cr::ActorId ActorId) -> R<std::vector<cr::Transform>>
|
||||||
|
{
|
||||||
|
REQUIRE_CARLA_EPISODE();
|
||||||
|
FCarlaActor* CarlaActor = Episode->FindCarlaActor(ActorId);
|
||||||
|
if (!CarlaActor)
|
||||||
|
{
|
||||||
|
return RespondError(
|
||||||
|
"get_actor_bone_relative_transform",
|
||||||
|
ECarlaServerResponse::ActorNotFound,
|
||||||
|
" Actor Id: " + FString::FromInt(ActorId));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
TArray<FTransform> BoneRelativeTransforms;
|
||||||
|
TArray<USkinnedMeshComponent*> SkinnedMeshComponents;
|
||||||
|
CarlaActor->GetActor()->GetComponents<USkinnedMeshComponent>(SkinnedMeshComponents);
|
||||||
|
if(!SkinnedMeshComponents[0])
|
||||||
|
{
|
||||||
|
return RespondError(
|
||||||
|
"get_actor_bone_relative_transforms",
|
||||||
|
ECarlaServerResponse::ComponentNotFound,
|
||||||
|
" Component Name: SkinnedMeshComponent ");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
for(USkinnedMeshComponent* SkinnedMeshComponent : SkinnedMeshComponents)
|
||||||
|
{
|
||||||
|
const int32 NumBones = SkinnedMeshComponent->GetNumBones();
|
||||||
|
for (int32 BoneIndex = 0; BoneIndex < NumBones; ++BoneIndex)
|
||||||
|
{
|
||||||
|
FTransform BoneTransform = SkinnedMeshComponent->GetBoneTransform(BoneIndex, FTransform::Identity);
|
||||||
|
BoneRelativeTransforms.Add(BoneTransform);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return MakeVectorFromTArray<cr::Transform>(BoneRelativeTransforms);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
BIND_SYNC(get_actor_component_names) << [this](
|
||||||
|
cr::ActorId ActorId) -> R<std::vector<std::string>>
|
||||||
|
{
|
||||||
|
REQUIRE_CARLA_EPISODE();
|
||||||
|
FCarlaActor* CarlaActor = Episode->FindCarlaActor(ActorId);
|
||||||
|
if (!CarlaActor)
|
||||||
|
{
|
||||||
|
return RespondError(
|
||||||
|
"get_actor_component_names",
|
||||||
|
ECarlaServerResponse::ActorNotFound,
|
||||||
|
" Actor Id: " + FString::FromInt(ActorId));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
TArray<UActorComponent*> Components;
|
||||||
|
CarlaActor->GetActor()->GetComponents(Components);
|
||||||
|
std::vector<std::string> ComponentNames;
|
||||||
|
for(auto Cmp : Components)
|
||||||
|
{
|
||||||
|
FString ComponentName = Cmp->GetName();
|
||||||
|
ComponentNames.push_back(TCHAR_TO_UTF8(*ComponentName));
|
||||||
|
}
|
||||||
|
return ComponentNames;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
BIND_SYNC(get_actor_bone_names) << [this](
|
||||||
|
cr::ActorId ActorId) -> R<std::vector<std::string>>
|
||||||
|
{
|
||||||
|
REQUIRE_CARLA_EPISODE();
|
||||||
|
FCarlaActor* CarlaActor = Episode->FindCarlaActor(ActorId);
|
||||||
|
if (!CarlaActor)
|
||||||
|
{
|
||||||
|
return RespondError(
|
||||||
|
"get_actor_component_relative_transform",
|
||||||
|
ECarlaServerResponse::ActorNotFound,
|
||||||
|
" Actor Id: " + FString::FromInt(ActorId));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
USkinnedMeshComponent* SkinnedMeshComponent = CarlaActor->GetActor()->FindComponentByClass<USkinnedMeshComponent>();
|
||||||
|
if(!SkinnedMeshComponent)
|
||||||
|
{
|
||||||
|
return RespondError(
|
||||||
|
"get_actor_bone_relative_transforms",
|
||||||
|
ECarlaServerResponse::ComponentNotFound,
|
||||||
|
" Component Name: SkinnedMeshComponent ");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
TArray<FName> BoneNames;
|
||||||
|
SkinnedMeshComponent->GetBoneNames(BoneNames);
|
||||||
|
TArray<std::string> StringBoneNames;
|
||||||
|
for (const FName& Name : BoneNames)
|
||||||
|
{
|
||||||
|
FString FBoneName = Name.ToString();
|
||||||
|
std::string StringBoneName = TCHAR_TO_UTF8(*FBoneName);
|
||||||
|
StringBoneNames.Add(StringBoneName);
|
||||||
|
}
|
||||||
|
return MakeVectorFromTArray<std::string>(StringBoneNames);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
BIND_SYNC(get_actor_socket_world_transforms) << [this](
|
||||||
|
cr::ActorId ActorId) -> R<std::vector<cr::Transform>>
|
||||||
|
{
|
||||||
|
REQUIRE_CARLA_EPISODE();
|
||||||
|
FCarlaActor* CarlaActor = Episode->FindCarlaActor(ActorId);
|
||||||
|
if (!CarlaActor)
|
||||||
|
{
|
||||||
|
return RespondError(
|
||||||
|
"get_actor_component_relative_transform",
|
||||||
|
ECarlaServerResponse::ActorNotFound,
|
||||||
|
" Actor Id: " + FString::FromInt(ActorId));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
TArray<FTransform> SocketWorldTransforms;
|
||||||
|
TArray<UActorComponent*> Components;
|
||||||
|
CarlaActor->GetActor()->GetComponents(Components);
|
||||||
|
for(UActorComponent* ActorComponent : Components)
|
||||||
|
{
|
||||||
|
if(USceneComponent* SceneComponent = Cast<USceneComponent>(ActorComponent))
|
||||||
|
{
|
||||||
|
const TArray<FName>& SocketNames = SceneComponent->GetAllSocketNames();
|
||||||
|
for (const FName& SocketName : SocketNames)
|
||||||
|
{
|
||||||
|
FTransform SocketTransform = SceneComponent->GetSocketTransform(SocketName);
|
||||||
|
SocketWorldTransforms.Add(SocketTransform);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return MakeVectorFromTArray<cr::Transform>(SocketWorldTransforms);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
BIND_SYNC(get_actor_socket_relative_transforms) << [this](
|
||||||
|
cr::ActorId ActorId) -> R<std::vector<cr::Transform>>
|
||||||
|
{
|
||||||
|
REQUIRE_CARLA_EPISODE();
|
||||||
|
FCarlaActor* CarlaActor = Episode->FindCarlaActor(ActorId);
|
||||||
|
if (!CarlaActor)
|
||||||
|
{
|
||||||
|
return RespondError(
|
||||||
|
"get_actor_component_relative_transform",
|
||||||
|
ECarlaServerResponse::ActorNotFound,
|
||||||
|
" Actor Id: " + FString::FromInt(ActorId));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
TArray<FTransform> SocketRelativeTransforms;
|
||||||
|
TArray<UActorComponent*> Components;
|
||||||
|
CarlaActor->GetActor()->GetComponents(Components);
|
||||||
|
for(UActorComponent* ActorComponent : Components)
|
||||||
|
{
|
||||||
|
if(USceneComponent* SceneComponent = Cast<USceneComponent>(ActorComponent))
|
||||||
|
{
|
||||||
|
const TArray<FName>& SocketNames = SceneComponent->GetAllSocketNames();
|
||||||
|
for (const FName& SocketName : SocketNames)
|
||||||
|
{
|
||||||
|
FTransform SocketTransform = SceneComponent->GetSocketTransform(SocketName, ERelativeTransformSpace::RTS_Actor);
|
||||||
|
SocketRelativeTransforms.Add(SocketTransform);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return MakeVectorFromTArray<cr::Transform>(SocketRelativeTransforms);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
BIND_SYNC(get_physics_control) << [this](
|
BIND_SYNC(get_physics_control) << [this](
|
||||||
cr::ActorId ActorId) -> R<cr::VehiclePhysicsControl>
|
cr::ActorId ActorId) -> R<cr::VehiclePhysicsControl>
|
||||||
{
|
{
|
||||||
|
@ -2457,7 +2763,8 @@ BIND_SYNC(is_sensor_enabled_for_ros) << [this](carla::streaming::detail::stream_
|
||||||
c.description,
|
c.description,
|
||||||
c.transform,
|
c.transform,
|
||||||
*c.parent,
|
*c.parent,
|
||||||
cr::AttachmentType::Rigid) :
|
cr::AttachmentType::Rigid,
|
||||||
|
c.socket_name) :
|
||||||
spawn_actor(c.description, c.transform);
|
spawn_actor(c.description, c.transform);
|
||||||
if (!result.HasError())
|
if (!result.HasError())
|
||||||
{
|
{
|
||||||
|
|
|
@ -14,6 +14,8 @@ FString CarlaGetStringError(ECarlaServerResponse Response)
|
||||||
return "Sucess";
|
return "Sucess";
|
||||||
case ECarlaServerResponse::ActorNotFound:
|
case ECarlaServerResponse::ActorNotFound:
|
||||||
return "Actor could not be found in the registry";
|
return "Actor could not be found in the registry";
|
||||||
|
case ECarlaServerResponse::ComponentNotFound:
|
||||||
|
return "Component could not be found in this actor";
|
||||||
case ECarlaServerResponse::ActorTypeMismatch:
|
case ECarlaServerResponse::ActorTypeMismatch:
|
||||||
return "Actor does not match the expected type";
|
return "Actor does not match the expected type";
|
||||||
case ECarlaServerResponse::MissingActor:
|
case ECarlaServerResponse::MissingActor:
|
||||||
|
|
|
@ -10,6 +10,7 @@ enum class ECarlaServerResponse
|
||||||
{
|
{
|
||||||
Success,
|
Success,
|
||||||
ActorNotFound,
|
ActorNotFound,
|
||||||
|
ComponentNotFound,
|
||||||
ActorTypeMismatch,
|
ActorTypeMismatch,
|
||||||
FunctionNotSupported,
|
FunctionNotSupported,
|
||||||
NullActor,
|
NullActor,
|
||||||
|
|
|
@ -96,7 +96,8 @@ static void UActorAttacher_AttachActorsWithSpringArmGhost(
|
||||||
void UActorAttacher::AttachActors(
|
void UActorAttacher::AttachActors(
|
||||||
AActor *Child,
|
AActor *Child,
|
||||||
AActor *Parent,
|
AActor *Parent,
|
||||||
const EAttachmentType AttachmentType)
|
const EAttachmentType AttachmentType,
|
||||||
|
const FString& SocketName)
|
||||||
{
|
{
|
||||||
check(Child != nullptr);
|
check(Child != nullptr);
|
||||||
check(Parent != nullptr);
|
check(Parent != nullptr);
|
||||||
|
@ -104,7 +105,7 @@ void UActorAttacher::AttachActors(
|
||||||
switch (AttachmentType)
|
switch (AttachmentType)
|
||||||
{
|
{
|
||||||
case EAttachmentType::Rigid:
|
case EAttachmentType::Rigid:
|
||||||
Child->AttachToActor(Parent, FAttachmentTransformRules::KeepRelativeTransform);
|
Child->AttachToActor(Parent, FAttachmentTransformRules::KeepRelativeTransform, FName(*SocketName));
|
||||||
break;
|
break;
|
||||||
case EAttachmentType::SpringArm:
|
case EAttachmentType::SpringArm:
|
||||||
UActorAttacher_AttachActorsWithSpringArm(Child, Parent);
|
UActorAttacher_AttachActorsWithSpringArm(Child, Parent);
|
||||||
|
|
|
@ -42,5 +42,5 @@ class CARLA_API UActorAttacher : public UBlueprintFunctionLibrary
|
||||||
public:
|
public:
|
||||||
|
|
||||||
UFUNCTION(BlueprintCallable, Category="CARLA|Actor Attacher")
|
UFUNCTION(BlueprintCallable, Category="CARLA|Actor Attacher")
|
||||||
static void AttachActors(AActor *Child, AActor *Parent, EAttachmentType AttachmentType);
|
static void AttachActors(AActor *Child, AActor *Parent, EAttachmentType AttachmentType, const FString& SocketName = "");
|
||||||
};
|
};
|
||||||
|
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -154,16 +154,32 @@ void UOpenDriveToMap::CreateMap()
|
||||||
UE_LOG(LogCarlaToolsMapGenerator, Error, TEXT("Map Name Is Empty") );
|
UE_LOG(LogCarlaToolsMapGenerator, Error, TEXT("Map Name Is Empty") );
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if ( !IsValid(FileDownloader) )
|
|
||||||
|
if( !Url.IsEmpty() ) {
|
||||||
|
if ( !IsValid(FileDownloader) )
|
||||||
|
{
|
||||||
|
FileDownloader = NewObject<UCustomFileDownloader>();
|
||||||
|
}
|
||||||
|
|
||||||
|
FileDownloader->ResultFileName = MapName;
|
||||||
|
FileDownloader->Url = Url;
|
||||||
|
|
||||||
|
FileDownloader->DownloadDelegate.BindUObject( this, &UOpenDriveToMap::ConvertOSMInOpenDrive );
|
||||||
|
FileDownloader->StartDownload();
|
||||||
|
}
|
||||||
|
else if(LocalFilePath.EndsWith(".xodr"))
|
||||||
{
|
{
|
||||||
FileDownloader = NewObject<UCustomFileDownloader>();
|
ImportXODR();
|
||||||
|
}
|
||||||
|
else if(LocalFilePath.EndsWith(".osm"))
|
||||||
|
{
|
||||||
|
ImportOSM();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
UE_LOG(LogCarlaToolsMapGenerator, Error, TEXT("URL and Local FilePath are Empty. URL: %s Local FilePath: %s"), *Url, *LocalFilePath );
|
||||||
}
|
}
|
||||||
|
|
||||||
FileDownloader->ResultFileName = MapName;
|
|
||||||
FileDownloader->Url = Url;
|
|
||||||
|
|
||||||
FileDownloader->DownloadDelegate.BindUObject( this, &UOpenDriveToMap::ConvertOSMInOpenDrive );
|
|
||||||
FileDownloader->StartDownload();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void UOpenDriveToMap::CreateTerrain( const int MeshGridSize, const float MeshGridSectionSize)
|
void UOpenDriveToMap::CreateTerrain( const int MeshGridSize, const float MeshGridSectionSize)
|
||||||
|
@ -490,7 +506,7 @@ void UOpenDriveToMap::GenerateAll(const boost::optional<carla::road::Map>& Param
|
||||||
{
|
{
|
||||||
GenerateRoadMesh(ParamCarlaMap, MinLocation, MaxLocation);
|
GenerateRoadMesh(ParamCarlaMap, MinLocation, MaxLocation);
|
||||||
GenerateLaneMarks(ParamCarlaMap, MinLocation, MaxLocation);
|
GenerateLaneMarks(ParamCarlaMap, MinLocation, MaxLocation);
|
||||||
//GenerateSpawnPoints(ParamCarlaMap);
|
GenerateSpawnPoints(ParamCarlaMap, MinLocation, MaxLocation);
|
||||||
CreateTerrain(12800, 256);
|
CreateTerrain(12800, 256);
|
||||||
GenerateTreePositions(ParamCarlaMap, MinLocation, MaxLocation);
|
GenerateTreePositions(ParamCarlaMap, MinLocation, MaxLocation);
|
||||||
GenerationFinished(MinLocation, MaxLocation);
|
GenerationFinished(MinLocation, MaxLocation);
|
||||||
|
@ -714,10 +730,14 @@ void UOpenDriveToMap::GenerateSpawnPoints( const boost::optional<carla::road::Ma
|
||||||
for (const auto &Wp : Waypoints)
|
for (const auto &Wp : Waypoints)
|
||||||
{
|
{
|
||||||
const FTransform Trans = ParamCarlaMap->ComputeTransform(Wp);
|
const FTransform Trans = ParamCarlaMap->ComputeTransform(Wp);
|
||||||
AVehicleSpawnPoint *Spawner = UEditorLevelLibrary::GetEditorWorld()->SpawnActor<AVehicleSpawnPoint>();
|
if( Trans.GetLocation().X >= MinLocation.X && Trans.GetLocation().Y >= MinLocation.Y &&
|
||||||
Spawner->SetActorRotation(Trans.GetRotation());
|
Trans.GetLocation().X <= MaxLocation.X && Trans.GetLocation().Y <= MaxLocation.Y)
|
||||||
Spawner->SetActorLocation(Trans.GetTranslation() + FVector(0.f, 0.f, SpawnersHeight));
|
{
|
||||||
ActorsToMove.Add(Spawner);
|
AVehicleSpawnPoint *Spawner = UEditorLevelLibrary::GetEditorWorld()->SpawnActor<AVehicleSpawnPoint>();
|
||||||
|
Spawner->SetActorRotation(Trans.GetRotation());
|
||||||
|
Spawner->SetActorLocation(Trans.GetTranslation() + FVector(0.f, 0.f, SpawnersHeight));
|
||||||
|
ActorsToMove.Add(Spawner);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -878,6 +898,41 @@ bool UOpenDriveToMap::IsInRoad(
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void UOpenDriveToMap::ImportXODR(){
|
||||||
|
IPlatformFile& FileManager = FPlatformFileManager::Get().GetPlatformFile();
|
||||||
|
FString MyFileDestination = FPaths::ProjectContentDir() + "CustomMaps/" + MapName + "/OpenDrive/" + MapName + ".xodr";
|
||||||
|
|
||||||
|
if(FileManager.CopyFile( *MyFileDestination, *LocalFilePath,
|
||||||
|
EPlatformFileRead::None,
|
||||||
|
EPlatformFileWrite::None))
|
||||||
|
{
|
||||||
|
UE_LOG(LogCarlaToolsMapGenerator, Verbose, TEXT("FilePaths: File Copied!"));
|
||||||
|
FilePath = MyFileDestination;
|
||||||
|
LoadMap();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
UE_LOG(LogCarlaToolsMapGenerator, Error, TEXT("FilePaths local xodr file not copied: File not Copied!"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void UOpenDriveToMap::ImportOSM(){
|
||||||
|
IPlatformFile& FileManager = FPlatformFileManager::Get().GetPlatformFile();
|
||||||
|
FString MyFileDestination = FPaths::ProjectContentDir() + "CustomMaps/" + MapName + "/OpenDrive/" + MapName + ".osm";
|
||||||
|
|
||||||
|
if(FileManager.CopyFile( *MyFileDestination, *LocalFilePath,
|
||||||
|
EPlatformFileRead::None,
|
||||||
|
EPlatformFileWrite::None))
|
||||||
|
{
|
||||||
|
UE_LOG(LogCarlaToolsMapGenerator, Verbose, TEXT("FilePaths: File Copied!"));
|
||||||
|
ConvertOSMInOpenDrive();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
UE_LOG(LogCarlaToolsMapGenerator, Error, TEXT("FilePaths local osm file not copied: File not Copied!"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
void UOpenDriveToMap::MoveActorsToSubLevels(TArray<AActor*> ActorsToMove)
|
void UOpenDriveToMap::MoveActorsToSubLevels(TArray<AActor*> ActorsToMove)
|
||||||
{
|
{
|
||||||
AActor* QueryActor = UGameplayStatics::GetActorOfClass(
|
AActor* QueryActor = UGameplayStatics::GetActorOfClass(
|
||||||
|
|
|
@ -91,6 +91,9 @@ public:
|
||||||
UPROPERTY( EditAnywhere, BlueprintReadWrite, Category="Settings" )
|
UPROPERTY( EditAnywhere, BlueprintReadWrite, Category="Settings" )
|
||||||
FString Url;
|
FString Url;
|
||||||
|
|
||||||
|
UPROPERTY( EditAnywhere, BlueprintReadWrite, Category="Settings" )
|
||||||
|
FString LocalFilePath;
|
||||||
|
|
||||||
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Settings")
|
UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = "Settings")
|
||||||
FVector2D OriginGeoCoordinates;
|
FVector2D OriginGeoCoordinates;
|
||||||
|
|
||||||
|
@ -213,6 +216,9 @@ private:
|
||||||
|
|
||||||
void InitTextureData();
|
void InitTextureData();
|
||||||
|
|
||||||
|
void ImportXODR();
|
||||||
|
void ImportOSM();
|
||||||
|
|
||||||
UPROPERTY()
|
UPROPERTY()
|
||||||
UCustomFileDownloader* FileDownloader;
|
UCustomFileDownloader* FileDownloader;
|
||||||
UPROPERTY()
|
UPROPERTY()
|
||||||
|
|
|
@ -19,7 +19,7 @@ for /F "delims=" %%a in (%CONTENT_VERSIONS%) do (
|
||||||
set "lastLine=%%a"
|
set "lastLine=%%a"
|
||||||
)
|
)
|
||||||
set CONTENT_ID=%lastLine:~-16,16%
|
set CONTENT_ID=%lastLine:~-16,16%
|
||||||
set CONTENT_LINK=http://carla-assets.s3.amazonaws.com/%CONTENT_ID%.tar.gz
|
set CONTENT_LINK=https://carla-assets.s3.us-east-005.backblazeb2.com/%CONTENT_ID%.tar.gz
|
||||||
if "%CONTENT_ID:~0,2%"=="20" (
|
if "%CONTENT_ID:~0,2%"=="20" (
|
||||||
set CONTENT_FILE=%CONTENT_FOLDER%/%CONTENT_ID%.tar.gz
|
set CONTENT_FILE=%CONTENT_FOLDER%/%CONTENT_ID%.tar.gz
|
||||||
set CONTENT_FILE_TAR=%CONTENT_FOLDER%/%CONTENT_ID%.tar
|
set CONTENT_FILE_TAR=%CONTENT_FOLDER%/%CONTENT_ID%.tar
|
||||||
|
|
|
@ -41,13 +41,16 @@ done
|
||||||
# -- Set up environment --------------------------------------------------------
|
# -- Set up environment --------------------------------------------------------
|
||||||
# ==============================================================================
|
# ==============================================================================
|
||||||
|
|
||||||
|
MAX_PARALLELL_DOWNLOADS=16
|
||||||
|
MAX_CONNECTIONS_PER_SERVER=16
|
||||||
|
|
||||||
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
||||||
pushd "$SCRIPT_DIR" >/dev/null
|
pushd "$SCRIPT_DIR" >/dev/null
|
||||||
|
|
||||||
CONTENT_FOLDER="${SCRIPT_DIR}/Unreal/CarlaUE4/Content/Carla"
|
CONTENT_FOLDER="${SCRIPT_DIR}/Unreal/CarlaUE4/Content/Carla"
|
||||||
|
|
||||||
CONTENT_ID=$(tac $SCRIPT_DIR/Util/ContentVersions.txt | egrep -m 1 . | rev | cut -d' ' -f1 | rev)
|
CONTENT_ID=$(tac $SCRIPT_DIR/Util/ContentVersions.txt | egrep -m 1 . | rev | cut -d' ' -f1 | rev)
|
||||||
CONTENT_LINK=http://carla-assets.s3.amazonaws.com/${CONTENT_ID}.tar.gz
|
CONTENT_LINK=https://carla-assets.s3.us-east-005.backblazeb2.com/${CONTENT_ID}.tar.gz
|
||||||
|
|
||||||
VERSION_FILE="${CONTENT_FOLDER}/.version"
|
VERSION_FILE="${CONTENT_FOLDER}/.version"
|
||||||
|
|
||||||
|
@ -60,7 +63,7 @@ function download_content {
|
||||||
mkdir -p Content
|
mkdir -p Content
|
||||||
if hash aria2c 2>/dev/null; then
|
if hash aria2c 2>/dev/null; then
|
||||||
echo -e "${CONTENT_LINK}\n\tout=Content.tar.gz" > .aria2c.input
|
echo -e "${CONTENT_LINK}\n\tout=Content.tar.gz" > .aria2c.input
|
||||||
aria2c -j16 -x16 --input-file=.aria2c.input
|
aria2c -j${MAX_PARALLELL_DOWNLOADS} -x${MAX_CONNECTIONS_PER_SERVER} --input-file=.aria2c.input
|
||||||
rm -f .aria2c.input
|
rm -f .aria2c.input
|
||||||
else
|
else
|
||||||
wget -c ${CONTENT_LINK} -O Content.tar.gz
|
wget -c ${CONTENT_LINK} -O Content.tar.gz
|
||||||
|
|
|
@ -155,10 +155,10 @@ if exist %OMNIVERSE_PLUGIN_FOLDER% (
|
||||||
)
|
)
|
||||||
|
|
||||||
if %USE_CARSIM% == true (
|
if %USE_CARSIM% == true (
|
||||||
py -3 %ROOT_PATH%Util/BuildTools/enable_carsim_to_uproject.py -f="%ROOT_PATH%Unreal/CarlaUE4/CarlaUE4.uproject" -e
|
python %ROOT_PATH%Util/BuildTools/enable_carsim_to_uproject.py -f="%ROOT_PATH%Unreal/CarlaUE4/CarlaUE4.uproject" -e
|
||||||
set CARSIM_STATE="CarSim ON"
|
set CARSIM_STATE="CarSim ON"
|
||||||
) else (
|
) else (
|
||||||
py -3 %ROOT_PATH%Util/BuildTools/enable_carsim_to_uproject.py -f="%ROOT_PATH%Unreal/CarlaUE4/CarlaUE4.uproject"
|
python %ROOT_PATH%Util/BuildTools/enable_carsim_to_uproject.py -f="%ROOT_PATH%Unreal/CarlaUE4/CarlaUE4.uproject"
|
||||||
set CARSIM_STATE="CarSim OFF"
|
set CARSIM_STATE="CarSim OFF"
|
||||||
)
|
)
|
||||||
if %USE_CHRONO% == true (
|
if %USE_CHRONO% == true (
|
||||||
|
|
|
@ -109,7 +109,7 @@ rem Build for Python 3
|
||||||
rem
|
rem
|
||||||
if %BUILD_FOR_PYTHON3%==true (
|
if %BUILD_FOR_PYTHON3%==true (
|
||||||
echo Building Python API for Python 3.
|
echo Building Python API for Python 3.
|
||||||
py -3 setup.py bdist_egg bdist_wheel
|
python setup.py bdist_egg bdist_wheel
|
||||||
if %errorlevel% neq 0 goto error_build_wheel
|
if %errorlevel% neq 0 goto error_build_wheel
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -12,6 +12,10 @@ AWS_COPY="aws s3 cp"
|
||||||
DOCKER="docker"
|
DOCKER="docker"
|
||||||
UNTAR="tar -xvzf"
|
UNTAR="tar -xvzf"
|
||||||
UPLOAD_MAPS=true
|
UPLOAD_MAPS=true
|
||||||
|
PROFILE="--profile Jenkins-CVC"
|
||||||
|
ENDPOINT="--endpoint-url=https://s3.us-east-005.backblazeb2.com/"
|
||||||
|
TEST=false
|
||||||
|
|
||||||
|
|
||||||
# ==============================================================================
|
# ==============================================================================
|
||||||
# -- Parse arguments -----------------------------------------------------------
|
# -- Parse arguments -----------------------------------------------------------
|
||||||
|
@ -21,12 +25,15 @@ DOC_STRING="Upload latest build to S3."
|
||||||
|
|
||||||
USAGE_STRING="Usage: $0 [-h|--help] [--replace-latest] [--docker-push] [--dry-run]"
|
USAGE_STRING="Usage: $0 [-h|--help] [--replace-latest] [--docker-push] [--dry-run]"
|
||||||
|
|
||||||
OPTS=`getopt -o h --long help,replace-latest,docker-push,dry-run -n 'parse-options' -- "$@"`
|
OPTS=`getopt -o h --long help,replace-latest,docker-push,dry-run,test -n 'parse-options' -- "$@"`
|
||||||
|
|
||||||
eval set -- "$OPTS"
|
eval set -- "$OPTS"
|
||||||
|
|
||||||
while [[ $# -gt 0 ]]; do
|
while [[ $# -gt 0 ]]; do
|
||||||
case "$1" in
|
case "$1" in
|
||||||
|
--test )
|
||||||
|
TEST=true
|
||||||
|
shift ;;
|
||||||
--replace-latest )
|
--replace-latest )
|
||||||
REPLACE_LATEST=true;
|
REPLACE_LATEST=true;
|
||||||
shift ;;
|
shift ;;
|
||||||
|
@ -86,6 +93,25 @@ if [ ! -f ${LATEST_PACKAGE_PATH} ]; then
|
||||||
fatal_error "Latest package not found, please run 'make package'."
|
fatal_error "Latest package not found, please run 'make package'."
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
# ==============================================================================
|
||||||
|
# -- TEST --------------------------------------------------------------------
|
||||||
|
# ==============================================================================
|
||||||
|
|
||||||
|
if ${TEST} ; then
|
||||||
|
LATEST_PACKAGE=test_CARLA_${REPOSITORY_TAG}.tar.gz
|
||||||
|
LATEST_PACKAGE_PATH=./${LATEST_PACKAGE}
|
||||||
|
LATEST_PACKAGE2=test_AdditionalMaps_${REPOSITORY_TAG}.tar.gz
|
||||||
|
LATEST_PACKAGE_PATH2=./${LATEST_PACKAGE2}
|
||||||
|
|
||||||
|
DEPLOY_NAME=test_CARLA_${REPOSITORY_TAG}.tar.gz
|
||||||
|
DEPLOY_NAME2=test_AdditionalMaps_${REPOSITORY_TAG}.tar.gz
|
||||||
|
|
||||||
|
touch ${LATEST_PACKAGE}
|
||||||
|
touch ${LATEST_PACKAGE2}
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
# ==============================================================================
|
# ==============================================================================
|
||||||
# -- Upload --------------------------------------------------------------------
|
# -- Upload --------------------------------------------------------------------
|
||||||
# ==============================================================================
|
# ==============================================================================
|
||||||
|
@ -93,10 +119,10 @@ fi
|
||||||
DEPLOY_URI=${S3_PREFIX}/${DEPLOY_NAME}
|
DEPLOY_URI=${S3_PREFIX}/${DEPLOY_NAME}
|
||||||
DEPLOY_URI2=${S3_PREFIX}/${DEPLOY_NAME2}
|
DEPLOY_URI2=${S3_PREFIX}/${DEPLOY_NAME2}
|
||||||
|
|
||||||
${AWS_COPY} ${LATEST_PACKAGE_PATH} ${DEPLOY_URI}
|
${AWS_COPY} ${LATEST_PACKAGE_PATH} ${DEPLOY_URI} ${ENDPOINT} ${PROFILE}
|
||||||
log "Latest build uploaded to ${DEPLOY_URI}."
|
log "Latest build uploaded to ${DEPLOY_URI}."
|
||||||
|
|
||||||
${AWS_COPY} ${LATEST_PACKAGE_PATH2} ${DEPLOY_URI2}
|
${AWS_COPY} ${LATEST_PACKAGE_PATH2} ${DEPLOY_URI2} ${ENDPOINT} ${PROFILE}
|
||||||
log "Latest build uploaded to ${DEPLOY_URI2}."
|
log "Latest build uploaded to ${DEPLOY_URI2}."
|
||||||
|
|
||||||
# ==============================================================================
|
# ==============================================================================
|
||||||
|
@ -105,10 +131,10 @@ log "Latest build uploaded to ${DEPLOY_URI2}."
|
||||||
|
|
||||||
if ${REPLACE_LATEST} ; then
|
if ${REPLACE_LATEST} ; then
|
||||||
|
|
||||||
${AWS_COPY} ${DEPLOY_URI} ${LATEST_DEPLOY_URI}
|
${AWS_COPY} ${DEPLOY_URI} ${LATEST_DEPLOY_URI} ${ENDPOINT} ${PROFILE}
|
||||||
log "Latest build uploaded to ${LATEST_DEPLOY_URI}."
|
log "Latest build uploaded to ${LATEST_DEPLOY_URI}."
|
||||||
|
|
||||||
${AWS_COPY} ${DEPLOY_URI2} ${LATEST_DEPLOY_URI2}
|
${AWS_COPY} ${DEPLOY_URI2} ${LATEST_DEPLOY_URI2} ${ENDPOINT} ${PROFILE}
|
||||||
log "Latest build uploaded to ${LATEST_DEPLOY_URI2}."
|
log "Latest build uploaded to ${LATEST_DEPLOY_URI2}."
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
|
@ -119,10 +119,10 @@ rem ============================================================================
|
||||||
if %DO_PACKAGE%==true (
|
if %DO_PACKAGE%==true (
|
||||||
|
|
||||||
if %USE_CARSIM% == true (
|
if %USE_CARSIM% == true (
|
||||||
py -3 %ROOT_PATH%Util/BuildTools/enable_carsim_to_uproject.py -f="%ROOT_PATH%Unreal/CarlaUE4/CarlaUE4.uproject" -e
|
python %ROOT_PATH%Util/BuildTools/enable_carsim_to_uproject.py -f="%ROOT_PATH%Unreal/CarlaUE4/CarlaUE4.uproject" -e
|
||||||
echo CarSim ON > "%ROOT_PATH%Unreal/CarlaUE4/Config/CarSimConfig.ini"
|
echo CarSim ON > "%ROOT_PATH%Unreal/CarlaUE4/Config/CarSimConfig.ini"
|
||||||
) else (
|
) else (
|
||||||
py -3 %ROOT_PATH%Util/BuildTools/enable_carsim_to_uproject.py -f="%ROOT_PATH%Unreal/CarlaUE4/CarlaUE4.uproject"
|
python %ROOT_PATH%Util/BuildTools/enable_carsim_to_uproject.py -f="%ROOT_PATH%Unreal/CarlaUE4/CarlaUE4.uproject"
|
||||||
echo CarSim OFF > "%ROOT_PATH%Unreal/CarlaUE4/Config/CarSimConfig.ini"
|
echo CarSim OFF > "%ROOT_PATH%Unreal/CarlaUE4/Config/CarSimConfig.ini"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
#!/bin/bash
|
||||||
# ==============================================================================
|
# ==============================================================================
|
||||||
# -- Parse arguments -----------------------------------------------------------
|
# -- Parse arguments -----------------------------------------------------------
|
||||||
# ==============================================================================
|
# ==============================================================================
|
||||||
|
|
|
@ -367,7 +367,7 @@ FOR /F "usebackq tokens=1,2" %%i in ("%VERSION_FILE%") do (
|
||||||
set ASSETS_VERSION=%%i
|
set ASSETS_VERSION=%%i
|
||||||
set HASH=%%j
|
set HASH=%%j
|
||||||
)
|
)
|
||||||
set URL=http://carla-assets.s3.amazonaws.com/%HASH%.tar.gz
|
set URL=https://carla-assets.s3.us-east-005.backblazeb2.com/%HASH%.tar.gz
|
||||||
|
|
||||||
rem ============================================================================
|
rem ============================================================================
|
||||||
rem -- Generate CMake ----------------------------------------------------------
|
rem -- Generate CMake ----------------------------------------------------------
|
||||||
|
|
|
@ -69,6 +69,7 @@ UNREAL_HOSTED_CFLAGS="--sysroot=$UE4_ROOT/Engine/Extras/ThirdPartyNotUE/SDKs/Hos
|
||||||
|
|
||||||
BOOST_VERSION=1.80.0
|
BOOST_VERSION=1.80.0
|
||||||
BOOST_BASENAME="boost-${BOOST_VERSION}-${CXX_TAG}"
|
BOOST_BASENAME="boost-${BOOST_VERSION}-${CXX_TAG}"
|
||||||
|
BOOST_SHA256SUM="4b2136f98bdd1f5857f1c3dea9ac2018effe65286cf251534b6ae20cc45e1847"
|
||||||
|
|
||||||
BOOST_INCLUDE=${PWD}/${BOOST_BASENAME}-install/include
|
BOOST_INCLUDE=${PWD}/${BOOST_BASENAME}-install/include
|
||||||
BOOST_LIBPATH=${PWD}/${BOOST_BASENAME}-install/lib
|
BOOST_LIBPATH=${PWD}/${BOOST_BASENAME}-install/lib
|
||||||
|
@ -91,15 +92,30 @@ for PY_VERSION in ${PY_VERSION_LIST[@]} ; do
|
||||||
BOOST_PACKAGE_BASENAME=boost_${BOOST_VERSION//./_}
|
BOOST_PACKAGE_BASENAME=boost_${BOOST_VERSION//./_}
|
||||||
|
|
||||||
log "Retrieving boost."
|
log "Retrieving boost."
|
||||||
wget "https://boostorg.jfrog.io/artifactory/main/release/${BOOST_VERSION}/source/${BOOST_PACKAGE_BASENAME}.tar.gz" || true
|
|
||||||
|
start=$(date +%s)
|
||||||
|
wget "https://archives.boost.io/release/${BOOST_VERSION}/source/${BOOST_PACKAGE_BASENAME}.tar.gz" || true
|
||||||
|
end=$(date +%s)
|
||||||
|
echo "Elapsed Time downloading from boost webpage: $(($end-$start)) seconds"
|
||||||
|
|
||||||
# try to use the backup boost we have in Jenkins
|
# try to use the backup boost we have in Jenkins
|
||||||
if [[ ! -f "${BOOST_PACKAGE_BASENAME}.tar.gz" ]] ; then
|
if [ ! -f "${BOOST_PACKAGE_BASENAME}.tar.gz" ] || [[ $(sha256sum "${BOOST_PACKAGE_BASENAME}.tar.gz") != "${BOOST_SHA256SUM}" ]] ; then
|
||||||
log "Using boost backup"
|
log "Using boost backup"
|
||||||
wget "https://carla-releases.s3.eu-west-3.amazonaws.com/Backup/${BOOST_PACKAGE_BASENAME}.tar.gz" || true
|
|
||||||
|
start=$(date +%s)
|
||||||
|
wget "https://carla-releases.s3.us-east-005.backblazeb2.com/Backup/${BOOST_PACKAGE_BASENAME}.tar.gz" || true
|
||||||
|
end=$(date +%s)
|
||||||
|
echo "Elapsed Time downloading from boost carla backup in backblaze: $(($end-$start)) seconds"
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
log "Extracting boost for Python ${PY_VERSION}."
|
log "Extracting boost for Python ${PY_VERSION}."
|
||||||
|
|
||||||
|
start=$(date +%s)
|
||||||
tar -xzf ${BOOST_PACKAGE_BASENAME}.tar.gz
|
tar -xzf ${BOOST_PACKAGE_BASENAME}.tar.gz
|
||||||
|
end=$(date +%s)
|
||||||
|
echo "Elapsed Time Extracting boost for Python: $(($end-$start)) seconds"
|
||||||
|
|
||||||
mkdir -p ${BOOST_BASENAME}-install/include
|
mkdir -p ${BOOST_BASENAME}-install/include
|
||||||
mv ${BOOST_PACKAGE_BASENAME} ${BOOST_BASENAME}-source
|
mv ${BOOST_PACKAGE_BASENAME} ${BOOST_BASENAME}-source
|
||||||
|
|
||||||
|
@ -165,8 +181,13 @@ else
|
||||||
|
|
||||||
log "Retrieving rpclib."
|
log "Retrieving rpclib."
|
||||||
|
|
||||||
|
start_download_time=$(date +%s)
|
||||||
|
|
||||||
git clone -b ${RPCLIB_PATCH} https://github.com/carla-simulator/rpclib.git ${RPCLIB_BASENAME}-source
|
git clone -b ${RPCLIB_PATCH} https://github.com/carla-simulator/rpclib.git ${RPCLIB_BASENAME}-source
|
||||||
|
|
||||||
|
end_download_time=$(date +%s)
|
||||||
|
|
||||||
|
echo "Elapsed Time downloading rpclib: $(($end_download_time-$start_download_time)) seconds"
|
||||||
log "Building rpclib with libc++."
|
log "Building rpclib with libc++."
|
||||||
|
|
||||||
# rpclib does not use any cmake 3.9 feature.
|
# rpclib does not use any cmake 3.9 feature.
|
||||||
|
@ -233,8 +254,13 @@ else
|
||||||
|
|
||||||
log "Retrieving Google Test."
|
log "Retrieving Google Test."
|
||||||
|
|
||||||
|
start_download_time=$(date +%s)
|
||||||
|
|
||||||
git clone --depth=1 -b release-${GTEST_VERSION} https://github.com/google/googletest.git ${GTEST_BASENAME}-source
|
git clone --depth=1 -b release-${GTEST_VERSION} https://github.com/google/googletest.git ${GTEST_BASENAME}-source
|
||||||
|
|
||||||
|
end_download_time=$(date +%s)
|
||||||
|
echo "Elapsed Time downloading rpclib: $(($end-$start)) seconds"
|
||||||
|
|
||||||
log "Building Google Test with libc++."
|
log "Building Google Test with libc++."
|
||||||
|
|
||||||
mkdir -p ${GTEST_BASENAME}-libcxx-build
|
mkdir -p ${GTEST_BASENAME}-libcxx-build
|
||||||
|
@ -295,12 +321,15 @@ else
|
||||||
|
|
||||||
log "Retrieving Recast & Detour"
|
log "Retrieving Recast & Detour"
|
||||||
|
|
||||||
git clone https://github.com/carla-simulator/recastnavigation.git ${RECAST_BASENAME}-source
|
start=$(date +%s)
|
||||||
|
|
||||||
|
git clone --depth 1 -b carla https://github.com/carla-simulator/recastnavigation.git ${RECAST_BASENAME}-source
|
||||||
|
|
||||||
|
end=$(date +%s)
|
||||||
|
echo "Elapsed Time downloading: $(($end-$start)) seconds"
|
||||||
|
|
||||||
pushd ${RECAST_BASENAME}-source >/dev/null
|
pushd ${RECAST_BASENAME}-source >/dev/null
|
||||||
|
|
||||||
git checkout carla
|
|
||||||
|
|
||||||
popd >/dev/null
|
popd >/dev/null
|
||||||
|
|
||||||
log "Building Recast & Detour with libc++."
|
log "Building Recast & Detour with libc++."
|
||||||
|
@ -350,10 +379,18 @@ if [[ -d ${LIBPNG_INSTALL} ]] ; then
|
||||||
log "Libpng already installed."
|
log "Libpng already installed."
|
||||||
else
|
else
|
||||||
log "Retrieving libpng."
|
log "Retrieving libpng."
|
||||||
wget ${LIBPNG_REPO}
|
|
||||||
|
|
||||||
|
start=$(date +%s)
|
||||||
|
wget ${LIBPNG_REPO}
|
||||||
|
end=$(date +%s)
|
||||||
|
echo "Elapsed Time downloading libpng: $(($end-$start)) seconds"
|
||||||
|
|
||||||
|
start=$(date +%s)
|
||||||
log "Extracting libpng."
|
log "Extracting libpng."
|
||||||
tar -xf libpng-${LIBPNG_VERSION}.tar.xz
|
tar -xf libpng-${LIBPNG_VERSION}.tar.xz
|
||||||
|
end=$(date +%s)
|
||||||
|
echo "Elapsed Time Extracting libpng: $(($end-$start)) seconds"
|
||||||
|
|
||||||
mv ${LIBPNG_BASENAME} ${LIBPNG_BASENAME}-source
|
mv ${LIBPNG_BASENAME} ${LIBPNG_BASENAME}-source
|
||||||
|
|
||||||
pushd ${LIBPNG_BASENAME}-source >/dev/null
|
pushd ${LIBPNG_BASENAME}-source >/dev/null
|
||||||
|
@ -387,16 +424,26 @@ if [[ -d ${XERCESC_INSTALL_DIR} && -d ${XERCESC_INSTALL_SERVER_DIR} ]] ; then
|
||||||
log "Xerces-c already installed."
|
log "Xerces-c already installed."
|
||||||
else
|
else
|
||||||
log "Retrieving xerces-c."
|
log "Retrieving xerces-c."
|
||||||
|
start=$(date +%s)
|
||||||
wget ${XERCESC_REPO}
|
wget ${XERCESC_REPO}
|
||||||
|
end=$(date +%s)
|
||||||
|
echo "Elapsed Time downloading from xerces repo: $(($end-$start)) seconds"
|
||||||
# try to use the backup boost we have in Jenkins
|
# try to use the backup boost we have in Jenkins
|
||||||
if [[ ! -f "${XERCESC_BASENAME}.tar.gz" ]] ; then
|
if [[ ! -f "${XERCESC_BASENAME}.tar.gz" ]] ; then
|
||||||
log "Using xerces backup"
|
log "Using xerces backup"
|
||||||
wget "https://carla-releases.s3.eu-west-3.amazonaws.com/Backup/${XERCESC_BASENAME}.tar.gz" || true
|
start=$(date +%s)
|
||||||
|
wget "https://carla-releases.s3.us-east-005.backblazeb2.com/Backup/${XERCESC_BASENAME}.tar.gz" || true
|
||||||
|
end=$(date +%s)
|
||||||
|
echo "Elapsed Time downloading from xerces backup: $(($end-$start)) seconds"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
log "Extracting xerces-c."
|
log "Extracting xerces-c."
|
||||||
|
|
||||||
|
start=$(date +%s)
|
||||||
tar -xzf ${XERCESC_BASENAME}.tar.gz
|
tar -xzf ${XERCESC_BASENAME}.tar.gz
|
||||||
|
end=$(date +%s)
|
||||||
|
echo "Elapsed Time Extracting xerces-c: $(($end-$start)) seconds"
|
||||||
|
|
||||||
mv ${XERCESC_BASENAME} ${XERCESC_SRC_DIR}
|
mv ${XERCESC_BASENAME} ${XERCESC_SRC_DIR}
|
||||||
mkdir -p ${XERCESC_INSTALL_DIR}
|
mkdir -p ${XERCESC_INSTALL_DIR}
|
||||||
mkdir -p ${XERCESC_SRC_DIR}/build
|
mkdir -p ${XERCESC_SRC_DIR}/build
|
||||||
|
@ -460,10 +507,18 @@ if [[ -d ${EIGEN_INSTALL_DIR} ]] ; then
|
||||||
log "Eigen already installed."
|
log "Eigen already installed."
|
||||||
else
|
else
|
||||||
log "Retrieving Eigen."
|
log "Retrieving Eigen."
|
||||||
|
|
||||||
|
start=$(date +%s)
|
||||||
wget ${EIGEN_REPO}
|
wget ${EIGEN_REPO}
|
||||||
|
end=$(date +%s)
|
||||||
|
echo "Elapsed Time downloading from eigen repo: $(($end-$start)) seconds"
|
||||||
|
|
||||||
log "Extracting Eigen."
|
log "Extracting Eigen."
|
||||||
|
start=$(date +%s)
|
||||||
tar -xzf ${EIGEN_BASENAME}.tar.gz
|
tar -xzf ${EIGEN_BASENAME}.tar.gz
|
||||||
|
end=$(date +%s)
|
||||||
|
echo "Elapsed Time Extracting EIGEN: $(($end-$start)) seconds"
|
||||||
|
|
||||||
mv ${EIGEN_BASENAME} ${EIGEN_SRC_DIR}
|
mv ${EIGEN_BASENAME} ${EIGEN_SRC_DIR}
|
||||||
mkdir -p ${EIGEN_INCLUDE}/unsupported
|
mkdir -p ${EIGEN_INCLUDE}/unsupported
|
||||||
mv ${EIGEN_SRC_DIR}/Eigen ${EIGEN_INCLUDE}
|
mv ${EIGEN_SRC_DIR}/Eigen ${EIGEN_INCLUDE}
|
||||||
|
@ -495,10 +550,19 @@ if ${USE_CHRONO} ; then
|
||||||
log "Eigen already installed."
|
log "Eigen already installed."
|
||||||
else
|
else
|
||||||
log "Retrieving Eigen."
|
log "Retrieving Eigen."
|
||||||
|
|
||||||
|
start=$(date +%s)
|
||||||
wget ${EIGEN_REPO}
|
wget ${EIGEN_REPO}
|
||||||
|
end=$(date +%s)
|
||||||
|
echo "Elapsed Time: $(($end-$start)) seconds"
|
||||||
|
|
||||||
log "Extracting Eigen."
|
log "Extracting Eigen."
|
||||||
|
|
||||||
|
start=$(date +%s)
|
||||||
tar -xzf ${EIGEN_BASENAME}.tar.gz
|
tar -xzf ${EIGEN_BASENAME}.tar.gz
|
||||||
|
end=$(date +%s)
|
||||||
|
echo "Elapsed Time Extracting for Eigen: $(($end-$start)) seconds"
|
||||||
|
|
||||||
mv ${EIGEN_BASENAME} ${EIGEN_SRC_DIR}
|
mv ${EIGEN_BASENAME} ${EIGEN_SRC_DIR}
|
||||||
mkdir -p ${EIGEN_INCLUDE}/unsupported
|
mkdir -p ${EIGEN_INCLUDE}/unsupported
|
||||||
mv ${EIGEN_SRC_DIR}/Eigen ${EIGEN_INCLUDE}
|
mv ${EIGEN_SRC_DIR}/Eigen ${EIGEN_INCLUDE}
|
||||||
|
@ -526,7 +590,10 @@ if ${USE_CHRONO} ; then
|
||||||
log "chrono library already installed."
|
log "chrono library already installed."
|
||||||
else
|
else
|
||||||
log "Retrieving chrono library."
|
log "Retrieving chrono library."
|
||||||
|
start=$(date +%s)
|
||||||
git clone --depth 1 --branch ${CHRONO_TAG} ${CHRONO_REPO} ${CHRONO_SRC_DIR}
|
git clone --depth 1 --branch ${CHRONO_TAG} ${CHRONO_REPO} ${CHRONO_SRC_DIR}
|
||||||
|
end=$(date +%s)
|
||||||
|
echo "Elapsed Time dowloading chrono: $(($end-$start)) seconds"
|
||||||
|
|
||||||
mkdir -p ${CHRONO_SRC_DIR}/build
|
mkdir -p ${CHRONO_SRC_DIR}/build
|
||||||
|
|
||||||
|
@ -573,10 +640,19 @@ if [[ -d ${SQLITE_INSTALL_DIR} ]] ; then
|
||||||
log "Sqlite already installed."
|
log "Sqlite already installed."
|
||||||
else
|
else
|
||||||
log "Retrieving Sqlite3"
|
log "Retrieving Sqlite3"
|
||||||
|
|
||||||
|
start=$(date +%s)
|
||||||
wget ${SQLITE_REPO}
|
wget ${SQLITE_REPO}
|
||||||
|
end=$(date +%s)
|
||||||
|
echo "Elapsed Time: $(($end-$start)) seconds"
|
||||||
|
|
||||||
log "Extracting Sqlite3"
|
log "Extracting Sqlite3"
|
||||||
|
|
||||||
|
start=$(date +%s)
|
||||||
tar -xzf ${SQLITE_TAR}
|
tar -xzf ${SQLITE_TAR}
|
||||||
|
end=$(date +%s)
|
||||||
|
echo "Elapsed Time Extracting for SQlite: $(($end-$start)) seconds"
|
||||||
|
|
||||||
mv ${SQLITE_VERSION} ${SQLITE_SOURCE_DIR}
|
mv ${SQLITE_VERSION} ${SQLITE_SOURCE_DIR}
|
||||||
|
|
||||||
mkdir ${SQLITE_INSTALL_DIR}
|
mkdir ${SQLITE_INSTALL_DIR}
|
||||||
|
@ -620,10 +696,18 @@ if [[ -d ${PROJ_INSTALL_DIR} && -d ${PROJ_INSTALL_SERVER_DIR_FULL} ]] ; then
|
||||||
log "PROJ already installed."
|
log "PROJ already installed."
|
||||||
else
|
else
|
||||||
log "Retrieving PROJ"
|
log "Retrieving PROJ"
|
||||||
|
|
||||||
|
start=$(date +%s)
|
||||||
wget ${PROJ_REPO}
|
wget ${PROJ_REPO}
|
||||||
|
end=$(date +%s)
|
||||||
|
echo "Elapsed Time: $(($end-$start)) seconds"
|
||||||
|
|
||||||
log "Extracting PROJ"
|
log "Extracting PROJ"
|
||||||
|
start=$(date +%s)
|
||||||
tar -xzf ${PROJ_TAR}
|
tar -xzf ${PROJ_TAR}
|
||||||
|
end=$(date +%s)
|
||||||
|
echo "Elapsed Time Extracting for PROJ: $(($end-$start)) seconds"
|
||||||
|
|
||||||
mv ${PROJ_VERSION} ${PROJ_SRC_DIR}
|
mv ${PROJ_VERSION} ${PROJ_SRC_DIR}
|
||||||
|
|
||||||
mkdir -p ${PROJ_SRC_DIR}/build
|
mkdir -p ${PROJ_SRC_DIR}/build
|
||||||
|
@ -691,10 +775,18 @@ if [[ -d ${PATCHELF_INSTALL_DIR} ]] ; then
|
||||||
log "Patchelf already installed."
|
log "Patchelf already installed."
|
||||||
else
|
else
|
||||||
log "Retrieving patchelf"
|
log "Retrieving patchelf"
|
||||||
|
|
||||||
|
start=$(date +%s)
|
||||||
wget ${PATCHELF_REPO}
|
wget ${PATCHELF_REPO}
|
||||||
|
end=$(date +%s)
|
||||||
|
echo "Elapsed Time: $(($end-$start)) seconds"
|
||||||
|
|
||||||
log "Extracting patchelf"
|
log "Extracting patchelf"
|
||||||
|
start=$(date +%s)
|
||||||
tar -xzf ${PATCHELF_TAR}
|
tar -xzf ${PATCHELF_TAR}
|
||||||
|
end=$(date +%s)
|
||||||
|
echo "Elapsed Time Extracting patchelf: $(($end-$start)) seconds"
|
||||||
|
|
||||||
mv patchelf-${PATCHELF_VERSION} ${PATCHELF_SOURCE_DIR}
|
mv patchelf-${PATCHELF_VERSION} ${PATCHELF_SOURCE_DIR}
|
||||||
|
|
||||||
mkdir ${PATCHELF_INSTALL_DIR}
|
mkdir ${PATCHELF_INSTALL_DIR}
|
||||||
|
@ -729,7 +821,12 @@ if ${USE_PYTORCH} ; then
|
||||||
LIBTORCH_ZIPFILE=libtorch-shared-with-deps-1.11.0+cu113.zip
|
LIBTORCH_ZIPFILE=libtorch-shared-with-deps-1.11.0+cu113.zip
|
||||||
LIBTORCH_REPO=https://download.pytorch.org/libtorch/cu113/libtorch-shared-with-deps-1.11.0%2Bcu113.zip
|
LIBTORCH_REPO=https://download.pytorch.org/libtorch/cu113/libtorch-shared-with-deps-1.11.0%2Bcu113.zip
|
||||||
if [[ ! -d ${LIBTORCH_PATH} ]] ; then
|
if [[ ! -d ${LIBTORCH_PATH} ]] ; then
|
||||||
|
|
||||||
|
start=$(date +%s)
|
||||||
wget ${LIBTORCH_REPO}
|
wget ${LIBTORCH_REPO}
|
||||||
|
end=$(date +%s)
|
||||||
|
echo "Elapsed Time downloading LIBTORCH_REPO: $(($end-$start)) seconds"
|
||||||
|
|
||||||
unzip ${LIBTORCH_ZIPFILE}
|
unzip ${LIBTORCH_ZIPFILE}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
@ -809,7 +906,10 @@ if ${USE_ROS2} ; then
|
||||||
if [[ ! -d ${LIB_SOURCE} ]] ; then
|
if [[ ! -d ${LIB_SOURCE} ]] ; then
|
||||||
mkdir -p ${LIB_SOURCE}
|
mkdir -p ${LIB_SOURCE}
|
||||||
log "${LIB_REPO}"
|
log "${LIB_REPO}"
|
||||||
|
start=$(date +%s)
|
||||||
git clone --depth 1 --branch ${LIB_BRANCH} ${LIB_REPO} ${LIB_SOURCE}
|
git clone --depth 1 --branch ${LIB_BRANCH} ${LIB_REPO} ${LIB_SOURCE}
|
||||||
|
end=$(date +%s)
|
||||||
|
echo "Elapsed Time dowloading fastdds extension: $(($end-$start)) seconds"
|
||||||
mkdir -p ${LIB_SOURCE}/build
|
mkdir -p ${LIB_SOURCE}/build
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
|
@ -25,7 +25,7 @@
|
||||||
#
|
#
|
||||||
# You can download it directly from
|
# You can download it directly from
|
||||||
#
|
#
|
||||||
# http://carla-assets.s3.amazonaws.com/PUT_FILE_ID_HERE.tar.gz
|
# http://carla-assets.s3.us-east-005.backblazeb2.com/PUT_FILE_ID_HERE.tar.gz
|
||||||
|
|
||||||
0.9.5: 20190404_c7b464a
|
0.9.5: 20190404_c7b464a
|
||||||
0.9.6: 20190710_0097e66
|
0.9.6: 20190710_0097e66
|
||||||
|
|
|
@ -28,8 +28,8 @@ fi
|
||||||
|
|
||||||
CARLA_VERSION=$1
|
CARLA_VERSION=$1
|
||||||
CARLA_DIR=carla-simulator-${CARLA_VERSION}
|
CARLA_DIR=carla-simulator-${CARLA_VERSION}
|
||||||
CARLA_RELEASE_URL=https://carla-releases.s3.eu-west-3.amazonaws.com/Linux/CARLA_${CARLA_VERSION}.tar.gz
|
CARLA_RELEASE_URL=https://carla-releases.s3.us-east-005.backblazeb2.com/Linux/CARLA_${CARLA_VERSION}.tar.gz
|
||||||
ADDITIONAL_MAPS_URL=https://carla-releases.s3.eu-west-3.amazonaws.com/Linux/AdditionalMaps_${CARLA_VERSION}.tar.gz
|
ADDITIONAL_MAPS_URL=https://carla-releases.s3.us-east-005.backblazeb2.com/Linux/AdditionalMaps_${CARLA_VERSION}.tar.gz
|
||||||
|
|
||||||
# Adding maintainer name.
|
# Adding maintainer name.
|
||||||
DEBFULLNAME=Carla\ Simulator\ Team
|
DEBFULLNAME=Carla\ Simulator\ Team
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
@echo off
|
@echo off
|
||||||
setlocal
|
setlocal enabledelayedexpansion
|
||||||
|
|
||||||
rem BAT script that downloads and installs a ready to use
|
rem BAT script that downloads and installs a ready to use
|
||||||
rem boost build for CARLA (carla.org).
|
rem boost build for CARLA (carla.org).
|
||||||
|
@ -66,12 +66,13 @@ rem -- Local Variables ---------------------------------------------------------
|
||||||
rem ============================================================================
|
rem ============================================================================
|
||||||
|
|
||||||
set BOOST_BASENAME=boost-%BOOST_VERSION%
|
set BOOST_BASENAME=boost-%BOOST_VERSION%
|
||||||
|
set BOOST_SHA256SUM="e34756f63abe8ac34b35352743f17d061fcc825969a2dd8458264edb38781782"
|
||||||
|
|
||||||
set BOOST_TEMP_FOLDER=boost_%BOOST_VERSION:.=_%
|
set BOOST_TEMP_FOLDER=boost_%BOOST_VERSION:.=_%
|
||||||
set BOOST_TEMP_FILE=%BOOST_TEMP_FOLDER%.zip
|
set BOOST_TEMP_FILE=%BOOST_TEMP_FOLDER%.zip
|
||||||
set BOOST_TEMP_FILE_DIR=%BUILD_DIR%%BOOST_TEMP_FILE%
|
set BOOST_TEMP_FILE_DIR=%BUILD_DIR%%BOOST_TEMP_FILE%
|
||||||
|
|
||||||
set BOOST_REPO=https://boostorg.jfrog.io/artifactory/main/release/%BOOST_VERSION%/source/%BOOST_TEMP_FILE%
|
set BOOST_REPO=https://archives.boost.io/release/%BOOST_VERSION%/source/%BOOST_TEMP_FILE%
|
||||||
set BOOST_SRC_DIR=%BUILD_DIR%%BOOST_BASENAME%-source\
|
set BOOST_SRC_DIR=%BUILD_DIR%%BOOST_BASENAME%-source\
|
||||||
set BOOST_INSTALL_DIR=%BUILD_DIR%%BOOST_BASENAME%-install\
|
set BOOST_INSTALL_DIR=%BUILD_DIR%%BOOST_BASENAME%-install\
|
||||||
set BOOST_LIB_DIR=%BOOST_INSTALL_DIR%lib\
|
set BOOST_LIB_DIR=%BOOST_INSTALL_DIR%lib\
|
||||||
|
@ -84,16 +85,20 @@ if exist "%BOOST_INSTALL_DIR%" (
|
||||||
goto already_build
|
goto already_build
|
||||||
)
|
)
|
||||||
|
|
||||||
|
set _checksum=""
|
||||||
|
|
||||||
if not exist "%BOOST_SRC_DIR%" (
|
if not exist "%BOOST_SRC_DIR%" (
|
||||||
if not exist "%BOOST_TEMP_FILE_DIR%" (
|
if not exist "%BOOST_TEMP_FILE_DIR%" (
|
||||||
echo %FILE_N% Retrieving boost.
|
echo %FILE_N% Retrieving boost.
|
||||||
powershell -Command "(New-Object System.Net.WebClient).DownloadFile('%BOOST_REPO%', '%BOOST_TEMP_FILE_DIR%')"
|
powershell -Command "(New-Object System.Net.WebClient).DownloadFile('%BOOST_REPO%', '%BOOST_TEMP_FILE_DIR%')"
|
||||||
|
call :CheckSumEvaluate %BOOST_TEMP_FILE_DIR%,%BOOST_SHA256SUM%,_checksum
|
||||||
)
|
)
|
||||||
if not exist "%BOOST_TEMP_FILE_DIR%" (
|
if "!_checksum!" == "1" (
|
||||||
echo %FILE_N% Using Boost backup
|
echo %FILE_N% Using Boost backup
|
||||||
powershell -Command "(New-Object System.Net.WebClient).DownloadFile('https://carla-releases.s3.eu-west-3.amazonaws.com/Backup/%BOOST_TEMP_FILE%', '%BOOST_TEMP_FILE_DIR%')"
|
powershell -Command "(New-Object System.Net.WebClient).DownloadFile('https://carla-releases.s3.us-east-005.backblazeb2.com/Backup/%BOOST_TEMP_FILE%', '%BOOST_TEMP_FILE_DIR%')"
|
||||||
|
call :CheckSumEvaluate %BOOST_TEMP_FILE_DIR%,%BOOST_SHA256SUM%,_checksum
|
||||||
)
|
)
|
||||||
if %errorlevel% neq 0 goto error_download
|
if "!_checksum!" == "1" goto error_download
|
||||||
echo %FILE_N% Extracting boost from "%BOOST_TEMP_FILE%", this can take a while...
|
echo %FILE_N% Extracting boost from "%BOOST_TEMP_FILE%", this can take a while...
|
||||||
if exist "%ProgramW6432%/7-Zip/7z.exe" (
|
if exist "%ProgramW6432%/7-Zip/7z.exe" (
|
||||||
"%ProgramW6432%/7-Zip/7z.exe" x "%BOOST_TEMP_FILE_DIR%" -o"%BUILD_DIR%" -y
|
"%ProgramW6432%/7-Zip/7z.exe" x "%BOOST_TEMP_FILE_DIR%" -o"%BUILD_DIR%" -y
|
||||||
|
@ -197,3 +202,25 @@ rem ============================================================================
|
||||||
echo %FILE_N% Exiting with error...
|
echo %FILE_N% Exiting with error...
|
||||||
endlocal
|
endlocal
|
||||||
exit /b %errorlevel%
|
exit /b %errorlevel%
|
||||||
|
|
||||||
|
:CheckSumEvaluate
|
||||||
|
set filepath=%1
|
||||||
|
set checksum=%2
|
||||||
|
|
||||||
|
echo %FILE_N% calculating %filepath% checksum...
|
||||||
|
|
||||||
|
set PsCommand="(Get-FileHash %filepath%).Hash -eq '%checksum%'"
|
||||||
|
|
||||||
|
for /f %%F in ('Powershell -C %PsCommand%') do (
|
||||||
|
set filechecksum=%%F
|
||||||
|
)
|
||||||
|
|
||||||
|
if %filechecksum% == True (
|
||||||
|
echo %FILE_N% %filepath% checksum OK
|
||||||
|
set "%~3=0"
|
||||||
|
exit /b 0
|
||||||
|
) else (
|
||||||
|
echo %FILE_N% %filepath% BAD SHA256 checksum
|
||||||
|
set "%~3=1"
|
||||||
|
exit /b 1
|
||||||
|
)
|
|
@ -81,7 +81,7 @@ if not exist "%LIBPNG_SRC_DIR%" (
|
||||||
)
|
)
|
||||||
if not exist "%LIBPNG_TEMP_FILE_DIR%" (
|
if not exist "%LIBPNG_TEMP_FILE_DIR%" (
|
||||||
echo %FILE_N% Using %LIBPNG_BASENAME% from backup.
|
echo %FILE_N% Using %LIBPNG_BASENAME% from backup.
|
||||||
powershell -Command "(New-Object System.Net.WebClient).DownloadFile('https://carla-releases.s3.eu-west-3.amazonaws.com/Backup/libpng-%LIBPNG_VERSION%-src.zip', '%LIBPNG_TEMP_FILE_DIR%')"
|
powershell -Command "(New-Object System.Net.WebClient).DownloadFile('https://carla-releases.s3.us-east-005.backblazeb2.com/Backup/libpng-%LIBPNG_VERSION%-src.zip', '%LIBPNG_TEMP_FILE_DIR%')"
|
||||||
)
|
)
|
||||||
if %errorlevel% neq 0 goto error_download
|
if %errorlevel% neq 0 goto error_download
|
||||||
rem Extract the downloaded library
|
rem Extract the downloaded library
|
||||||
|
|
|
@ -58,7 +58,7 @@ rem ../xerces-c-x.x.x-src.zip
|
||||||
set XERCESC_TEMP_FILE_DIR=%BUILD_DIR%%XERCESC_TEMP_FILE%
|
set XERCESC_TEMP_FILE_DIR=%BUILD_DIR%%XERCESC_TEMP_FILE%
|
||||||
|
|
||||||
set XERCESC_REPO=https://archive.apache.org/dist/xerces/c/3/sources/xerces-c-%XERCESC_VERSION%.zip
|
set XERCESC_REPO=https://archive.apache.org/dist/xerces/c/3/sources/xerces-c-%XERCESC_VERSION%.zip
|
||||||
set XERCESC_BACKUP_REPO=https://carla-releases.s3.eu-west-3.amazonaws.com/Backup/xerces-c-%XERCESC_VERSION%.zip
|
set XERCESC_BACKUP_REPO=https://carla-releases.s3.us-east-005.backblazeb2.com/Backup/xerces-c-%XERCESC_VERSION%.zip
|
||||||
|
|
||||||
rem ../xerces-c-x.x.x-source/
|
rem ../xerces-c-x.x.x-source/
|
||||||
set XERCESC_SRC_DIR=%BUILD_DIR%%XERCESC_BASENAME%-%XERCESC_VERSION%-source\
|
set XERCESC_SRC_DIR=%BUILD_DIR%%XERCESC_BASENAME%-%XERCESC_VERSION%-source\
|
||||||
|
@ -93,7 +93,7 @@ if not exist "%XERCESC_SRC_DIR%" (
|
||||||
del "%XERCESC_TEMP_FILE_DIR%"
|
del "%XERCESC_TEMP_FILE_DIR%"
|
||||||
echo %FILE_N% Removing dir "%BUILD_DIR%manifest"
|
echo %FILE_N% Removing dir "%BUILD_DIR%manifest"
|
||||||
rmdir /s/q "%BUILD_DIR%manifest"
|
rmdir /s/q "%BUILD_DIR%manifest"
|
||||||
|
|
||||||
echo %FILE_N% Renaming dir %XERCESC_TEMP_FOLDER_DIR% to %XERCESC_BASENAME%-%XERCESC_VERSION%-source
|
echo %FILE_N% Renaming dir %XERCESC_TEMP_FOLDER_DIR% to %XERCESC_BASENAME%-%XERCESC_VERSION%-source
|
||||||
rename "%XERCESC_TEMP_FOLDER_DIR%" "%XERCESC_BASENAME%-%XERCESC_VERSION%-source"
|
rename "%XERCESC_TEMP_FOLDER_DIR%" "%XERCESC_BASENAME%-%XERCESC_VERSION%-source"
|
||||||
) else (
|
) else (
|
||||||
|
@ -133,7 +133,7 @@ cmake .. -G %GENERATOR% %PLATFORM%^
|
||||||
"%BUILD_DIR%%XERCESC_BASENAME%-%XERCESC_VERSION%-source"
|
"%BUILD_DIR%%XERCESC_BASENAME%-%XERCESC_VERSION%-source"
|
||||||
if %errorlevel% neq 0 goto error_cmake
|
if %errorlevel% neq 0 goto error_cmake
|
||||||
|
|
||||||
cmake --build . --config Release --target install
|
cmake --build . --config Release --target install
|
||||||
|
|
||||||
goto success
|
goto success
|
||||||
|
|
||||||
|
|
|
@ -55,7 +55,7 @@ set ZLIB_TEMP_FILE=%ZLIB_TEMP_FOLDER%.zip
|
||||||
set ZLIB_TEMP_FILE_DIR=%BUILD_DIR%%ZLIB_TEMP_FILE%
|
set ZLIB_TEMP_FILE_DIR=%BUILD_DIR%%ZLIB_TEMP_FILE%
|
||||||
|
|
||||||
set ZLIB_REPO=https://www.zlib.net/zlib%ZLIB_VERSION:.=%.zip
|
set ZLIB_REPO=https://www.zlib.net/zlib%ZLIB_VERSION:.=%.zip
|
||||||
set ZLIB_BACKUP_REPO=https://carla-releases.s3.eu-west-3.amazonaws.com/Backup/zlib%ZLIB_VERSION:.=%.zip
|
set ZLIB_BACKUP_REPO=https://carla-releases.s3.us-east-005.backblazeb2.com/Backup/zlib%ZLIB_VERSION:.=%.zip
|
||||||
set ZLIB_SRC_DIR=%BUILD_DIR%%ZLIB_BASENAME%-source\
|
set ZLIB_SRC_DIR=%BUILD_DIR%%ZLIB_BASENAME%-source\
|
||||||
set ZLIB_INSTALL_DIR=%BUILD_DIR%%ZLIB_BASENAME%-install\
|
set ZLIB_INSTALL_DIR=%BUILD_DIR%%ZLIB_BASENAME%-install\
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue