Files
UnrealEngineUWP/Engine/Source/Editor/BlueprintGraph/Public/MathExpressionHandler.h
Maciej Mroz 15e44a1b6e ME Optimization:
- FBPTerminal::InlineGeneratedParameter added - the result of the function is directly used as input parameter, it's not stroed in a lical variable
- FKismetFunctionContext::InlineGeneratedParameter
- MathExpressionHandler - compile (to out intermediate representation) a subgraph using "reverse polish notation" approach
- Math Expression node is not longer expanded
- VMBackend supports InlineGeneratedParameter and InlineGeneratedParameter

#codereview Nick.Whiting, Mike.Beach

[CL 2587365 by Maciej Mroz in Main branch]
2015-06-15 10:54:30 -04:00

30 lines
965 B
C++

// Copyright 1998-2015 Epic Games, Inc. All Rights Reserved.
#pragma once
#include "KismetCompiler.h"
struct FBlueprintCompiledStatement;
class UK2Node_MathExpression;
struct FKismetFunctionContext;
class FKCHandler_MathExpression : public FNodeHandlingFunctor
{
FBlueprintCompiledStatement* GenerateFunctionRPN(UEdGraphNode* CurrentNode
, FKismetFunctionContext& Context
, UK2Node_MathExpression& MENode
, FBPTerminal* ResultTerm
, TMap<UEdGraphPin*, UEdGraphPin*>& InnerToOuterInput);
public:
FKCHandler_MathExpression(FKismetCompilerContext& InCompilerContext)
: FNodeHandlingFunctor(InCompilerContext)
{}
virtual void RegisterNets(FKismetFunctionContext& Context, UEdGraphNode* InNode) override;
virtual void RegisterNet(FKismetFunctionContext& Context, UEdGraphPin* Net) override;
virtual void Compile(FKismetFunctionContext& Context, UEdGraphNode* Node) override;
static bool CanBeCalledByMathExpression(const UFunction* Function);
};