FSR Blueprint Library

FSR Frame Generation Library

The FSRFGLibrary exposes Blueprint nodes to configure AMD FidelityFX Frame Generation. All nodes are located under the AMD FidelityFX™ Frame Generation category.

Frame Generation features are supported by FSR 3 and FSR 4.

C++ Project Setup

To use these functions in C++, you must add the plugin's modules to your project's Build.cs file.

// YourProject.Build.cs
PublicDependencyModuleNames.AddRange(new string[] 
{ 
    "Core", 
    "CoreUObject", 
    "Engine", 
    "InputCore",
    "FSRDesktop", // Required for FSR FG functions
    "FSRGlobal"   // Required for FSR enums and data types
});

Core Frame Generation

Set FSR-FG Mode

Enables or disables AMD FSR Frame Generation. Supported FSR Versions: FSR 3, FSR 4

PinTypeDescription
ModeEFSRFrameGenerationMode (Input)Sets the Frame Generation mode (Disabled, Enabled).
#include "FSRFGLibrary.h"
#include "FSRDataTypes.h"

void AMyGameSettings::EnableFrameGeneration()
{
    UFSRFGLibrary::SetFSRFGMode(EFSRFrameGenerationMode::Enabled);
}

Get FSR-FG Current Mode

Retrieves the current Frame Generation state. Supported FSR Versions: FSR 3, FSR 4

PinTypeDescription
Return ValueEFSRFrameGenerationMode (Output)The currently active Frame Generation mode.
#include "FSRFGLibrary.h"

void AMyGameSettings::CheckFrameGeneration()
{
    EFSRFrameGenerationMode Mode = UFSRFGLibrary::GetFSRFGCurrentMode();
}

Set FSR-FG Async Present

Enables or disables the customized D3D12 swap-chain for superior asynchronous frame pacing. Supported FSR Versions: FSR 3, FSR 4

PinTypeDescription
ModeEFSRSwapChainMode (Input)Swap-chain mode (Default RHI, Override DX12).

Changing this setting requires an engine or game restart.

#include "FSRFGLibrary.h"
#include "FSRDataTypes.h"

void AMyGameSettings::ApplyAsyncPacing()
{
    UFSRFGLibrary::SetFSRFGAsyncPresent(EFSRSwapChainMode::OverrideDX12);
}

Get FSR-FG Async Present

Retrieves the current swap-chain override mode. Supported FSR Versions: FSR 3, FSR 4

PinTypeDescription
Return ValueEFSRSwapChainMode (Output)The currently configured swap-chain mode.
#include "FSRFGLibrary.h"

void AMyGameSettings::CheckAsyncPacing()
{
    EFSRSwapChainMode Mode = UFSRFGLibrary::GetFSRFGAsyncPresent();
}

UI Rendering Mode

Set FSR-FG UI Render Mode

Sets the UI rendering method during Frame Generation. Supported FSR Versions: FSR 3, FSR 4

PinTypeDescription
ModeEFSRUIMode (Input)UI rendering mode (Slate Redraw, UI Extraction).
#include "FSRFGLibrary.h"
#include "FSRDataTypes.h"

void AMyGameSettings::OptimizeUIForFrameGen()
{
    UFSRFGLibrary::SetFSRFGUIRenderMode(EFSRUIMode::UIExtraction);
}

Get FSR-FG UI Render Mode

Retrieves the active UI rendering method for Frame Generation. Supported FSR Versions: FSR 3, FSR 4

PinTypeDescription
Return ValueEFSRUIMode (Output)The current UI render mode.
#include "FSRFGLibrary.h"

void AMyGameSettings::CheckUIRenderMode()
{
    EFSRUIMode UIMode = UFSRFGLibrary::GetFSRFGUIRenderMode();
}

Debugging Features

These debugging nodes only function in Development and Editor builds.

Show FSR-FG Debug View

Toggles the Frame Generation debug view, allowing you to visualize generated frames. Supported FSR Versions: FSR 3, FSR 4

PinTypeDescription
bShowBoolean (Input)Set to true to display the FG debug view.
#include "FSRFGLibrary.h"

void AMyDebugManager::ToggleFGDebugView(bool bEnable)
{
    UFSRFGLibrary::ShowFSRFGDebugView(bEnable);
}

Show FSR-FG Debug Tear Lines

Toggles the display of tear lines for debugging frame pacing. Supported FSR Versions: FSR 3, FSR 4

PinTypeDescription
bShowBoolean (Input)Set to true to display pacing tear lines.
#include "FSRFGLibrary.h"

void AMyDebugManager::ToggleTearLines(bool bEnable)
{
    UFSRFGLibrary::ShowFSRFGDebugTearLines(bEnable);
}

Show FSR-FG Capture Debug UI

Ensures debug UI elements (like the console) are captured and displayed correctly during Frame Gen. Supported FSR Versions: FSR 3, FSR 4

PinTypeDescription
bCaptureBoolean (Input)Set to true to include debug UI in frame capture.
#include "FSRFGLibrary.h"

void AMyDebugManager::ToggleConsoleCapture(bool bCapture)
{
    UFSRFGLibrary::ShowFSRFGCaptureDebugUI(bCapture);
}

Last updated on

On this page