A sensor to register collisions. More...
#include <ObstacleDetectionSensor.h>
Public Member Functions | |
AObstacleDetectionSensor (const FObjectInitializer &ObjectInitializer) | |
virtual void | PostPhysTick (UWorld *World, ELevelTick TickType, float DeltaSeconds) override |
void | Set (const FActorDescription &Description) override |
![]() | |
ASensor (const FObjectInitializer &ObjectInitializer) | |
virtual void | BeginPlay () |
URandomEngine * | GetRandomEngine () |
int32 | GetSeed () const |
auto | GetToken () const |
Return the token that allows subscribing to this sensor's stream. More... | |
FDataStream | MoveDataStream () |
virtual void | PrePhysTick (float DeltaSeconds) |
void | SetDataStream (FDataStream InStream) |
Replace the FDataStream associated with this sensor. More... | |
void | SetEpisode (const UCarlaEpisode &InEpisode) |
void | SetSeed (int32 InSeed) |
void | Tick (const float DeltaTime) final |
Static Public Member Functions | |
static FActorDefinition | GetSensorDefinition () |
Private Member Functions | |
void | OnObstacleDetectionEvent (AActor *Actor, AActor *OtherActor, float Distance, const FHitResult &Hit) |
Private Attributes | |
bool | bDebugLineTrace = false |
bool | bOnlyDynamics = false |
float | Distance |
float | HitRadius |
Additional Inherited Members | |
![]() | |
void | EndPlay (EEndPlayReason::Type EndPlayReason) override |
template<typename SensorT > | |
FAsyncDataStream | GetDataStream (const SensorT &Self) |
Return the FDataStream associated with this sensor. More... | |
const UCarlaEpisode & | GetEpisode () const |
void | PostActorCreated () override |
![]() | |
URandomEngine * | RandomEngine = nullptr |
Random Engine used to provide noise for sensor output. More... | |
int32 | Seed = 123456789 |
Seed of the pseudo-random engine. More... | |
A sensor to register collisions.
Definition at line 18 of file ObstacleDetectionSensor.h.
AObstacleDetectionSensor::AObstacleDetectionSensor | ( | const FObjectInitializer & | ObjectInitializer | ) |
Definition at line 16 of file ObstacleDetectionSensor.cpp.
|
static |
Definition at line 22 of file ObstacleDetectionSensor.cpp.
References UActorBlueprintFunctionLibrary::MakeObstacleDetectorDefinitions().
|
private |
Definition at line 129 of file ObstacleDetectionSensor.cpp.
References ASensor::Episode, ASensor::GetDataStream(), ASensor::GetEpisode(), FAsyncDataStreamTmpl< T >::Send(), and UCarlaEpisode::SerializeActor().
Referenced by PostPhysTick().
|
overridevirtual |
Reimplemented from ASensor.
Definition at line 53 of file ObstacleDetectionSensor.cpp.
References bDebugLineTrace, bOnlyDynamics, Distance, HitRadius, and OnObstacleDetectionEvent().
|
overridevirtual |
Reimplemented from ASensor.
Definition at line 29 of file ObstacleDetectionSensor.cpp.
References bDebugLineTrace, bOnlyDynamics, Distance, HitRadius, UActorBlueprintFunctionLibrary::RetrieveActorAttributeToBool(), UActorBlueprintFunctionLibrary::RetrieveActorAttributeToFloat(), and FActorDescription::Variations.
|
private |
Definition at line 49 of file ObstacleDetectionSensor.h.
Referenced by PostPhysTick(), and Set().
|
private |
Definition at line 47 of file ObstacleDetectionSensor.h.
Referenced by PostPhysTick(), and Set().
|
private |
Definition at line 43 of file ObstacleDetectionSensor.h.
Referenced by PostPhysTick(), and Set().
|
private |
Definition at line 45 of file ObstacleDetectionSensor.h.
Referenced by PostPhysTick(), and Set().