2019-12-26 15:33:43 -05:00
|
|
|
// Copyright Epic Games, Inc. All Rights Reserved.
|
2014-11-14 18:23:41 -05:00
|
|
|
|
|
|
|
|
#include "AnimGraphConnectionDrawingPolicy.h"
|
2022-08-30 23:03:03 -04:00
|
|
|
|
|
|
|
|
#include "AnimGraphAttributes.h"
|
|
|
|
|
#include "AnimGraphNode_Base.h"
|
Copying //UE4/Dev-Build to //UE4/Dev-Main (Source: //UE4/Dev-Build @ 3209340)
#lockdown Nick.Penwarden
#rb none
==========================
MAJOR FEATURES + CHANGES
==========================
Change 3209340 on 2016/11/23 by Ben.Marsh
Convert UE4 codebase to an "include what you use" model - where every header just includes the dependencies it needs, rather than every source file including large monolithic headers like Engine.h and UnrealEd.h.
Measured full rebuild times around 2x faster using XGE on Windows, and improvements of 25% or more for incremental builds and full rebuilds on most other platforms.
* Every header now includes everything it needs to compile.
* There's a CoreMinimal.h header that gets you a set of ubiquitous types from Core (eg. FString, FName, TArray, FVector, etc...). Most headers now include this first.
* There's a CoreTypes.h header that sets up primitive UE4 types and build macros (int32, PLATFORM_WIN64, etc...). All headers in Core include this first, as does CoreMinimal.h.
* Every .cpp file includes its matching .h file first.
* This helps validate that each header is including everything it needs to compile.
* No engine code includes a monolithic header such as Engine.h or UnrealEd.h any more.
* You will get a warning if you try to include one of these from the engine. They still exist for compatibility with game projects and do not produce warnings when included there.
* There have only been minor changes to our internal games down to accommodate these changes. The intent is for this to be as seamless as possible.
* No engine code explicitly includes a precompiled header any more.
* We still use PCHs, but they're force-included on the compiler command line by UnrealBuildTool instead. This lets us tune what they contain without breaking any existing include dependencies.
* PCHs are generated by a tool to get a statistical amount of coverage for the source files using it, and I've seeded the new shared PCHs to contain any header included by > 15% of source files.
Tool used to generate this transform is at Engine\Source\Programs\IncludeTool.
[CL 3209342 by Ben Marsh in Main branch]
2016-11-23 15:48:37 -05:00
|
|
|
#include "Animation/AnimBlueprint.h"
|
|
|
|
|
#include "Animation/AnimBlueprintGeneratedClass.h"
|
2014-11-14 18:23:41 -05:00
|
|
|
#include "AnimationGraphSchema.h"
|
2021-01-06 09:11:59 -04:00
|
|
|
#include "AnimationPins/SGraphPinPose.h"
|
2022-08-30 23:03:03 -04:00
|
|
|
#include "ConnectionDrawingPolicy.h"
|
|
|
|
|
#include "Containers/Array.h"
|
|
|
|
|
#include "Containers/EnumAsByte.h"
|
|
|
|
|
#include "Containers/Set.h"
|
|
|
|
|
#include "EdGraph/EdGraphNode.h"
|
|
|
|
|
#include "EdGraph/EdGraphPin.h"
|
|
|
|
|
#include "Engine/Blueprint.h"
|
2022-05-19 07:05:17 -04:00
|
|
|
#include "K2Node_Knot.h"
|
2022-08-30 23:03:03 -04:00
|
|
|
#include "Kismet2/BlueprintEditorUtils.h"
|
|
|
|
|
#include "Math/Color.h"
|
|
|
|
|
#include "Math/Range.h"
|
|
|
|
|
#include "Math/UnrealMathSSE.h"
|
|
|
|
|
#include "Misc/AssertionMacros.h"
|
|
|
|
|
#include "Rendering/DrawElements.h"
|
|
|
|
|
#include "Rendering/RenderingCommon.h"
|
|
|
|
|
#include "SGraphPin.h"
|
|
|
|
|
#include "Templates/Casts.h"
|
|
|
|
|
#include "Templates/SubclassOf.h"
|
|
|
|
|
#include "UObject/NameTypes.h"
|
|
|
|
|
#include "UObject/UObjectGlobals.h"
|
|
|
|
|
|
|
|
|
|
class FArrangedWidget;
|
|
|
|
|
class FSlateRect;
|
|
|
|
|
class SWidget;
|
2014-11-14 18:23:41 -05:00
|
|
|
|
|
|
|
|
/////////////////////////////////////////////////////
|
|
|
|
|
// FAnimGraphConnectionDrawingPolicy
|
|
|
|
|
|
|
|
|
|
FAnimGraphConnectionDrawingPolicy::FAnimGraphConnectionDrawingPolicy(int32 InBackLayerID, int32 InFrontLayerID, float ZoomFactor, const FSlateRect& InClippingRect, FSlateWindowElementList& InDrawElements, UEdGraph* InGraphObj)
|
|
|
|
|
: FKismetConnectionDrawingPolicy(InBackLayerID, InFrontLayerID, ZoomFactor, InClippingRect, InDrawElements, InGraphObj)
|
|
|
|
|
{
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
bool FAnimGraphConnectionDrawingPolicy::TreatWireAsExecutionPin(UEdGraphPin* InputPin, UEdGraphPin* OutputPin) const
|
|
|
|
|
{
|
|
|
|
|
const UAnimationGraphSchema* Schema = GetDefault<UAnimationGraphSchema>();
|
|
|
|
|
|
|
|
|
|
return (InputPin != NULL) && (Schema->IsPosePin(OutputPin->PinType));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void FAnimGraphConnectionDrawingPolicy::BuildExecutionRoadmap()
|
|
|
|
|
{
|
2019-10-21 10:15:56 -04:00
|
|
|
if(UAnimBlueprint* TargetBP = Cast<UAnimBlueprint>(FBlueprintEditorUtils::FindBlueprintForGraph(GraphObj)))
|
2014-11-14 18:23:41 -05:00
|
|
|
{
|
2021-01-06 09:11:59 -04:00
|
|
|
UAnimBlueprintGeneratedClass* AnimBlueprintClass = (UAnimBlueprintGeneratedClass*)(*(TargetBP->GeneratedClass));
|
2014-11-14 18:23:41 -05:00
|
|
|
|
2021-01-06 09:11:59 -04:00
|
|
|
if (TargetBP->GetObjectBeingDebugged() == NULL)
|
2014-11-14 18:23:41 -05:00
|
|
|
{
|
2021-01-06 09:11:59 -04:00
|
|
|
return;
|
|
|
|
|
}
|
2021-10-12 21:21:22 -04:00
|
|
|
|
2021-01-06 09:11:59 -04:00
|
|
|
FAnimBlueprintDebugData& DebugInfo = AnimBlueprintClass->GetAnimBlueprintDebugData();
|
|
|
|
|
for (auto VisitIt = DebugInfo.UpdatedNodesThisFrame.CreateIterator(); VisitIt; ++VisitIt)
|
|
|
|
|
{
|
|
|
|
|
const FAnimBlueprintDebugData::FNodeVisit& VisitRecord = *VisitIt;
|
|
|
|
|
|
2021-10-12 21:21:22 -04:00
|
|
|
const int32 NumAnimNodeProperties = AnimBlueprintClass->GetAnimNodeProperties().Num();
|
|
|
|
|
if ((VisitRecord.SourceID >= 0) && (VisitRecord.SourceID < NumAnimNodeProperties) && (VisitRecord.TargetID >= 0) && (VisitRecord.TargetID < NumAnimNodeProperties))
|
2014-11-14 18:23:41 -05:00
|
|
|
{
|
2021-10-12 21:21:22 -04:00
|
|
|
const int32 ReverseSourceID = NumAnimNodeProperties - 1 - VisitRecord.SourceID;
|
|
|
|
|
const int32 ReverseTargetID = NumAnimNodeProperties - 1 - VisitRecord.TargetID;
|
|
|
|
|
|
|
|
|
|
if (const UAnimGraphNode_Base* SourceNode = Cast<const UAnimGraphNode_Base>(DebugInfo.NodePropertyIndexToNodeMap.FindRef(ReverseSourceID)))
|
2014-11-14 18:23:41 -05:00
|
|
|
{
|
2021-10-12 21:21:22 -04:00
|
|
|
if (const UAnimGraphNode_Base* TargetNode = Cast<const UAnimGraphNode_Base>(DebugInfo.NodePropertyIndexToNodeMap.FindRef(ReverseTargetID)))
|
2014-11-14 18:23:41 -05:00
|
|
|
{
|
2021-01-06 09:11:59 -04:00
|
|
|
UEdGraphPin* PoseNet = NULL;
|
|
|
|
|
|
|
|
|
|
UAnimationGraphSchema const* AnimSchema = GetDefault<UAnimationGraphSchema>();
|
|
|
|
|
for (int32 PinIndex = 0; PinIndex < TargetNode->Pins.Num(); ++PinIndex)
|
2014-11-14 18:23:41 -05:00
|
|
|
{
|
2021-01-06 09:11:59 -04:00
|
|
|
UEdGraphPin* Pin = TargetNode->Pins[PinIndex];
|
|
|
|
|
check(Pin);
|
|
|
|
|
if (AnimSchema->IsPosePin(Pin->PinType) && (Pin->Direction == EGPD_Output))
|
|
|
|
|
{
|
|
|
|
|
PoseNet = Pin;
|
|
|
|
|
break;
|
|
|
|
|
}
|
2014-11-14 18:23:41 -05:00
|
|
|
}
|
|
|
|
|
|
2021-01-06 09:11:59 -04:00
|
|
|
if (PoseNet != NULL)
|
|
|
|
|
{
|
|
|
|
|
//@TODO: Extend the rendering code to allow using the recorded blend weight instead of faked exec times
|
|
|
|
|
FExecPairingMap& Predecessors = PredecessorPins.FindOrAdd((UEdGraphNode*)SourceNode);
|
|
|
|
|
FTimePair& Timings = Predecessors.FindOrAdd(PoseNet);
|
|
|
|
|
Timings.PredExecTime = 0.0;
|
|
|
|
|
Timings.ThisExecTime = FMath::Clamp(VisitRecord.Weight, 0.f, 1.f);
|
|
|
|
|
}
|
2014-11-14 18:23:41 -05:00
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
2021-01-06 09:11:59 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void FAnimGraphConnectionDrawingPolicy::BuildPinToPinWidgetMap(TMap<TSharedRef<SWidget>, FArrangedWidget>& InPinGeometries)
|
|
|
|
|
{
|
|
|
|
|
FKismetConnectionDrawingPolicy::BuildPinToPinWidgetMap(InPinGeometries);
|
|
|
|
|
|
|
|
|
|
// Cache additional attributes
|
|
|
|
|
PinAttributes.Reset();
|
|
|
|
|
bool bFoundPanelZoom = false;
|
|
|
|
|
PanelZoom = 1.0f;
|
|
|
|
|
|
|
|
|
|
for(const TPair<UEdGraphPin*, TSharedPtr<SGraphPin>>& PinWidgetPair : PinToPinWidgetMap)
|
|
|
|
|
{
|
|
|
|
|
if(PinWidgetPair.Key->Direction == EGPD_Output && UAnimationGraphSchema::IsPosePin(PinWidgetPair.Key->PinType) && PinWidgetPair.Key->GetOwningNode()->IsA<UAnimGraphNode_Base>())
|
|
|
|
|
{
|
|
|
|
|
// Pose pins are assumed to be SGraphPinPose widgets here
|
|
|
|
|
check(PinWidgetPair.Value->GetType() == TEXT("SGraphPinPose"));
|
|
|
|
|
TSharedPtr<SGraphPinPose> PosePin = StaticCastSharedPtr<SGraphPinPose>(PinWidgetPair.Value);
|
|
|
|
|
|
|
|
|
|
PinAttributes.Add(PinWidgetPair.Key, PosePin->GetAttributeInfo());
|
|
|
|
|
|
|
|
|
|
if(!bFoundPanelZoom)
|
|
|
|
|
{
|
|
|
|
|
PanelZoom = PosePin->GetZoomAmount();
|
|
|
|
|
bFoundPanelZoom = true;
|
|
|
|
|
}
|
|
|
|
|
}
|
2019-12-13 11:07:03 -05:00
|
|
|
}
|
2014-11-14 18:23:41 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void FAnimGraphConnectionDrawingPolicy::DetermineStyleOfExecWire(float& Thickness, FLinearColor& WireColor, bool& bDrawBubbles, const FTimePair& Times)
|
|
|
|
|
{
|
|
|
|
|
// It's a followed link, make it strong and yellowish but fading over time
|
|
|
|
|
const double BlendWeight = Times.ThisExecTime;
|
|
|
|
|
|
|
|
|
|
const float HeavyBlendThickness = AttackWireThickness;
|
|
|
|
|
const float LightBlendThickness = SustainWireThickness;
|
|
|
|
|
|
|
|
|
|
Thickness = FMath::Lerp<float>(LightBlendThickness, HeavyBlendThickness, BlendWeight);
|
2022-10-14 06:28:36 -04:00
|
|
|
WireColor = WireColor * static_cast<float>(BlendWeight * 0.5 + 0.5);//FMath::Lerp<FLinearColor>(SustainColor, AttackColor, BlendWeight);
|
2014-11-14 18:23:41 -05:00
|
|
|
|
|
|
|
|
bDrawBubbles = true;
|
|
|
|
|
}
|
|
|
|
|
|
2021-01-06 09:11:59 -04:00
|
|
|
void FAnimGraphConnectionDrawingPolicy::DrawConnection(int32 LayerId, const FVector2D& Start, const FVector2D& End, const FConnectionParams& Params)
|
|
|
|
|
{
|
|
|
|
|
bool bCompositeWire = false;
|
|
|
|
|
|
|
|
|
|
// Pose pins display attribute links
|
|
|
|
|
if(Params.AssociatedPin1 && Params.AssociatedPin2)
|
|
|
|
|
{
|
|
|
|
|
if(UAnimationGraphSchema::IsPosePin(Params.AssociatedPin1->PinType))
|
|
|
|
|
{
|
2022-05-19 07:05:17 -04:00
|
|
|
// If either pin connects to a re-route (knot) node, traverse the link until a relevant pin is found
|
|
|
|
|
UEdGraphPin* UsePin1 = Params.AssociatedPin1;
|
|
|
|
|
if (Params.AssociatedPin1->GetOwningNode()->IsA<UK2Node_Knot>())
|
2021-01-06 09:11:59 -04:00
|
|
|
{
|
2022-05-19 07:05:17 -04:00
|
|
|
UsePin1 = FBlueprintEditorUtils::FindFirstCompilerRelevantLinkedPin(Params.AssociatedPin1);
|
|
|
|
|
}
|
2021-01-06 09:11:59 -04:00
|
|
|
|
2022-05-19 07:05:17 -04:00
|
|
|
UEdGraphPin* UsePin2 = Params.AssociatedPin2;
|
|
|
|
|
if (Params.AssociatedPin2->GetOwningNode()->IsA<UK2Node_Knot>())
|
|
|
|
|
{
|
|
|
|
|
UsePin2 = FBlueprintEditorUtils::FindFirstCompilerRelevantLinkedPin(Params.AssociatedPin2);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (UsePin1 && UsePin2)
|
|
|
|
|
{
|
|
|
|
|
UAnimGraphNode_Base* Node1 = Cast<UAnimGraphNode_Base>(UsePin1->GetOwningNode());
|
|
|
|
|
UAnimGraphNode_Base* Node2 = Cast<UAnimGraphNode_Base>(UsePin2->GetOwningNode());
|
|
|
|
|
if (Node1 && Node2)
|
2021-01-06 09:11:59 -04:00
|
|
|
{
|
2022-05-19 07:05:17 -04:00
|
|
|
const TArrayView<const SGraphPinPose::FAttributeInfo>& AdditionalAttributeInfo = PinAttributes.FindRef(UsePin1);
|
2021-01-06 09:11:59 -04:00
|
|
|
|
2022-05-19 07:05:17 -04:00
|
|
|
if (AdditionalAttributeInfo.Num() > 0)
|
2021-01-06 09:11:59 -04:00
|
|
|
{
|
2022-05-19 07:05:17 -04:00
|
|
|
const float MaxAttributeWireThickness = 3.0f;
|
|
|
|
|
const float MinAttributeWireThickness = 1.0f;
|
|
|
|
|
const float MaxWireGap = 2.0f;
|
|
|
|
|
const float MinWireGap = 0.5f;
|
2021-01-06 09:11:59 -04:00
|
|
|
|
2022-05-19 07:05:17 -04:00
|
|
|
// 0.375f is the zoom level before the 'low LOD' cutoff
|
|
|
|
|
const float ZoomLevelAlpha = FMath::GetMappedRangeValueClamped(TRange<float>(0.375f, 1.0f), TRange<float>(0.0f, 1.0f), PanelZoom);
|
|
|
|
|
const float AttributeWireThickness = FMath::Lerp(MinAttributeWireThickness, MaxAttributeWireThickness, ZoomLevelAlpha);
|
|
|
|
|
const float WireGap = FMath::Lerp(MinWireGap, MaxWireGap, ZoomLevelAlpha);
|
2021-01-06 09:11:59 -04:00
|
|
|
|
2022-05-19 07:05:17 -04:00
|
|
|
const FVector2D& P0 = Start;
|
|
|
|
|
const FVector2D& P1 = End;
|
2021-01-06 09:11:59 -04:00
|
|
|
|
2022-05-19 07:05:17 -04:00
|
|
|
const FVector2D SplineTangent = ComputeSplineTangent(P0, P1);
|
|
|
|
|
const FVector2D P0Tangent = (Params.StartDirection == EGPD_Output) ? SplineTangent : -SplineTangent;
|
|
|
|
|
const FVector2D P1Tangent = (Params.EndDirection == EGPD_Input) ? SplineTangent : -SplineTangent;
|
2021-01-06 09:11:59 -04:00
|
|
|
|
2022-05-19 07:05:17 -04:00
|
|
|
bCompositeWire = true;
|
2021-01-06 09:11:59 -04:00
|
|
|
|
2022-05-19 07:05:17 -04:00
|
|
|
float TotalThickness = Params.WireThickness;
|
2021-01-06 09:11:59 -04:00
|
|
|
|
2022-05-19 07:05:17 -04:00
|
|
|
static TArray<float> CachedWireThicknesses;
|
|
|
|
|
check(CachedWireThicknesses.Num() == 0); // Cant be called recursively or on multiple threads
|
|
|
|
|
CachedWireThicknesses.SetNumZeroed(AdditionalAttributeInfo.Num());
|
|
|
|
|
|
|
|
|
|
for (int32 AttributeInfoIndex = 0; AttributeInfoIndex < AdditionalAttributeInfo.Num(); ++AttributeInfoIndex)
|
2021-01-06 09:11:59 -04:00
|
|
|
{
|
|
|
|
|
const SGraphPinPose::FAttributeInfo& AttributeInfo = AdditionalAttributeInfo[AttributeInfoIndex];
|
|
|
|
|
|
2022-05-19 07:05:17 -04:00
|
|
|
float WireThickness = 0.0f;
|
|
|
|
|
switch (AttributeInfo.Blend)
|
2021-01-06 09:11:59 -04:00
|
|
|
{
|
2022-05-19 07:05:17 -04:00
|
|
|
case EAnimGraphAttributeBlend::Blendable:
|
|
|
|
|
{
|
|
|
|
|
if (UAnimBlueprint* AnimBlueprint = Cast<UAnimBlueprint>(FBlueprintEditorUtils::FindBlueprintForGraph(GraphObj)))
|
|
|
|
|
{
|
|
|
|
|
UAnimBlueprintGeneratedClass* AnimBlueprintClass = (UAnimBlueprintGeneratedClass*)(*(AnimBlueprint->GeneratedClass));
|
|
|
|
|
int32 SourceNodeId = AnimBlueprintClass->GetNodeIndexFromGuid(Node1->NodeGuid);
|
|
|
|
|
int32 TargetNodeId = AnimBlueprintClass->GetNodeIndexFromGuid(Node2->NodeGuid);
|
|
|
|
|
if (SourceNodeId != INDEX_NONE && TargetNodeId != INDEX_NONE)
|
|
|
|
|
{
|
|
|
|
|
const TArray<FAnimBlueprintDebugData::FAttributeRecord>* LinkAttributes = AnimBlueprintClass->GetAnimBlueprintDebugData().NodeOutputAttributesThisFrame.Find(SourceNodeId);
|
|
|
|
|
const bool bAttributeUsedInLink = LinkAttributes && LinkAttributes->ContainsByPredicate(
|
|
|
|
|
[&AttributeInfo, TargetNodeId](const FAnimBlueprintDebugData::FAttributeRecord& InRecord)
|
|
|
|
|
{
|
|
|
|
|
return InRecord.Attribute == AttributeInfo.Attribute && InRecord.OtherNode == TargetNodeId;
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
WireThickness = bAttributeUsedInLink ? AttributeWireThickness : 0.0f;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
break;
|
|
|
|
|
}
|
|
|
|
|
case EAnimGraphAttributeBlend::NonBlendable:
|
|
|
|
|
WireThickness = AttributeWireThickness;
|
|
|
|
|
break;
|
2021-01-06 09:11:59 -04:00
|
|
|
}
|
|
|
|
|
|
2022-05-19 07:05:17 -04:00
|
|
|
CachedWireThicknesses[AttributeInfoIndex] = WireThickness;
|
|
|
|
|
TotalThickness += WireThickness != 0.0f ? (WireThickness + WireGap) : 0.0f;
|
2021-01-06 09:11:59 -04:00
|
|
|
}
|
2022-05-19 07:05:17 -04:00
|
|
|
|
|
|
|
|
const float InitialOffset = TotalThickness * 0.5f;
|
|
|
|
|
FVector2D SubWireP0 = P0;
|
|
|
|
|
SubWireP0.Y += InitialOffset;
|
|
|
|
|
FVector2D SubWireP1 = P1;
|
|
|
|
|
SubWireP1.Y += InitialOffset;
|
|
|
|
|
|
|
|
|
|
// Draw in reverse order to get pose wires appearing on top
|
|
|
|
|
for (int32 AttributeInfoIndex = AdditionalAttributeInfo.Num() - 1; AttributeInfoIndex >= 0; --AttributeInfoIndex)
|
|
|
|
|
{
|
|
|
|
|
float Thickness = CachedWireThicknesses[AttributeInfoIndex];
|
|
|
|
|
if (Thickness > 0.0f)
|
|
|
|
|
{
|
|
|
|
|
const SGraphPinPose::FAttributeInfo& AttributeInfo = AdditionalAttributeInfo[AttributeInfoIndex];
|
|
|
|
|
FLinearColor Color = AttributeInfo.Color;
|
|
|
|
|
|
|
|
|
|
if (HoveredPins.Num() > 0)
|
|
|
|
|
{
|
|
|
|
|
ApplyHoverDeemphasis(Params.AssociatedPin1, Params.AssociatedPin2, Thickness, Color);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
SubWireP0.Y -= Thickness + WireGap;
|
|
|
|
|
SubWireP1.Y -= Thickness + WireGap;
|
|
|
|
|
|
|
|
|
|
// Draw the spline itself
|
|
|
|
|
FSlateDrawElement::MakeDrawSpaceSpline(
|
|
|
|
|
DrawElementsList,
|
|
|
|
|
LayerId,
|
|
|
|
|
SubWireP0, P0Tangent,
|
|
|
|
|
SubWireP1, P1Tangent,
|
|
|
|
|
Thickness,
|
|
|
|
|
ESlateDrawEffect::None,
|
|
|
|
|
Color
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
SubWireP0.Y -= Params.WireThickness + WireGap;
|
|
|
|
|
SubWireP1.Y -= Params.WireThickness + WireGap;
|
|
|
|
|
|
|
|
|
|
FKismetConnectionDrawingPolicy::DrawConnection(LayerId, SubWireP0, SubWireP1, Params);
|
|
|
|
|
|
|
|
|
|
CachedWireThicknesses.Reset();
|
2021-01-06 09:11:59 -04:00
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if(!bCompositeWire)
|
|
|
|
|
{
|
|
|
|
|
FKismetConnectionDrawingPolicy::DrawConnection(LayerId, Start, End, Params);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void FAnimGraphConnectionDrawingPolicy::ApplyHoverDeemphasis(UEdGraphPin* OutputPin, UEdGraphPin* InputPin, float& Thickness, FLinearColor& WireColor)
|
|
|
|
|
{
|
|
|
|
|
// Remove the thickness increase on hover
|
|
|
|
|
float OriginalThickness = Thickness;
|
|
|
|
|
FKismetConnectionDrawingPolicy::ApplyHoverDeemphasis(OutputPin, InputPin, Thickness, WireColor);
|
|
|
|
|
Thickness = OriginalThickness;
|
|
|
|
|
}
|