AMD FidelityFX™ Single Pass Downsampler (SPD) background

AMD FidelityFX™ Single Pass Downsampler (SPD)

Single pass MIP levels

Horizon Zero Dawn logo

AMD FidelityFX™ Single Pass Downsampler (SPD) provides an AMD RDNA™ architecture-optimized solution for generating up to 12 MIP levels of a texture.

Supports: 

  • DirectX® 12 Ultimate
  • Vulkan®

Part of the AMD FidelityFX™ SDK

AMD FidelityFX SDK components

Download the latest version - v1.1.4

This release of the AMD FidelityFX™ SDK adds the following features:

  • Additions to the API and fixes for issues discovered.

Features

Downsample in a single pass

RDNA™ architecture optimized

Use SPD with existing postprocessing

Details

MIP levels have versions of the same texture but in smaller resolutions. They are used when the high-resolution texture is not necessarily needed (such as when objects are far from the camera, covering only a few pixels) or might introduce aliasing artefacts. MIP levels are also commonly used in effects like Bloom, Screen Space Reflections, and many more.

Use AMD FidelityFX™ SPD as a building block to accelerate your post processing pipeline or texture creation.

More key features

  • Generates up to 12 mip levels (maximum source texture size is 4096x4096).
  • Single function call.
  • User defined 2x2 reduction function.
  • User controlled border handling.
  • Supports various image formats.
  • HLSL and GLSL versions available.
  • Rapid Packed Math support.
  • Uses optionally subgroup operations / SM6+ wave operations, which can provide faster performance.

Generating these MIP levels is in principle quite simple. For the next lower MIP, a 2×2 pixel quad is averaged resulting in a half-sized resolution texture. The most common approach is to generate these MIP levels one after the other. This requires synchronization after each step.

AMD FidelityFX™ SPD instead works on patches, downsampling each patch individually using a single pass compute shader without the requirement to synchronize the whole GPU after each step. Without these in-between synchronizations it makes SPD suitable for async compute.

The traditional approach

vs. AMD FidelityFX SPD

New for AMD FidelityFX™ SPD v2.0 - Support for downsampling sub-rectangles

Default approach: 

  • Invokes 64 thread groups.

With the sub-rectangle feature:

  • Invokes 12 thread groups.
  • Only downsamples a subrectangle covering all patches with modified data.

Note: The last active thread group still computes the last 4 MIPs in both cases i.e. 8x8 → 4x4 → 2x2 → 1x1

Source texture: 512×512

64×64 patch with unmodified data.
64×64 patch with modified data.

Optimizing for the AMD RDNA™ Architecture

Lou Kramer, Developer Technology Engineer

When AMD introduced its Navi family of GPUs, it also introduced a whole new GPU architecture: RDNA™. This architecture is not only used in AMD GPUs for PC, but also in next-generation consoles. Join the session to learn about the details of RDNA and how it differs from the previous GCN architecture. We will also be presenting examples of optimizations based on the case study of implementing an efficient downsampler covering topics such as characteristics of workload distribution, shader optimizations, and efficient texture access.

Requirements

  • DirectX® 12 Ultimate
  • Vulkan®

Footnotes and disclaimers

Horizon Zero Dawn™ © 2024 Sony Interactive Entertainment Europe. Published by Sony Interactive Entertainment Europe. Developed by Guerrilla. “Horizon Zero Dawn” is a trademark of Sony Interactive Entertainment Europe. All rights reserved.

Version history

  • The AMD FidelityFX™ SDK 1.1.4 is a patch release that includes additions to API and fixes for issues discovered with AMD FSR 3.1.0 to 3.1.3.

  • Exposed 4 new tunings to reduce AMD FSR upscaler ghosting in newly disoccludded pixels or highly reactive pixels.

  • Changed the default value of fMinDisocclusionAccumulation to -0.333 (from equivalent of 0.333 in AMD FSR 3.1.3) to reduce disocclusion ghosting.

  • Added ffxQueryGetProviderVersion to get version info from created ffx-api context.

  • Exposed ffxDispatchDescFrameGenerationPrepareCameraInfo as a linked struct. It is a required input to AMD FSR 3.1.4 and onwards for best quality.

  • Added frame generation debug checker support.

  • Dropped unused interpolation command lists if frame generation callback fails, to fix infinite wait at swapchain destruction.

  • General fixes to Vulkan® Frame Interpolation Swapchain.

  • General framework fixes and updates.

  • Frame pacing debug line added to Vulkan®.

  • Added new FFX error when create frame interpolation swapchain results in E_ACCESSDENIED in DX12 due to overlay or capture software.

  • Enabled support for frame interpolation swapchain on Windows® 10 1909 and potentially earlier versions.

  • Fixed flipped disocclusion factor from previous and current backbuffer.

  • Fixed HDR mode issues in Cauldron sample.

  • Fixed MSVC C compile errors including ffx-api.

  • The AMD FidelityFX™ SDK 1.1.4 also updates the following to address select issues:

  • AMD FidelityFX™ Brixelizer GI 1.0.1

  • AMD FidelityFX™ Breadcrumbs 1.0.1

Other AMD FidelityFX effects