Commit Graph

  • 89f8f0d71f FSR 2.3.4/3.1.5 update: Fix for possible negative rcas output. fsr3.1.4 Nico de Poel 2025-08-23 13:05:59 +0200
  • c31c462f7f Fixed Metal not getting compiled with texture array support, which broke HDRP support. Nico de Poel 2025-08-23 12:31:16 +0200
  • 419c82668a Updated package version number Nico de Poel 2025-05-12 20:06:11 +0200
  • ef8a19887b (FSR3) Clear new locks buffer ahead of the frame instead of at the end of the Accumulate pass. This makes more sense with NewLocks being an aliasable (temp RT) resource, and it avoids reading and writing to the same texture in the Accumulate pass. Nico de Poel 2025-05-11 12:28:13 +0200
  • 5bb38aa76d (FSR2) Clear new locks buffer ahead of the frame instead of at the end of the Accumulate pass. This makes more sense with NewLocks being an aliasable (temp RT) resource, and it avoids reading and writing to the same texture in the Accumulate pass. Nico de Poel 2025-05-11 12:20:05 +0200
  • fddefa8165 Changed auto-exposure texture into a double buffered resource (FSR3), to avoid issues with reading and writing to the same texture in the compute luminance pass. This allows fast exposure convergence without issues on OpenGL and Metal. Nico de Poel 2025-05-11 12:05:43 +0200
  • 97af0d9d8a Changed auto-exposure texture into a double buffered resource (FSR2), to avoid issues with reading and writing to the same texture in the compute luminance pass. This allows fast exposure convergence without issues on OpenGL and Metal. Nico de Poel 2025-05-11 11:48:08 +0200
  • 834abd0f0e Ported changes from FidelityFX 1.1.4 Nico de Poel 2025-05-09 20:14:16 +0200
  • a7d2635477 Updated FSR package version number to 1.0.1 fsr3.1.1 Nico de Poel 2024-12-15 13:17:47 +0100
  • cb42842275 Reorganized profiler sampling to work around issues in non-development builds on Unity 2020.x Nico de Poel 2024-12-15 12:40:13 +0100
  • c82e131ee8 Backported auto-exposure reset value from FSR3 as part of the OpenGL black screen fix Nico de Poel 2024-12-14 23:39:06 +0100
  • a1a037a8ec Ported auto-exposure initialization fix from FSR 3.1 over to FSR 2.2. Fixes black screen flashes on history reset in OpenGL on Nvidia GPUs. Nico de Poel 2024-12-14 21:06:28 +0100
  • a063074772 Optimized multi-compile keywords based on which are actually used in each pass Nico de Poel 2024-12-14 20:52:32 +0100
  • be76c9a138 Fixed FSR2 auto-exposure issue with OpenGL Core on Nvidia GPUs, most likely due to reading uninitialized texture data. Nico de Poel 2024-12-14 20:26:16 +0100
  • b014f056ed Use a constant to determine the highest mip level that SPD can use on OpenGL Core, and ensure storing the pyramid values use the correct mip level Nico de Poel 2024-12-14 20:25:35 +0100
  • f8f5f9077d Reduced number of SPD mip levels used by luma pyramid and shading change pyramid passes by one for OpenGL Core, to ensure they stay within the limit of 8 UAV bindings. Nico de Poel 2024-12-14 18:52:29 +0100
  • 3dd791eb84 Changed velocity factor integration in a way that isn't stupid Nico de Poel 2024-12-14 14:20:50 +0100
  • c4f82f7da3 Disabled Xbox Series-specific optimizations, as I have no way to test those right now and most likely they won't matter in Unity anyway Nico de Poel 2024-12-14 14:01:51 +0100
  • 922e89f9fe Updated shaders to FSR 3.1.3: - Color clamp now uses ellipsoid instead of AABB to help with ghosting streaks - Moved velocity factor to a different section of the accumulate pass Nico de Poel 2024-12-14 13:33:09 +0100
  • e28400609a Use precise math because it makes literally no difference for performance cas Nico de Poel 2024-11-08 11:59:16 +0100
  • 30235b37a5 Remove final saturate from the CAS filter, so that the output remains in HDR Nico de Poel 2024-11-08 10:58:29 +0100
  • d65cc3a35d Added standalone CAS sharpening shader Nico de Poel 2024-10-29 18:30:00 +0100
  • f5ad170590 Ported velocity factor and exposure clear value from FSR 3.1.1 code Nico de Poel 2024-10-01 23:27:26 +0200
  • 1d891ad702 Updated shaders to FSR 2.3.2 and FSR 3.1.1 from FidelityFX SDK 1.1.1 Nico de Poel 2024-10-01 22:41:35 +0200
  • cb4321b8ae Updated shaders and passes to the framework changes fsr3framegen Nico de Poel 2024-08-05 21:56:57 +0200
  • 5e9272b75a Merge branch 'framework' into fsr3framegen Nico de Poel 2024-08-05 21:48:47 +0200
  • a0b519ff66 Reworked pass base class so it doesn't impose a dispatch method signature, as that proved to be too restrictive. Instead made adding a profiler sample easier using a disposable struct. framework Nico de Poel 2024-08-05 21:48:28 +0200
  • 5944893e4b Renamed UNITY_FSR_ keywords and macros to UNITY_FFX_ to reflect that they're to be commonly used by all sorts of FidelityFX shaders. Nico de Poel 2024-08-05 17:47:04 +0200
  • 8d289fdfa7 Renamed ffx_fsr_unity_common include file to ffx_unity_common, so it can be more generally used for all sorts of FidelityFX shaders. Nico de Poel 2024-08-05 17:44:40 +0200
  • f1e963dfc1 Merge branch 'framework' into fsr3framegen Nico de Poel 2024-08-05 11:57:23 +0200
  • 80f42cae73 Struct constraint on dispatch parameters can now be enforced Nico de Poel 2024-08-05 10:42:06 +0200
  • 33f410125f Minor cleanup Nico de Poel 2024-08-04 17:35:33 +0200
  • 9c377cc144 Use derived classes to reference passes. Nico de Poel 2024-08-04 17:26:15 +0200
  • 76d0ee5425 Changed all dispatch descriptions into structs, renamed some fields, cleaned up some unused code. Changing to lowercase field names for public struct members now, which follows the C# naming conventions. FSR2/3 won't follow suit for now, because too much code already makes use of the capitalized names. Nico de Poel 2024-08-04 17:16:42 +0200
  • 2bb45ffb76 Merge branch 'framework' into fsr3framegen Nico de Poel 2024-08-04 17:06:12 +0200
  • 452f9e13a9 Turned all dispatch descriptions into structs with a default value, applied in-parameters wherever appropriate, renamed a few things, and made pass references use the most derived type. Nico de Poel 2024-08-04 17:02:54 +0200
  • 2ff4b9772b Made block size and texture size available through the optical flow context, which is better encapsulation. Nico de Poel 2024-08-04 01:40:09 +0200
  • b1ddc9ba0d Moved duplicated BackbufferTransferFunction enum to a common enums file Nico de Poel 2024-08-04 01:34:40 +0200
  • f41a81f1a8 Merge branch 'framework' into fsr3framegen Nico de Poel 2024-08-04 01:12:22 +0200
  • 43e0f15ab8 Made the pass classes sealed, which is a more sensible way to please the compiler about using virtual methods inside constructors. Nico de Poel 2024-08-04 01:08:14 +0200
  • 404a090adf Reworked optical flow passes to inherit from FfxPassBase, with a bit of a hack to work around the need for the extra level parameter. Made the pass classes sealed, which is a more sensible way to please the compiler about using virtual methods inside constructors. Nico de Poel 2024-08-04 01:04:56 +0200
  • 371743ca70 Applied in-parameter for context and dispatch descriptions more consistently Nico de Poel 2024-08-04 00:44:08 +0200
  • b21b1b43c4 Reworked passes to make the context description copy unnecessary, and made use of extension methods to simplify resource binding in Optical Flow passes. Nico de Poel 2024-08-04 00:34:01 +0200
  • ac96933f9d Merge branch 'framework' into fsr3framegen Nico de Poel 2024-08-04 00:16:53 +0200
  • b565ca029f Made flags a field of the FfxPassWithFlags class, obviating the need to hold on to a context description copy, or the need to pass flags around. Nico de Poel 2024-08-04 00:14:45 +0200
  • acb54c821f Refactored frame interpolation passes to use the common base class, and simplified all of the shader resource bindings. Nico de Poel 2024-08-03 18:32:40 +0200
  • 7b988fd39d Reworked dispatching code to use the common SPD and depth params methods. Nico de Poel 2024-08-03 18:20:10 +0200
  • de4f5bd83d Refactored context classes to use common base class, and reworked constant buffers to use the wrapper class. Nico de Poel 2024-08-03 18:12:28 +0200
  • 097eaa960a Refactored resources classes to use common base class Nico de Poel 2024-08-03 18:05:13 +0200
  • 9d35022137 Merge branch 'framework' into fsr3framegen Nico de Poel 2024-08-03 17:58:18 +0200
  • 3e4e0bb003 Moved SetupDeviceDepthToViewSpaceDepthParams to the common FfxUtils class Nico de Poel 2024-08-03 17:49:08 +0200
  • 74a127a40d Further generalized SPD constants and setup Nico de Poel 2024-08-03 17:41:10 +0200
  • d583c750d2 Moved SPD setup method into a separate common FfxSpd class Nico de Poel 2024-08-03 17:34:43 +0200
  • 328011f7ba Added profiling samplers around the entire FSR2/3 process Nico de Poel 2024-08-03 17:20:03 +0200
  • c5130f8236 Renamed frameIndex to bufferIndex Nico de Poel 2024-08-03 17:15:35 +0200
  • 3e91f84cf8 Simplified handling of compute buffer data by wrapping it inside a helper class Nico de Poel 2024-08-03 17:07:46 +0200
  • 19a74fee45 Created an abstract base class for context objects, with a few common helper methods Nico de Poel 2024-08-03 16:42:01 +0200
  • c33ec9d4ed Further abstracted base pass class to allow for passes without shader keyword flags, and to allow custom kernel names. Nico de Poel 2024-08-03 16:33:29 +0200
  • 7c923f8ce8 Renamed frameIndex to bufferIndex, which works in all contexts and makes it more clear that it'll be used as an array index Nico de Poel 2024-08-03 16:22:23 +0200
  • 13b9b98318 Created additional extension methods to bind various compute shader resources, to make the dispatching code a lot more straightforward. Nico de Poel 2024-08-03 16:16:35 +0200
  • 15b380eebf Abstracted some of the common pass code into a new base class for passes. Nico de Poel 2024-08-03 15:51:37 +0200
  • 2d446333c1 Created additional shared helped methods for creating lookup textures and the Lanczos2 LUT Nico de Poel 2024-08-03 15:28:17 +0200
  • 3bb3d78610 Refactored resource creation to make use of shared helped methods Nico de Poel 2024-08-03 15:17:05 +0200
  • 6219d6159d Moved all create/destroy methods for various types of resources to a new common base class Nico de Poel 2024-08-03 14:58:49 +0200
  • 9f06f24943 Moved a number of shared static helper methods to a new FfxUtils class Nico de Poel 2024-08-03 14:46:07 +0200
  • 4282b10eb4 Revert "Disabling inverted depth flag while I try to figure out what the correct way to deal with this is. For now, this fixes the broken disocclusion mask causing holes in the interpolated frame, which then get filled in with junk by the inpainting pass." Nico de Poel 2024-07-29 12:35:03 +0200
  • 49d197e60f Disabling inverted depth flag while I try to figure out what the correct way to deal with this is. For now, this fixes the broken disocclusion mask causing holes in the interpolated frame, which then get filled in with junk by the inpainting pass. Nico de Poel 2024-07-28 17:31:34 +0200
  • 32692053a4 Small cleanup Nico de Poel 2024-07-28 14:00:57 +0200
  • db151d3604 Reduced Unity version requirement to 2019.x 2019 Nico de Poel 2024-07-27 23:53:31 +0200
  • 8d34558083 Removed auto-T&C mask resources from FSR3. Nico de Poel 2024-07-27 23:22:41 +0200
  • 0b63246f6c Reverted FSR2 resources back to using temporary RTs wherever possible. Use explicit name ID binding for compute buffer texture parameters. Nico de Poel 2024-07-27 23:20:50 +0200
  • 44b9a37dee Made FSR3 upscaler compatible with Unity 2019.x: - Removed multi_compile pragmas for a single, statically compiled variant of each shader, using the most common permutation. - Use old API to directly set data on a compute buffer and bind compute buffers globally. - Removed auto T&C pass to avoid clashes with auto-reactive pass in their compute buffer usage. - Explicitly bind temporary RTs to compute shaders, even if they are using globally bound name IDs. - Removed texture array support. Nico de Poel 2024-07-27 23:08:56 +0200
  • 5402dd465a Made FSR2 compatible with Unity 2019.x: - Removed multi_compile pragmas for a single, statically compiled variant of each shader, using the most common permutation. - Use old direct API to set data on a compute buffer. - Removed auto T&C pass to avoid clashes with auto-reactive pass in their compute buffer usage. - Made all resources persistent, to avoid issues with binding temporary render textures (may not actually have been an issue). Nico de Poel 2024-07-27 22:26:54 +0200
  • 875b90f6ef Simplified backbuffer selection for interpolation source Nico de Poel 2024-07-27 13:44:20 +0200
  • 4e29c3dfb4 Replaced allocating lambda expression with a regular method. Nico de Poel 2024-07-27 13:36:40 +0200
  • 01eb878a3e Removed pointless dispatch count, when it's only used to check for first execution Nico de Poel 2024-07-27 13:23:45 +0200
  • c215db4017 Removed a few TODOs for things that have been checked and seem fine Nico de Poel 2024-07-27 13:08:47 +0200
  • 4b675d285e Modified inpainting pyramid passes to use a maximum of 7 mip levels. This allows the shaders to stay within the limit of 8 UAV bindings required by DX11.0, and gets rid of Unity's warnings and errors about breaking this limit. Nico de Poel 2024-07-27 13:03:29 +0200
  • a72e842bee Fixed unintentional cap on SPD mip levels Nico de Poel 2024-07-27 12:49:41 +0200
  • 279edd4429 Allocate double buffers only when async compute support is enabled Nico de Poel 2024-07-27 12:32:19 +0200
  • 80d63d74fa Fixed mipmap bindings when going over the RT's mipmap count, and pick the correct backbuffer to copy for the next frame. Nico de Poel 2024-07-26 23:37:37 +0200
  • 910621b019 Couple of tweaks to facilitate integration Nico de Poel 2024-07-26 23:22:46 +0200
  • ec705e3d8d Implemented remaining dispatch code Nico de Poel 2024-07-26 22:50:58 +0200
  • 28ca91c32f Implemented prepare process and started on main dispatch Nico de Poel 2024-07-26 20:00:33 +0200
  • 1fab819f35 Implemented remaining passes Nico de Poel 2024-07-26 17:10:31 +0200
  • 4cd63e62a8 Implemented a bunch more FI passes Nico de Poel 2024-07-25 23:16:05 +0200
  • 57b78d7bac Implemented prepare (reconstruct and dilate) pass Nico de Poel 2024-07-25 22:32:49 +0200
  • df9db23e6a Set up shader IDs and dispatch descriptions Nico de Poel 2024-07-25 22:18:32 +0200
  • e9c46dfdd7 Set up pass classes and instances Nico de Poel 2024-07-25 21:56:37 +0200
  • c9f6b3f29d Implemented resources and some initialization code and structs Nico de Poel 2024-07-25 21:35:03 +0200
  • 88a7c95666 Added script meta files that weren't generated yet last time around Nico de Poel 2024-07-25 17:16:10 +0200
  • e6c714c02e Set up initial skeleton for Frame Interpolation implementation Nico de Poel 2024-07-24 23:22:20 +0200
  • 198f2725af Renamed namespaces for OF and FI to FrameGen. Logically groups the two together, and it avoids the need for awkward OpticalFlow.OpticalFlow.something references. Nico de Poel 2024-07-24 22:11:12 +0200
  • eeb4095685 Reworked backbuffer transfer function parameter into a clearly designated enum Nico de Poel 2024-07-24 19:50:11 +0200
  • 9a72a8f180 Implemented the remaining optical flow passes and fixed a few small issues. Seems to work but it needs more extensive testing. Nico de Poel 2024-07-24 18:06:32 +0200
  • c74320613b Reworked multi-level double-buffered resources into arrays of arrays of render textures Nico de Poel 2024-07-23 23:28:13 +0200
  • 0701d8bf52 Moved some helper methods to the static OpticalFlow class Nico de Poel 2024-07-23 22:58:04 +0200
  • 4be784e427 Implemented passes up to and including SCD divergence Nico de Poel 2024-07-23 22:36:37 +0200
  • 70121d1516 Implemented resources, shader IDs, the skeleton for all passes, setup and destruction, a bunch of helper methods and dispatch of the prepare luma pass. Nico de Poel 2024-07-23 21:21:06 +0200
  • 07a7571935 Set up first skeleton for optical flow data structures and dispatching Nico de Poel 2024-07-22 23:48:05 +0200