View in English

  • Apple Developer
    • Get Started

    Explore Get Started

    • Overview
    • Learn
    • Apple Developer Program

    Stay Updated

    • Latest News
    • Hello Developer
    • Platforms

    Explore Platforms

    • Apple Platforms
    • iOS
    • iPadOS
    • macOS
    • tvOS
    • visionOS
    • watchOS
    • App Store

    Featured

    • Design
    • Distribution
    • Games
    • Accessories
    • Web
    • Home
    • CarPlay
    • Technologies

    Explore Technologies

    • Overview
    • Xcode
    • Swift
    • SwiftUI

    Featured

    • Accessibility
    • App Intents
    • Apple Intelligence
    • Games
    • Machine Learning & AI
    • Security
    • Xcode Cloud
    • Community

    Explore Community

    • Overview
    • Meet with Apple events
    • Community-driven events
    • Developer Forums
    • Open Source

    Featured

    • WWDC
    • Swift Student Challenge
    • Developer Stories
    • App Store Awards
    • Apple Design Awards
    • Apple Developer Centers
    • Documentation

    Explore Documentation

    • Documentation Library
    • Technology Overviews
    • Sample Code
    • Human Interface Guidelines
    • Videos

    Release Notes

    • Featured Updates
    • iOS
    • iPadOS
    • macOS
    • watchOS
    • visionOS
    • tvOS
    • Xcode
    • Downloads

    Explore Downloads

    • All Downloads
    • Operating Systems
    • Applications
    • Design Resources

    Featured

    • Xcode
    • TestFlight
    • Fonts
    • SF Symbols
    • Icon Composer
    • Support

    Explore Support

    • Overview
    • Help Guides
    • Developer Forums
    • Feedback Assistant
    • Contact Us

    Featured

    • Account Help
    • App Review Guidelines
    • App Store Connect Help
    • Upcoming Requirements
    • Agreements and Guidelines
    • System Status
  • Quick Links

    • Events
    • News
    • Forums
    • Sample Code
    • Videos
 

Videos

Open Menu Close Menu
  • Collections
  • All Videos
  • About

Back to WWDC26

  • About
  • Summary
  • Code
  • Build real-time neural rendering pipelines with Metal

    Discover how to integrate machine learning into your real-time rendering pipeline using Metal 4. We'll explore practical adoption patterns and best practices for achieving production-quality results with MetalFX neural denoising, featuring real-world insights from Maxon's Redshift Live. Learn how to train and deploy a neural tone mapper using the ML command encoder inline with your graphics work. Finally, dive into the new tensor API to build and evaluate small, specialized neural networks directly within your shaders.

    Chapters

    • 0:00 - Introduction
    • 2:16 - MetalFX Denoising
    • 9:57 - Deploy custom ML networks with Metal 4
    • 13:40 - Inline neural networks with tensorOps
    • 20:55 - Next steps

    Resources

    • Metal sample code library
    • Download the Metal Performance Primitives (MPP) Programming Guide
    • Understanding the Metal 4 core API
      • HD Video
      • SD Video

    Related Videos

    WWDC25

    • Combine Metal 4 machine learning and graphics
    • Go further with Metal 4 games
  • Search this video…
    • 8:46 - Compute camera-only motion vectors

      #include <metal_stdlib>
      using namespace metal;
      
      // Compute camera-only motion vectors
      float4 clipCurrent = viewProjCurrent * float4(worldPos, 1.0);
      float2 ndcCurrent = clipCurrent.xy / clipCurrent.w;
      
      float4 clipPrevious = viewProjPrevious * float4(worldPos, 1.0);
      float2 ndcPrevious = clipPrevious.xy / clipPrevious.w;
      
      float2 motion = ndcPrevious - ndcCurrent;
      
      // Get subpixel offset for current and previous frames
      float2 jitterCurrent = getJitter(frameIndex);
      float2 jitterPrevious = getJitter(frameIndexPrevious);
      motion -= jitterPrevious - jitterCurrent;
    • 0:00 - Introduction
    • An overview of how machine learning is transforming real-time rendering pipelines on Apple platforms, and a preview of three levels of ML integration: MetalFX Denoising, deploying custom networks with Metal 4, and building tiny networks inline in shaders with tensorOps.

    • 2:16 - MetalFX Denoising
    • How to integrate MetalFX Denoising into a path tracer running at one sample per pixel. Covers auxiliary inputs (albedo, depth, motion vectors), best practices for clean inputs, transparency overlays, the denoiser strength mask, and primary surface replacement for mirrors and glass — illustrated with Redshift Live from Maxon.

    • 9:57 - Deploy custom ML networks with Metal 4
    • How to train a neural tone mapper offline (e.g., HDRNet), export it to Metal Performance Shaders Graph, and execute it inside a Metal 4 command buffer alongside your existing rendering passes to replace complex post-processing pipelines with a single network.

    • 13:40 - Inline neural networks with tensorOps
    • How to build and run small multilayer perceptrons directly inside Metal shaders using the TensorOps API and cooperative tensors. Demonstrates an online-trained sky visibility probe that adapts to dynamic scenes each frame — enabling ML inference and training that runs alongside your existing compute and render work.

    • 20:55 - Next steps
    • A recap of the three levels of ML integration in rendering pipelines, and guidance on where to start: download Xcode, explore Metal 4 sample code, and adopt MetalFX denoising for real-time applications first.

Developer Footer

  • Videos
  • WWDC26
  • Build real-time neural rendering pipelines with Metal
  • Open Menu Close Menu
    • iOS
    • iPadOS
    • macOS
    • tvOS
    • visionOS
    • watchOS
    • App Store
    Open Menu Close Menu
    • Swift
    • SwiftUI
    • Swift Playground
    • TestFlight
    • Xcode
    • Xcode Cloud
    • Icon Composer
    • SF Symbols
    Open Menu Close Menu
    • Accessibility
    • Accessories
    • Apple Intelligence
    • Audio & Video
    • Augmented Reality
    • Business
    • Design
    • Distribution
    • Education
    • Games
    • Health & Fitness
    • In-App Purchase
    • Localization
    • Maps & Location
    • Machine Learning & AI
    • Security
    • Safari & Web
    Open Menu Close Menu
    • Documentation
    • Downloads
    • Sample Code
    • Videos
    Open Menu Close Menu
    • Help Guides & Articles
    • Contact Us
    • Forums
    • Feedback & Bug Reporting
    • System Status
    Open Menu Close Menu
    • Apple Developer
    • App Store Connect
    • Certificates, IDs, & Profiles
    • Feedback Assistant
    Open Menu Close Menu
    • Apple Developer Program
    • Apple Developer Enterprise Program
    • App Store Small Business Program
    • MFi Program
    • Mini Apps Partner Program
    • News Partner Program
    • Video Partner Program
    • Security Bounty Program
    • Security Research Device Program
    Open Menu Close Menu
    • Meet with Apple
    • Apple Developer Centers
    • App Store Awards
    • Apple Design Awards
    • Apple Developer Academies
    • WWDC
    Read the latest news.
    Get the Apple Developer app.
    Copyright © 2026 Apple Inc. All rights reserved.
    Terms of Use Privacy Policy Agreements and Guidelines