CARLA
Loading...
Searching...
No Matches
TaggerDelegate.h
Go to the documentation of this file.
1// Copyright (c) 2026 Computer Vision Center (CVC) at the Universitat Autonoma
2// de Barcelona (UAB).
3//
4// This work is licensed under the terms of the MIT license.
5// For a copy, see <https://opensource.org/licenses/MIT>.
6
7#pragma once
8
9#include <util/ue-header-guard-begin.h>
10#include "Engine/World.h"
11#include <util/ue-header-guard-end.h>
12
13#include "TaggerDelegate.generated.h"
14
15/// Used to tag every actor that is spawned into the world.
16UCLASS()
17class CARLA_API UTaggerDelegate : public UObject
18{
19 GENERATED_BODY()
20
21public:
22
24
25 void RegisterSpawnHandler(UWorld *World);
26
27 void SetSemanticSegmentationEnabled(bool Enable = true)
28 {
29 bSemanticSegmentationEnabled = Enable;
30 }
31
32 void OnActorSpawned(AActor *Actor);
33
34private:
35
36 FOnActorSpawned::FDelegate ActorSpawnedDelegate;
37
38 bool bSemanticSegmentationEnabled = false;
39};
Used to tag every actor that is spawned into the world.
FOnActorSpawned::FDelegate ActorSpawnedDelegate
void SetSemanticSegmentationEnabled(bool Enable=true)