UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
DataflowDebugDraw.h
Go to the documentation of this file.
1// Copyright Epic Games, Inc. All Rights Reserved.
2
3#pragma once
4
8#include "Math/Color.h"
13
14#include "DataflowDebugDraw.generated.h"
15
17
19{
20public:
21
23
24 virtual ~FDataflowDebugDraw() = default;
25
26private:
27
28 virtual void SetColor(const FLinearColor& InColor) override;
29 virtual void SetPointSize(float Size) override;
30 virtual void SetLineWidth(double Width) override;
31 virtual void SetWireframe(bool bInWireframe) override;
32 virtual void SetShaded(bool bInShaded) override;
33 virtual void SetTranslucent(bool bInShadedTranslucent) override;
34 virtual void SetForegroundPriority() override;
35 virtual void SetWorldPriority() override;
36 virtual void ResetAllState() override;
37
38 virtual void ReservePoints(int32 NumAdditionalPoints) override;
39 virtual void DrawObject(const TRefCountPtr<IDataflowDebugDrawObject>& Object) override;
40 virtual void DrawPoint(const FVector& Position) override;
41 virtual void DrawLine(const FVector& Start, const FVector& End) const override;
42 virtual void DrawMesh(const IDebugDrawMesh& Mesh) const override;
43
44 virtual void DrawBox(const FVector& Extents, const FQuat& Rotation, const FVector& Center, double UniformScale) const override;
45 virtual void DrawSphere(const FVector& Center, double Radius) const override;
46 virtual void DrawCapsule(const FVector& Center, const double& Radius, const double& HalfHeight, const FVector& XAxis, const FVector& YAxis, const FVector &ZAxis) const override;
47 virtual void DrawText3d(const FString& String, const FVector& Location) const override;
48
49 virtual void DrawOverlayText(const FString& InString) override;
50 virtual FString GetOverlayText() const override;
51
53 virtual IDataflowDebugDrawInterface::FDataflowElementsType& ModifyDataflowElements() { return DataflowElements; }
54
56 virtual const IDataflowDebugDrawInterface::FDataflowElementsType& GetDataflowElements() const { return DataflowElements; }
57
59 class FDataflowDebugRenderSceneProxy* DebugRenderSceneProxy = nullptr;
60
63
65 double LineWidth = 1.0;
66 float PointSize = 5.0;
67 bool bWireframe = true;
68 bool bShaded = false;
69 bool bTranslucent = false;
71
72 FLinearColor ColorWithTranslucency = FLinearColor::White;
74
75 TArray<FString> OverlayStrings;
76};
77
78UENUM(BlueprintType)
80{
81 Wireframe UMETA(DisplayName = "Wireframe"),
82 Shaded UMETA(DisplayName = "Shaded"),
83};
84
88USTRUCT()
90{
92
93 UPROPERTY(EditAnywhere, Category = "Debug Draw")
95
96 UPROPERTY(EditAnywhere, Category = "Debug Draw", meta = (EditCondition = "RenderType==EDataflowDebugDrawRenderType::Shaded", EditConditionHides));
97 bool bTranslucent = true;
98
99 UPROPERTY(EditAnywhere, Category = "Debug Draw");
101
102 UPROPERTY(EditAnywhere, Category = "Debug Draw", meta = (ClampMin = "0.1", ClampMax = "10.0"));
103 float LineWidthMultiplier = 1.f;
104
106};
107
111UENUM(BlueprintType)
113{
114 Single UMETA(DisplayName = "Single Color"),
115 ColorByRadius UMETA(DisplayName = "Color by Radius"),
116 Random UMETA(DisplayName = "Random Colors"),
117};
118
119USTRUCT()
121{
123
124
125 UPROPERTY(EditAnywhere, Category = "Debug Draw - Sphere Covering")
126 bool bDisplaySphereCovering = false;
127
128 UPROPERTY(EditAnywhere, Category = "Debug Draw - Sphere Covering")
130
131 UPROPERTY(EditAnywhere, Category = "Debug Draw - Sphere Covering", meta = (EditCondition = "RenderType==EDataflowDebugDrawRenderType::Shaded", EditConditionHides));
132 bool bTranslucent = true;
133
134 UPROPERTY(EditAnywhere, Category = "Debug Draw - Sphere Covering", meta = (ClampMin = "0.1", ClampMax = "10.0"));
135 float LineWidthMultiplier = .25f;
136
137 UPROPERTY(EditAnywhere, Category = "Debug Draw - Sphere Covering");
139
140 UPROPERTY(EditAnywhere, Category = "Debug Draw - Sphere Covering", meta = (EditCondition = "ColorMethod == EDataflowSphereCoveringColorMethod::Single", EditConditionHides));
142
144 UPROPERTY(EditAnywhere, Category = "Debug Draw - Sphere Covering", meta = (ClampMin = "0", EditCondition = "ColorMethod == EDataflowSphereCoveringColorMethod::Random", EditConditionHides))
145 int32 ColorRandomSeed = 0;
146
147 UPROPERTY(EditAnywhere, Category = "Debug Draw - Sphere Covering", meta = (EditCondition = "ColorMethod == EDataflowSphereCoveringColorMethod::ColorByRadius", EditConditionHides));
149
150 UPROPERTY(EditAnywhere, Category = "Debug Draw - Sphere Covering", meta = (EditCondition = "ColorMethod == EDataflowSphereCoveringColorMethod::ColorByRadius", EditConditionHides));
152};
153
155{
156 DataflowRenderingInterface.SetShaded(false);
157 DataflowRenderingInterface.SetWireframe(true);
158}
159
161{
162 DataflowRenderingInterface.SetShaded(true);
163 DataflowRenderingInterface.SetWireframe(true);
164}
165
166
FPlatformTypes::int32 int32
A 32-bit signed integer.
Definition Platform.h:1125
UE_FORCEINLINE_HINT TSharedRef< CastToType, Mode > StaticCastSharedRef(TSharedRef< CastFromType, Mode > const &InSharedRef)
Definition SharedPointer.h:127
EDataflowSphereCoveringColorMethod
Definition DataflowDebugDraw.h:113
EDataflowDebugDrawRenderType
Definition DataflowDebugDraw.h:80
ESceneDepthPriorityGroup
Definition EngineTypes.h:187
@ SDPG_World
Definition EngineTypes.h:189
return true
Definition ExternalRpcRegistry.cpp:601
const bool
Definition NetworkReplayStreaming.h:178
#define UPROPERTY(...)
UObject definition macros.
Definition ObjectMacros.h:744
#define UENUM(...)
Definition ObjectMacros.h:749
#define USTRUCT(...)
Definition ObjectMacros.h:746
#define GENERATED_USTRUCT_BODY(...)
Definition ObjectMacros.h:767
uint32 Size
Definition VulkanMemory.cpp:4034
uint8_t uint8
Definition binka_ue_file_header.h:8
Definition DataflowDebugDraw.h:19
virtual ~FDataflowDebugDraw()=default
Definition DataflowDebugDrawComponent.h:22
EDrawType
Definition DebugRenderSceneProxy.h:48
@ Invalid
Definition DebugRenderSceneProxy.h:52
Definition DataflowDebugDrawInterface.h:23
Definition Array.h:670
Definition RefCounting.h:454
@ false
Definition radaudio_common.h:23
Definition DataflowElement.h:12
Definition DataflowDebugDraw.h:90
Definition DataflowDebugDraw.h:121
Definition Color.h:48
static CORE_API const FLinearColor White
Definition Color.h:456
Definition DataflowDebugDrawInterface.h:48