add new documentation for newly added APIs for controlling lights and textures
This commit is contained in:
zimmy87 2021-11-16 13:30:33 -08:00 коммит произвёл GitHub
Родитель e692a6f81d
Коммит f1894e1feb
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4AEE18F83AFDEB23
1 изменённых файлов: 13 добавлений и 0 удалений

Просмотреть файл

@ -217,6 +217,19 @@ AirSim offers API to retrieve point cloud data from Lidar sensors on vehicles. Y
More on [lidar APIs and settings](lidar.md) and [sensor settings](sensors.md)
### Light Control APIs
Lights that can be manipulated inside AirSim can be created via the `simSpawnObject()` API by passing either `PointLightBP` or `SpotLightBP` as the `asset_name` parameter and `True` as the `is_blueprint` parameter. Once a light has been spawned, it can be manipulated using the following API:
* `simSetLightIntensity`: This allows you to edit a light's intensity or brightness. It takes two parameters, `light_name`, the name of the light object returned by a previous call to `simSpawnObject()`, and `intensity`, a float value.
### Texture APIs
Textures can be dynamically set on objects via these APIs:
* `simSetObjectMaterial`: This sets an object's material using an existing Unreal material asset. It takes two string parameters, `object_name` and `material_name`.
* `simSetObjectMaterialFromTexture`: This sets an object's material using a path to a texture. It takes two string parameters, `object_name` and `texture_path`.
### Multiple Vehicles
AirSim supports multiple vehicles and control them through APIs. Please [Multiple Vehicles](multi_vehicle.md) doc.