You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
Before: 3548 unity files Total CPU Time: 47343.578125 s Total time in Parallel executor: 494.60 seconds After: 3445 unity files Total CPU Time: 46044.671875 s Total time in Parallel executor: 468.51 seconds #jira #preflight 63336159b20e73a098b7f24f [CL 22218213 by bryan sefcik in ue5-main branch]
45 lines
1.3 KiB
C++
45 lines
1.3 KiB
C++
// Copyright Epic Games, Inc. All Rights Reserved.
|
|
|
|
#include "SmartObjectDebugRenderingComponent.h"
|
|
#include "SmartObjectDebugSceneProxy.h"
|
|
#include "Debug/DebugDrawService.h"
|
|
|
|
#include UE_INLINE_GENERATED_CPP_BY_NAME(SmartObjectDebugRenderingComponent)
|
|
|
|
USmartObjectDebugRenderingComponent::USmartObjectDebugRenderingComponent(const FObjectInitializer& ObjectInitialize)
|
|
: Super(ObjectInitialize)
|
|
{
|
|
#if WITH_EDITORONLY_DATA
|
|
HitProxyPriority = HPP_Wireframe;
|
|
#endif
|
|
}
|
|
|
|
#if UE_ENABLE_DEBUG_DRAWING
|
|
void USmartObjectDebugRenderingComponent::OnRegister()
|
|
{
|
|
Super::OnRegister();
|
|
|
|
if (!HasAnyFlags(RF_ClassDefaultObject))
|
|
{
|
|
CanvasDebugDrawDelegateHandle = UDebugDrawService::Register(TEXT("Game"), FDebugDrawDelegate::CreateUObject(this, &USmartObjectDebugRenderingComponent::DebugDrawCanvas));
|
|
}
|
|
}
|
|
|
|
void USmartObjectDebugRenderingComponent::OnUnregister()
|
|
{
|
|
if (!HasAnyFlags(RF_ClassDefaultObject))
|
|
{
|
|
UDebugDrawService::Unregister(CanvasDebugDrawDelegateHandle);
|
|
}
|
|
|
|
Super::OnUnregister();
|
|
}
|
|
|
|
FDebugRenderSceneProxy* USmartObjectDebugRenderingComponent::CreateDebugSceneProxy()
|
|
{
|
|
FSmartObjectDebugSceneProxy* DebugProxy = new FSmartObjectDebugSceneProxy(*this, FDebugRenderSceneProxy::WireMesh, *ViewFlagName);
|
|
DebugDraw(DebugProxy);
|
|
return DebugProxy;
|
|
}
|
|
#endif // UE_ENABLE_DEBUG_DRAWING
|