Skip to content

Commit c843738

Browse files
sebastienlagardeJulienIgnace-UnityRSlyszFrancescoC-unityAntoine Lelievre
authored
Merge Hdrp/staging [Skip CI] (#49)
* Global Settings API doc. (#5649) * Fog Volume Component API doc. (#5645) * Debug Display API doc. (#5643) * Color picker API doc. * FullScreen Debug API doc. * Decal debug API doc * False Color debug API doc * Lighting Debug API doc * Material Debug API doc. * DebugDisplaySettings API doc. * Restored contact shadow fade debug. * API documentation for sky related classes. (#5640) * API documentation for sky related classes. * Document the PBR sky * Hdrp/small wizard fixes for dxr (#5633) * Add ScreenSpaceShadow to Camera's default FrameSettings * Forbid to atmpt creating default scene if the hdrpAsset is not right (we depend on its resources) * Update CHANGELOG.md * Add OS and Hardware check in wizard for DXR * Update CHANGELOG.md * Fixe typos * Add missing check on Shadows * Update Documentation Co-authored-by: sebastienlagarde <[email protected]> * Documentation (#5613) Co-authored-by: sebastienlagarde <[email protected]> * Fix custom pass disable stencil (#5545) * Disable the strencil in custom passes when overwriting the depth and not writing into it * Updated changelog * Rephrase doc Co-authored-by: sebastienlagarde <[email protected]> * Add option to exclude camera motion contribution from motion blur (#5656) * Remove camera component from motion blur if desired * changelog * Documentation update Co-authored-by: sebastienlagarde <[email protected]> * Implement Semi-transparent Shadows for Point and Spot lights (#5490) * Make the shadow behavior for transparent and transmissive objects more intuitive. * Update changelog * Implementing semi transparent ray traced shadows for point and spot light Adding a test scene for both cases Moving contact shadow ray tracing code to a seperate file Changing the direction of contact shadow rays to be coherent with the other shadows * update changelog * Update the test scenes Co-authored-by: sebastienlagarde <[email protected]> * fix shader warning in termporal AA * Support semi-transparent shadows for unlit shader and unlit shader graph (#5663) * Not doing ray tracing when the stencil bit is off for ssr (#5665) adding a test case for it * Restored serialization of deprecated parameters to fix migration. (#5666) * Shadow Atlas is no longer allocated for area lights when they are disabled in the shader config file. (#5662) Co-authored-by: sebastienlagarde <[email protected]> * Updated HDRP documentation (#5664) * Updated HDRP asset doc * Update the upgrade guide for cookies and planars * Added warning in the material sorting priority doc for depth write * Added a section about surface option properties for ShaderGraphs * Fix link name * Alpha output documentation (#5658) * Update documentation for HDRI-Sky-Backplate (AO) (#5670) * Avoid MRT Clear on PS4 [Skip CI] (#5675) * Avoid MRT Clear on PS4 * changelog * Update HDRenderPipeline.cs * Update HDRenderPipeline.cs Co-authored-by: sebastienlagarde <[email protected]> * Change name of option (#5681) * More code share between inspector materials (#5635) * Share stencil code for inspector materials (Akin to what happens in shadergraph) * changelog * Add comment and fix issue * Better handling of setting state (if not available, don't write it) * Update BaseLitGUI.cs Co-authored-by: sebastienlagarde <[email protected]> * Expose alpha cutoff material for ShaderGraphs (#5667) * Expose alpha clip to material UI for ShaderGraphs * Updated changelog * Replace #if by #ifdef * Fix debug menu bitfield (#5683) * Fixed runtime debug menu bitfield controls * Updated changelog * Hdrp/update default scenes (#5634) * Replace default scenes with scene prepared for scene-template * Update of DefaultSettingsProfile * Update DXR scene * fix missing profile in default scene dxr * Update CHANGELOG.md * Fix missing HDRI Sky references in DXR new scene * Fixed VFX Tests Default volume profile * Changed Default Volume settings to an empty one. * Missing volume asset files + update manifest and meta Co-authored-by: JulienIgnace-Unity <[email protected]> Co-authored-by: sebastienlagarde <[email protected]> * - Fixed the radius value used for ray traced directional light. (#5682) - Fixed compilation issues with the layered lit in ray tracing shaders. - Changed the way the length parameter is used for ray traced contact shadows. - Added contact shadow test scenes Co-authored-by: sebastienlagarde <[email protected]> * fixed XR autotests viewport size rounding (#5684) Co-authored-by: sebastienlagarde <[email protected]> * Material samples bis (#5686) * Add ball * update Material samples #5638 * Update CHANGELOG.md * Remove unused version property from Material * Updating the documentation for ray tracing (#5680) * Updating the documentation for ray tracing * review corrections * Fix mip slider reflectionprobe (#5689) * Remove the slider knob when the reflection probe preview has no mipmap * Updated changelog * edit VR documentation (#5685) Co-authored-by: sebastienlagarde <[email protected]> * Better directional PCSS blur handling (#5688) * Use correct penumbra calculation for directional. * Update visual test * Need cleaning uo * Cleaning * screenshot update * Small cleanup * typo leftover * changelog Co-authored-by: sebastienlagarde <[email protected]> * Update 001-HDTemplate.png * Adding the initial implementation of sub-surface scattering (#5625) * Initial implementation of ray traced sub surface scattering Added a test scene for ray traced sub surface scaterring * Update changelog * Updating the tests * Update 8103_PrePostPass.unity * Remove unnecessary skip of material upgrade dialog box. (#5692) * Remove unnecessary skip of material upgrade dialog box. * Update changelog Co-authored-by: sebastienlagarde <[email protected]> * Fix warning after metal fixup (#5704) * Various API doc update. (#5705) * Various doc + FrameSettings WIP * Finished frame settings API doc and added various other missing doc. Also made internal wrongly public API in HDRP * Fix density volume blend distance (#5698) * Fixed adjusting positive axis of Blend Distance slides the negative axis * Updated changelog * edit VR doc (#5699) * Hdrp/wizard update vr installation (#5706) * Add installatation checker in UsedPackageRetriever * Add PackageInstaller * Add better control on the displayed HelpBox * Update VR fixes * fix typo * Move Install Config Package Button above with HDRP Package info * Update CHANGELOG.md * Update documentation Co-authored-by: sebastienlagarde <[email protected]> * Removing unused alpha threshold depth prepass and post pass for fabric shader graph (#5711) Co-authored-by: sebastienlagarde <[email protected]> * Fix default volume profiles location (#5710) * Ray traced reflection smoothness fade and fallback fixes. (#5700) * Fix fall back for ray traced reflections when denoising is enabled Make Smoothness Fade start work with ray traced reflections Fix the blend of reflections based on the weight Add the contact shadow test scenes back * Change the name of the weight function and add it to all shading models Co-authored-by: sebastienlagarde <[email protected]> * Fix iridescence color space (#5691) * Fix iridescence color space * Fixed compilation and updated test screenshots * fix test Co-authored-by: JulienIgnace-Unity <[email protected]> * Fix Terrain Detail Mesh (stop to spam) [Require C++ PR] (#5690) * disable support of Terrain Detail Fix for error spam issue in HDRP: https://fogbugz.unity3d.com/f/cases/1211848/ * Update CHANGELOG.md * Update HDRenderPipeline.cs * Update HDRenderPipeline.cs * [Waiting for C++] Disable probes in renderers (#5648) * Disable probes section in the Renderer editors * Updated changelog Co-authored-by: sebastienlagarde <[email protected]> * Merge Hdrp/fix/case 1210058 to master (#5612) * Fix for 1210058 - NaNs at certain view angles Issue is caused by NaNs/INFs when computing basis on extremely thin (subpixel-width) geometry. Putting some safeguards fixes the issue * Update CHANGELOG.md to reflect 1210058 fix. * Updated fix for issue #1210058 Overwrite the UVs to fix the derivatives. * Updated fix for issue #1210058 Make sure the UVs are zero if unused to fix the derivatives. * Undo last.change -- UV fix addresses NaNs Zeroing the unused UV1 channel on the material seems to do the trick. * Changelog adjustments to be moved Current version puts everything in HDRP, so there is no change in core. * Update CHANGELOG.md Reflect fix for NaNs * Fixed UV1 for lightmaps and detail maps. * update comment * Update NormalSurfaceGradient.hlsl Co-authored-by: JulienIgnace-Unity <[email protected]> Co-authored-by: sebastienlagarde <[email protected]> * Minor code cleanup * Added script documentation for SSR, SSAO (ray tracing), GI, Light Cluter, RayTracingSettings, Ray Counters, ray traced SSS andRecursive Rendering. (#5732) * Added script documentation for SSR, SSAO (ray tracing), GI, Light Cluster, RayTracingSettings, Ray Counters, ray traced SSS andRecursive Rendering. * udpate changelog * Implementation of ScreenSpaceReflections for Transparent materials (#4968) Co-authored-by: sebastienlagarde <[email protected]> * Fix HDRP duplicated frame settings (#5850) * - Added a fallback for ray traced area light shadows in case the material is forward or the lit mode is forward. (#5749) - Fixed a bug related to ray traced area light shadow history. Co-authored-by: sebastienlagarde <[email protected]> * Fix cookie index usage (#5871) * Hdrp/merge staging (#5943) * fix case 1205791 custom mesh issue (#5551) * fic case 1205791 custom mesh issue * Updated changelog * Added a call to Dirty() (#5420) * Added a call to Dirty() * Updated changelog Co-authored-by: Marc Templin <[email protected]> * Fix shadergraph analytics. (#5912) * Fix analytics. * Added changelog * Fix for case 1200161 Save as subgraph issue (#5503) * Fix for case 1200161 * Edited CHANGELOG.md * Added comment to the code Co-authored-by: Sharlene Tan <[email protected]> Co-authored-by: Marc Templin <[email protected]> * fix for unreported keyword bug (#5863) * Fixed fogbugz case 1197958 (#5671) * * Fixed fogbugz case 1197958. * * Updated CHANGELOG.md. * * Added spacing. * Added #if ENABLE_VR && ENABLE_VR_MODULE guard to XR code. * Added Logic to Inject render pass to base renderer (#5901) * Moved render pass injection code from Forward Renderer to ScriptableRenderer to be able to use for all renderers. * added changelog * Disabling the GetDefaultRenderer() test for now until it is redone. (#5924) * [Yamato] [skip ci] Setting up master to run on 2020.1 (#5936) * added 2020.1 and fast to editors * added 2020.1/staging and fast to the rest of the files * [CI] Bors setup (#5841) * Create bors.toml * Update bors.toml * Update bors.toml * Update upm-ci-projects.yml * Create testcommit * Update bors.toml * adding trying trigger * add staging trigger * Delete testcommit * use squash merge * updating job that bors will run * [skip ci] update job that bors will run * Fixed MAD and RCP definitions in OpenGL. (#5922) Co-authored-by: Martin Thorzen <[email protected]> Co-authored-by: Marc Templin <[email protected]> Co-authored-by: Sharlene Tan <[email protected]> Co-authored-by: Zachary Diller <[email protected]> Co-authored-by: thomas-zeng <[email protected]> Co-authored-by: Felipe Lira <[email protected]> Co-authored-by: Elvar Örn Unnþórsson <[email protected]> Co-authored-by: Liis Kivistik <[email protected]> Co-authored-by: Sophia <[email protected]> * Fix whitespace * Misc fixes for the sky (#5974) * Static lighting sky now takes the default volume into account. * Fixed a leak in the PBR sky renderer. * Added a tooltip to the Ambient Mode parameter in the Visual Environment volume component. * Update changelog * Fixed null ref * Fixed an issue where having ambient mode set to dynamic might prevent the sky from being included in baking. * Forces an update of static sky when changing it in the Environment panel. * Fixed a problem with static sky when multiple skies are rendered at the same time. * Revert probes renderer PR (#5990) * Re-enable the probes section of renderers as it was not supposed to be disabled * Updated changelog * Fix a leak in the sky system. (#5967) * Fixed a cubemap leak when rendering previews for the first time. Also changed the debug name of the cubemap used for static lighting. * Update changelog. * Fixed an assert getting fired for the wrong reason. * Added a new light layer debug mode (#5942) * Moved lighting debug settings in containers * Light layers debug mode * Categories for Lighting Debug Panel Documentation * Light layers debug mode documentation * DebugUI.BitField now uses correct display names * Added unit test scene * Added changelog * Revert "Added changelog" This reverts commit a148fc2f97ef5288123f8f16485ba35f57b80f5e. * Updated CHANGELOG * Disable light layer debug mode after testing * reset all debug display settings * Renamed Shadow Layers option * Editable layer color. Defaults to color blind friendly colors * Fix when enabling an exclusive setting * Updated screenshots with new colors * Simplified variable API * Renamed class * Fix division by 0. Updated doc Co-authored-by: Adrien <[email protected]> * Hdrp/ssr toggle (#5996) * Added an "enable" checkbox to the SSR volume component. * Update changelog * Fix build when not in editor (#6024) * Fixed SSR in scene 1710 (#6028) * Fix merge error * Removed MSAA Buffers allocation when lit shader mode is set to "deferred only" (#6012) * Removed MSAA Buffers allocation when lit shader mode is set to "deferred only". * Removed MSAA SSS Buffer allocation when deferred only. * Invalid cast for realtime reflection probes (case 1220504) (#6026) * Invalid cast for realtime reflection probes (case 1220504) * Updated changelog Co-authored-by: sebastienlagarde <[email protected]> * Aov Buffers tests (#6023) * Deactivate Preview Camera for HDCameraEditor to prevent it from rende… (#6022) * Deactivate Preview Camera for HDCameraEditor to prevent it from rendering in the render loop (case 1105163) * Updated changelog Co-authored-by: sebastienlagarde <[email protected]> * Disable reflection probes section (#5994) * Disable reflection probes in the renderer components * Updated changelog * Remove version guard for terrainDetailUnsupported Co-authored-by: sebastienlagarde <[email protected]> * Integrate first skeleton of post process in render graph. (#5856) * Fixed execution error without raytracing * Prepare Prepass refacto * Another round of preparation * Renamed XRPassScope to XRSinglePassScope * RenderAfterPostProcess is now static * Add AfterPostProcess to RenderGraph (WIP) * AfterPostProcess implementation * Fixed wrong RTHandle allocation * Fixed light layers texture binding during deferred lighting pass * Implemented Post Process Final Pass with RenderGraph * Post merge fixes * Fixed some issues with missing buffers in SSS and deferred lighting compute shaders. * Fixed alpha in post processes * Fix DXR Tests (#6073) * Made ssr enable parameter true by default. (#6076) * Add comment (#6056) * Hdrp /tests/shuriken light module (#6021) * Add shurikent light module test * Fixed Simulate * Fix texts and image ratio Co-authored-by: sebastienlagarde <[email protected]> * Hdrp/pt7 (#5831) * Added support for anisotropy. * Tidied the code up, plus moved to correlated G term for aniso GGX. * Added anisotropic refractive sampling. * Disable path tracing for the shading graph preview camera. * Added support for alpha culling. * Fixed issue with transmission rays. * Updated Changelog. * Added support for punctual and directional light cookies. * Updated Changelog. * Added support for area light cookies. * Fixed bug with area cookies atlas not being properly generated when rebuilding library. * Made sure maxDepth > minDepth always, and added support for AO from mask. * Added support for transparent shadows. * Updated Changelog. * Toggling path tracing on/off does not reset iteration anymore. * Reverted change on enable, was causing minor issues. * Made sure we don't have transparent behaviour when shader is set to opaque. * Minor changes. * Tweaks on transparency behaviour. * Updated changelog. * Added path-tracing specific payload. * Added support for iridescence. * Updated Changelog. * Added multiple scattering compensation for specular. * Added Path tracing test. * PT test part 2. * Updated Changelog. * Added proper area light range attenuation. * Fixed issue with alpha clipping in ray-tracing. * Cosmetic. * Fix on the rect area light range. * In the editor, dragging manipulators around now resets accumulation. * Added material dirtiness tracking. * Does not apply intensity clamping to camera rays. * Reste PT iteration when saving a shader graph. * Added dirtiness tracking for acceleration structure and lights. * Added support for bg color. * Minor change to progress bar display. * Minor change to iteration counter, so that it never goes over the max. * Updated path tracing test. * Hdrp/rendergraph cleanup (#6083) * Fixed execution error without raytracing * Prepare Prepass refacto * Another round of preparation * Renamed XRPassScope to XRSinglePassScope * RenderAfterPostProcess is now static * Add AfterPostProcess to RenderGraph (WIP) * AfterPostProcess implementation * Fixed wrong RTHandle allocation * Fixed light layers texture binding during deferred lighting pass * Implemented Post Process Final Pass with RenderGraph * Post merge fixes * Fixed some issues with missing buffers in SSS and deferred lighting compute shaders. * Fixed alpha in post processes * Removed RenderGraphResource and RenderGraphMutableResource in favor of more explicit RendererListHandle and TextureHandle * Fixed decal normal patch pass * Fixed stencil resolve render pass * Fixed RenderDBuffer render pass function capturing variables. * Fixed wrong variable capture and restored ClearLightList to the render graph implementation of BuildGPULightList * Various fixes of things that diverged compared to regular path. * Unified renderer list and texture invalid handle error. * Revert wrong change * post merge fix * Removed useless comment. * Missing doc * Hdrp /fix light prefab infinite reload on inspector gui (#6054) * fix infinite reload loop for light prefab * Update CHANGELOG.md * Fixed an issue where fog sky color mode could sample NaNs in the sky cubemap (#6027) * Fixed an issue where fog sky color mode could sample NaNs in the sky cubemap. * Update changelog. # Conflicts: # com.unity.render-pipelines.high-definition/CHANGELOG.md * Fixed sampling of the sky texture in a more general way (not just fog) updated tests screenshots as well. * Missing screenshot * Fixed the issue properly by generating 7 mips of convolution. * Reverted screenshots * Reverted useless change. * Fix culling group was not disposed error in the build (#5880) * Fix culling group was not disposed error in build * Fix culling was not disposed error in build * Updated changelog Co-authored-by: sebastienlagarde <[email protected]> * Fix Material Samples : Revert correct GUIDs (#5875) * Revert correct GUID Change the GUID of the prefab to the correct one referenced in the scene * Fix fern material GUID * Hdrp/light multiplier (#6077) * Allow the light dimmer to get values higher than one * Changelog Co-authored-by: sebastienlagarde <[email protected]> * Update documentation typo (#5860) * Add warning and workaround instructions if XR single-pass is enabled after the first frame with XR SDK (#5853) * added warning and workaround instructions if XR single-pass is enabled after the first frame with XR SDK * edit VR doc * Updated CHANGELOG.md * Updated VR-Overview.md Co-authored-by: sebastienlagarde <[email protected]> Co-authored-by: Sharlene Tan <[email protected]> * Remove info box on Visual Environment and replaced it with info on documentation (#6099) * Remove info box and update documentation * changelog Co-authored-by: sebastienlagarde <[email protected]> * Update 9801_ShurikenLightModule.png * Add missing exposure and mipmap sliders to the planar reflection probe preview (#5847) * Added planar reflection probe preview mip and exposure sliders * Updated changelog * Disable mip map as we don't have them anymore * Re-edited changelog * Use SRP macros in shader Co-authored-by: sebastienlagarde <[email protected]> * Fix upgrade cookie planar size (#6104) * Fixed the size of the planar reflection / cookie atlas after an upgrade of the HDRP asset * Updated changelog * Fixing merge issue for SSR transparent * Fix universal and yamato after merge. * fixuniversal after merge * renormalize files * Update 9801_ShurikenLightModule.unity * Make isEditorCameraPreview and sky public (#6147) * Update HDAdditionalCameraData.cs * Update SkySettings.cs * Update 9801_ShurikenLightModule.unity * Update HDAdditionalCameraData.cs * Update 9801_ShurikenLightModule.unity * Fixing ray tracing tests (#6158) * Fixed transparent SSR for shader graph. (#6163) * - Fixed transparent SSR for shader graph. * changelog * Added old graphics tests and modifications (#6143) * Update scenes * update blendstates * added OSX reference images * win reference images * fix lit light difference * Update blendstates-c-lit-unlit * disable check memory alloc due to ref probe issues * update ref images * rename test 1709 to 1711 * rename test 1709 to 1711 - bis Co-authored-by: sebastienlagarde <[email protected]> * Fix issue with blend mode and with keyword (#6164) * Fixed an issue with emissive light meshes not being in the RAS (#6174) * Hdrp/pt8 (#6090) * Added support for anisotropy. * Tidied the code up, plus moved to correlated G term for aniso GGX. * Added anisotropic refractive sampling. * Disable path tracing for the shading graph preview camera. * Added support for alpha culling. * Fixed issue with transmission rays. * Updated Changelog. * Added support for punctual and directional light cookies. * Updated Changelog. * Added support for area light cookies. * Fixed bug with area cookies atlas not being properly generated when rebuilding library. * Made sure maxDepth > minDepth always, and added support for AO from mask. * Added support for transparent shadows. * Updated Changelog. * Toggling path tracing on/off does not reset iteration anymore. * Reverted change on enable, was causing minor issues. * Made sure we don't have transparent behaviour when shader is set to opaque. * Minor changes. * Tweaks on transparency behaviour. * Updated changelog. * Added path-tracing specific payload. * Added support for iridescence. * Updated Changelog. * Added multiple scattering compensation for specular. * Added Path tracing test. * PT test part 2. * Updated Changelog. * Added proper area light range attenuation. * Fixed issue with alpha clipping in ray-tracing. * Cosmetic. * Fix on the rect area light range. * In the editor, dragging manipulators around now resets accumulation. * Added material dirtiness tracking. * Does not apply intensity clamping to camera rays. * Reste PT iteration when saving a shader graph. * Added dirtiness tracking for acceleration structure and lights. * Added support for bg color. * Minor change to progress bar display. * Minor change to iteration counter, so that it never goes over the max. * Updated path tracing test. * Added finer estimates of lights during global pdf computation. * Refined light estimates during light list creation. * Updated PT test after changes to light sampling. * Minor change on samples count dirtiness handling. * Cosmetic, plus include guards. * Separated the path intersection structure from the ray tracing one. * Cosmetic, plus taking SSS weight into account to reduce diffuse. * Added SSS support for path tracing, and made some minor changes to the ray-traced version. * Minor code refactor. * ... * ... * Post-merge cleansing. * Fixed minor issues in CreateMaterialData(). * Fixed issue with test framework and resolution change. * Avoid error msg on null instance in PathTracing.cs. * Pathtracer new automated scenes (#6053) * Add global GI automated test scene * Adding transparency test scene * Update max samples of transparency scene to 32 * Added area light test scene / Updating reference image * Transparency scene settings + ref image * Scene added to build (Editor build settings) * Update tranparency image ref * Updating scene to 1 spp and ref image Also moving the asset to common assets folder * Re-added support for unlit shader graph. Co-authored-by: remi-chapelain <[email protected]> * Update RTSSS Screenshots (#6177) * Fix DX12 and DXR Player build and Updating the test screenshots for DXR player tests (#6130) * Fix DX12 and DXR Player build Updating the test screenshots for DXR player tests * fix shader graph case Co-authored-by: sebastienlagarde <[email protected]> * Update CHANGELOG.md * Fix shader compilation issue with Vulkan and Raytracing (#6181) * update path tracing and 1219 test * Fix hdasset migration code not being called after a package upgrade (#6179) * Fix the HDRP asset migration code not being called after a package upgrade * Updated changelog Co-authored-by: sebastienlagarde <[email protected]> * Fix custom pass out of bounds (#6176) * Fix draw renderers custom pass out of bound exception * Updated changelog Co-authored-by: sebastienlagarde <[email protected]> * Fix PBR master node (#6182) * Fix PBR shader render states * Updated changelog * Fix some typos in the debug menu (#6097) * fix some typos * Revert typo fix that break public API * Changelog * Add regenerated shader includes Co-authored-by: sebastienlagarde <[email protected]> * Fixed ray traced point and spot lights shadows not rejecting history when semi-transparent or colored. (#6108) * Fixed ray traced point and spot lights shadows not rejecting history when semi-transparent or colored. * Removing unwanted skip closest hit Co-authored-by: sebastienlagarde <[email protected]> * Diffuse Shadow Denoiser Improvement. (#5851) * - Added a new mode that improves the filtering of ray traced shadows (directional, point and spot) based on the distance to the occluder. Added new test scenes to test the denoiser improvement * Update changelog * Fix an issue with the shadow denoiser grabiing data outside of the screen * changing light parameter to internal * Fixed a warning due to StaticLightingSky when reloading domain in some cases. (#6193) * Fixed the MaxLightCount being display when the light volume debug menu is on ColorAndEdge. (#6211) * Fixed the MaxLightCount being display when the light volume debug menu is on ColorAndEdge. * Update com.unity.render-pipelines.high-definition/CHANGELOG.md Co-Authored-By: Motiejus Viltrakis <[email protected]> Co-authored-by: sebastienlagarde <[email protected]> Co-authored-by: Motiejus Viltrakis <[email protected]> * Update documentation to mention more explicitely the lack of support of vertex animation (#6207) * Update documentation to mention more explicitely the lack of support of vertex animation * Update Ray-Tracing-Getting-Started.md Co-authored-by: sebastienlagarde <[email protected]> * Make subsection in decal debug menu to specify "affect transparents" (#6200) * Make subsection in decal debug menu * changelog Co-authored-by: sebastienlagarde <[email protected]> * Added coverage for Enabled GPU Instanced material (#6183) For light layers automated test * Support cookie on light backing for Disc Area Light (#6138) * Added support for light cookies in the baking backends. * Updated light conversion script to reflect the latest changes made to the API. * Added support for directional light cookie sizes. * Added support for cookies on rectangular area lights. * Enable Area::Disc Light on backing with cookie * Update ChangeLog * Update CHANGELOG.md Co-authored-by: uygar <[email protected]> Co-authored-by: sebastienlagarde <[email protected]> * Hdrp /lookdev/fix crash on adding volume as viewed game object (#6129) * Update Volume's Layer when moving them to LookDev's stage * Update CHANGELOG.md Co-authored-by: sebastienlagarde <[email protected]> * Add smoothness remark (#6226) * Removed unexpected file * Removed legacy VR code from HDRP (#5923) * Removed legacy VR code * do not set CullingOptions.Stereo with xrsdk * re-add and tag previous function signature as obsolete Co-authored-by: sebastienlagarde <[email protected]> * Improve light clipping and culling #2 (#4711) * Improve area light culling * Simplify * Clip box lights at the attenuation range * Save 1x ALU * Add missing feature flags * Chanelog Co-authored-by: EvgeniiG <7ee2cc898cca1b5fc49df740c2081dfc681e0a28> Co-authored-by: Sebastien Lagarde <[email protected]> * Hdrp/fix/decal material ui errors (#6225) * Fixed error in the console when switching shader to decal in the material UI * Updated changelog Co-authored-by: sebastienlagarde <[email protected]> * Fix z-fighting in sceneview when scene lighting is off (#6213) * Do not override the depth state of transparent materials in RenderDebugView * Changelog * Changelog - add case number Co-authored-by: sebastienlagarde <[email protected]> * Mention default post processing in default volumes. (#6232) * Fix cubemap inspector so that thumbnail for cubemap work (#6231) * Fix for missing thumbnail on cubemaps * Changelog * Better default angles Co-authored-by: sebastienlagarde <[email protected]> * fix ray tracing with VR single-pass (#6242) * - Fix an exception in ray tracing that happens if two LOD levels are using the same mesh renderer. (#6198) Co-authored-by: sebastienlagarde <[email protected]> * update location of reference screenshots after merge * Added debug exposure to light hierarchy debug. (#6215) Co-authored-by: sebastienlagarde <[email protected]> * - Rejecting history for ray traced reflections based on a threshold evaluated on the neighborhood of the sampled history. (#6251) Co-authored-by: sebastienlagarde <[email protected]> * Hdrp/pt9 (#6184) * Added support for anisotropy. * Tidied the code up, plus moved to correlated G term for aniso GGX. * Added anisotropic refractive sampling. * Disable path tracing for the shading graph preview camera. * Added support for alpha culling. * Fixed issue with transmission rays. * Updated Changelog. * Added support for punctual and directional light cookies. * Updated Changelog. * Added support for area light cookies. * Fixed bug with area cookies atlas not being properly generated when rebuilding library. * Made sure maxDepth > minDepth always, and added support for AO from mask. * Added support for transparent shadows. * Updated Changelog. * Toggling path tracing on/off does not reset iteration anymore. * Reverted change on enable, was causing minor issues. * Made sure we don't have transparent behaviour when shader is set to opaque. * Minor changes. * Tweaks on transparency behaviour. * Updated changelog. * Added path-tracing specific payload. * Added support for iridescence. * Updated Changelog. * Added multiple scattering compensation for specular. * Added Path tracing test. * PT test part 2. * Updated Changelog. * Added proper area light range attenuation. * Fixed issue with alpha clipping in ray-tracing. * Cosmetic. * Fix on the rect area light range. * In the editor, dragging manipulators around now resets accumulation. * Added material dirtiness tracking. * Does not apply intensity clamping to camera rays. * Reste PT iteration when saving a shader graph. * Added dirtiness tracking for acceleration structure and lights. * Added support for bg color. * Minor change to progress bar display. * Minor change to iteration counter, so that it never goes over the max. * Updated path tracing test. * Added finer estimates of lights during global pdf computation. * Refined light estimates during light list creation. * Updated PT test after changes to light sampling. * Minor change on samples count dirtiness handling. * Cosmetic, plus include guards. * Separated the path intersection structure from the ray tracing one. * Cosmetic, plus taking SSS weight into account to reduce diffuse. * Added SSS support for path tracing, and made some minor changes to the ray-traced version. * Minor code refactor. * ... * ... * Post-merge cleansing. * Fixed minor issues in CreateMaterialData(). * Fixed issue with test framework and resolution change. * Avoid error msg on null instance in PathTracing.cs. * Pathtracer new automated scenes (#6053) * Add global GI automated test scene * Adding transparency test scene * Update max samples of transparency scene to 32 * Added area light test scene / Updating reference image * Transparency scene settings + ref image * Scene added to build (Editor build settings) * Update tranparency image ref * Updating scene to 1 spp and ref image Also moving the asset to common assets folder * Fog support WIP... * Added support for fog attenuation. * Cosmetic. * Set a maxSampleCount to 1 for tests only in play mode. * Updated Changelog. * Cosmetic. * Take min and max depth into account for fog color. * Make sure we are inside the light cluster when buidling light list. * Simplified signature of RenderPathTracing() func, replaced RaytracingFrameIndex with RaytracingSampleIndex. * Taking max fog distance into account. * Fog max dist part2. * Added a new test scene for the fog * move reference screenshots Co-authored-by: remi-chapelain <[email protected]> Co-authored-by: Remi Chapelain <[email protected]> Co-authored-by: Sebastien Lagarde <[email protected]> * Hdrp/volume debug (#6058) * New widget DebugUI.Table * Opened some Volume related API * New volume debug panel * Fixed a bug when debugging editor cameras * Fixed table border color. Updated documentation * Handles inactive and removed components * Don't show deprecated volume components. Sort by name * Revert unwanted modification * Handle disabled volumes * Hides volumes that don't affect the final value * Code documentation * Add range check * Fix player build * Fix volume influence detection * Refresh display when components changes * Fix error on player build * Reduce popping * Use editor camera as anchor point * Select all layers for the scene camera * Un-open profileRef API * Remove ref to profileRef * Proper component name, show text for non supported parameters * Fix profile duplication when using volume debug menu * Updated unsupported parameters message. Show a name as fallback if it exists Co-authored-by: sebastienlagarde <[email protected]> * Fixing HDRP_DXR_TEST not having local package at right location (#6107) * Clearer naming of tile and cluster categories for environment lights (#6227) * Rename Environment to Probes * changelog Co-authored-by: sebastienlagarde <[email protected]> * Fixed an issue with refraction model and ray traced recursive rendering (case 1198578). (#6267) Co-authored-by: sebastienlagarde <[email protected]> * fix for Fogbugz 1214609 - HDRP Wizard addively increases the Light Intesity instead of setting it (#6266) * Fixed an issue where a dynamic sky changing any frame may not update the ambient probe. (#6235) * Fixed an issue where a dynamic sky changing any frame may not update the ambient probe. * Update changelog Co-authored-by: sebastienlagarde <[email protected]> * Add XR setting to control camera jitter for temporal effects (#6259) * add XR setting to control camera jitter for temporal effects * cleanup unused code path * revert changes to scenes * Deprecate Utilities namespace (#6219) * (case 1204677) Copied namespace Utility to UnityEngine.Rendering and made it obsolete. * Updated changelog * Updated comment * Updated comment Co-authored-by: sebastienlagarde <[email protected]> * Remove deprecated namespace Utilities. [Requires #6219] (#6220) * (case 1204677) Copied namespace Utility to UnityEngine.Rendering and made it obsolete. * Updated changelog * Updated comment * Removal of deprecated API * Updated changelog * Remove deprecated api Co-authored-by: Sebastien Lagarde <[email protected]> * Fix issue on thumbnail generation so that no error on new project and thumbnail are generated at first import (#6265) * Fix issue with static preview for cubemap being called without a material initialized * Fix the issue preventing thumbnail to be preserved upon reimport on load * Comment * changelog * Change asset swap to legacy method * comment and white line removal * Fix for baked probe import cycle * Added comment * Oops missing a file Co-authored-by: sebastienlagarde <[email protected]> * Add custom pass opaque rendering error message (#6330) * Added an error message when rendering opaque objects with an HDRP asset in DeferredOnly mode * Updated custom pass doc * Updated changelog * Fix issue of debug display variant with shader graph not compiling (#6325) * move #define DEBUG_DISPLAY into debugdisplay.hlsl * fix builtindata * fix includes * fix shader * fix XR culling with multiple cameras (#6314) Co-authored-by: sebastienlagarde <[email protected]> * fix XR single-pass with Mock HMD plugin (#6313) Co-authored-by: sebastienlagarde <[email protected]> * fix sRGB mismatch with XR SDK (#6311) Co-authored-by: sebastienlagarde <[email protected]> * Partial fix LookDev opened when CoreRP package reimported (#6291) * Fix null texture usage happening on CoreRP upgrade * Partially fix garbage collected stylesheet issue. (Need more work on UIElement side, see case 1228706 ) * Update CHANGELOG.md * Clean log Co-authored-by: sebastienlagarde <[email protected]> * Hdrp/fix default volume switch (#6250) * Fixed an issue where default volume would not update when switching profile. * Update changelog * Fixed an issue when setting the default volume for the first time where the hdrp asset would not be dirtied Co-authored-by: sebastienlagarde <[email protected]> * Reflection probe cameras are now created with the correct type (#6245) Co-authored-by: sebastienlagarde <[email protected]> * Fixed an issue where AO override would not override specular occlusion. (#6222) * Fixed an issue where AO override would not override specular occlusion. * Update changelog Co-authored-by: sebastienlagarde <[email protected]> * Fixed an issue where Volume inspector might not refresh correctly in some cases. (#6252) * Fixed an issue where Volume inspector might not refresh correctly in some cases. * Update changelog Co-authored-by: sebastienlagarde <[email protected]> * render XR mirror view only for camera with no RT (#6306) Co-authored-by: sebastienlagarde <[email protected]> * Split set rendering feature set and API validity check (#6301) * Split set rendering feature set and API validity check * changelog Co-authored-by: sebastienlagarde <[email protected]> * Hdrp/probe scale 1219246 (#6288) * Fix when scale down < 0 all direction of box Influence Volume * Update Change log * Hdrp/fix/particle light shadows (#6111) * Tried to fix particle light shadows * Fixed particle shadows * Updated changelog Co-authored-by: sebastienlagarde <[email protected]> * Recording of accumulation motion blur and path tracing (#6114) * Pt and accumulation motion blur recording Fix merge issues Fix merge issues #2 Bugfix: accumulation with one sample Chengelog Don't set the fixed-time in the subframe manager - should be set in the recorder Properly set and reset the fixed time Updated documentation Small fix to make physics simulation work with scaled time / accumulation mb Post rebase fixes and disable accumulation when using only one sub-frame * Fix post merge issues * hdrp resources asset file * remove duplicate code * Move most compute shaders to use multi_compile API (#6307) * Squashed commit of the following: commit ed9e485efc69a7949e34f0512666d522470dc73e Author: FrancescoC-Unity <[email protected]> Date: Fri Mar 20 11:47:59 2020 +0100 Revert "Squashed commit of the following:" This reverts commit 0dd46577be82abeaefc839cbcd9f3875b05d48e6. commit 0dd46577be82abeaefc839cbcd9f3875b05d48e6 Author: FrancescoC-Unity <[email protected]> Date: Fri Mar 20 10:39:28 2020 +0100 Squashed commit of the following: commit 0e1815814ce8204cfa42ae3050ba655fe769c550 Merge: ac6809ec032 2b018dfe8a9 Author: Sebastien Lagarde <[email protected]> Date: Thu Mar 19 18:19:45 2020 +0100 Merge branch 'master' into HDRP/staging commit 2b018dfe8a9f5f304e4b95d6279dda60f632c9dc Author: sebastienlagarde <[email protected]> Date: Thu Mar 19 18:19:02 2020 +0100 Merge Hdrp/staging (#6293) * Custom pass cleanup (#5507) * Fix custom pass cleanup issue with multiple volumes * Updated changelog * Delay discard of fragments during decal projection (#5283) * Delay discard of fragments during decal projection Metal Shading Language declares that fragment discard invalidates derivatives for the rest of the quad, so we need to reorder when we discard during decal projection, or we get artifacts along the edges of the projection (any partial quads get bad partial derivatives regardless of whether they are computed implicitly or explicitly). * Better re-arrangement of decal code * Update TerrainLitPasses.hlsl * Update TerrainLitPasses.hlsl * Update TerrainLitPasses.hlsl * Update ShaderPassDecal.hlsl Co-authored-by: sebastienlagarde <[email protected]> * Fixing unnecessary memory allocations in the ray tracing cluster build and Updating the screen shots for the ray tracing tests (#5465) * Fixing unnecessary memory allocations in the ray tracing cluster build Updating the screen shots for the ray tracing tests * Update test scene and screenshots * - Discarding the ray tracing history for AO, reflection, diffuse shadows and GI when the viewport size changes. - Update and disable some tests that still need to be updated * Add a counter for ray tracing frame index and update screenshots * Fixing the Area Shadows Denoiser Test Co-authored-by: sebastienlagarde <[email protected]> * Change the default volume used by the ray tracing tests to make them work again (#5510) * Change the default volume used for the ray tracing tests, fixes the tests back. * Fix access to the ray tracing frame index in ray tracing ambient occlusion (doesn't change behavior) * Missing term in the ray tracing frame index access (#5511) * Fix colum headers (#5517) * Fix colum headers * Update CHANGELOG.md * Rename post formats (#5505) * Renamed the post processing format to the new convention * Updated changelog Co-authored-by: sebastienlagarde <[email protected]> * Fixed the first frame flash with auto exposure (#5491) * Fixed flashes with low and high exposure scenes when Automatic Exposure is in use * Moved postfx history reset to per-camera reset Co-authored-by: sebastienlagarde <[email protected]> * Update DefaultSettingsVolumeProfile.asset * Hdrp/small enhencements for DXR (#5493) * Add Warning for DXR and AsyncExecution in FrameSettings * move restarting at end of all fix in wizard for DXR * Update CHANGELOG.md Co-authored-by: sebastienlagarde <[email protected]> * Hdrp/update default scenes (#5485) * Replace default scenes with scene prepared for scene-template * Update of DefaultSettingsProfile * Update DXR scene * Add ScreenSpaceShadow to Camera's default FrameSettings * Update CHANGELOG.md Co-authored-by: sebastienlagarde <[email protected]> * Refactoring pre-existing materials to share code between rasterization and ray tracing (#5441) * Refactoring pre-existing materials to share code between rasterization and ray tracing Update the test scene * update changelog * Changing the color of an unlit in the reflection test scene * review corrections * Fixing unlit shader graph * Fix specular AA related issue * Update the reflection test * Fix an issue with debug display for ray tracing shaders Always use ray tracing frame index 0 for ray tracing tests Update tests screenshots Update ray traced reflection test scene Co-authored-by: sebastienlagarde <[email protected]> * Hdrp/staging thin (#5509) * Adding a REFRACTION_THIN model. * Fixed thin distance. * ... and fixed it. * Updated changelog, removed unused REFRACTION attrs from Fabric template. * Added a REFRACTION_THIN_DISTANCE macro. * Finished support for thin refraction. * Fixed LitTesselation (was missing thin refraction model). * fix issue when merging Refactoring of DoAlphaTest * Fixed an issue where passing a null ProfilingSampler would cause a null ref exception. (#5555) * Fixing the area shadow denoised test (#5544) * Fix leak in Sky when matcap view (#5556) * skip pre render sky in matcap view * changelog Co-authored-by: sebastienlagarde <[email protected]> * Fix compilation issues of ApplyExposure on platforms that don't support VR (#5575) * Fix * changelog * Remove Preview from physically based sky * HDRP asset migration (#5580) * Initialize the HDRP asset version to the latest one so new assets are not migrated * Updated changelog * Hdrp/remove wind resources (#5578) * Remove wind resources Remove wind resources no longer used and containing big files * Update changelog * revert: Hdrp/update default scenes (#5485) * Fix issue with missing texture in test * Disable POM test in 1708 SG_OnSG as it is unstable * Add missing texture in runtime test * update caption for geometric normal debug in forward * add missing texture to runtime test * Create Textures.meta * fix SG on decal SG * Fixed an issue where ambient occlusion and screen space reflections editors would generate null ref exceptions when HDRP was not set as the current pipeline. (#5577) * Fixed a null reference exception in the probe UI when no HDRP asset is present. (#5582) * Fixed a null reference exception in the probe UI when no HDRP asset is present. * Indentation Co-authored-by: sebastienlagarde <[email protected]> * Fix custom pass outline (#5590) * Fixed custom pass outline resolution screen resolution dependent * Updated changelog Co-authored-by: sebastienlagarde <[email protected]> * Fixed a null reference exception in the HDRI Sky editor when no HDRP asset is present. (#5596) Co-authored-by: sebastienlagarde <[email protected]> * Fix decal orientation when created from script. (#5592) * Fixed all migration classes to default to latest version so that Decals created by script to get migrated. Fixed decal created through context menu so that they get the proper rotation convention. * Update changelog * Moved the GetEnumLastValue to TypeInfo class * Updated super old test scenes to the proper latest version for decals Co-authored-by: sebastienlagarde <[email protected]> * Refactor of HDCamera (accesibility mostly) [Skip CI] (#5548) * Refactor of HDCamera - Made internal/private APIs that should not have been public - Fixed naming convention for private members - Moved everything by accessibility for clarity (public, internal, then private) * Added Doc and returned some API public. * Fix visibility of Density Volumes in reflections [Skip CI] (#5589) * Oblique projection frustum fix, first try * HDCamera frustum now recalculates near and far plane to avoid issues with oblique projection matrices. * Update changelog * Added comments * Indentation * Fixed camera relative position of frustum * Indentation * Fixed a null reference exception in Path Tracing, Recursive Rendering and raytraced Global Illumination editors when no HDRP asset is present. (#5597) Co-authored-by: sebastienlagarde <[email protected]> * Fix ray tracing tests and add a test scene for lights and cookies in ray tracing (#5604) * expose StartSinglePass() and StopSinglePass() as public interface for XRPass (#5605) * Add missing custom pass API documentation (#5530) * Add missing custom pass API documentation * Fix doc spells and grammar * Stencil Refactor and Material migration fixes (#5581) * Remove leftover code * commit to switch machine * Remove hard coded stencil values in shaders * clear stencil * tmp commit, start of splitting decal in dbuffer and normal patchup * Make decal patching up run after GBuffer * Remove hardcoded value for SSS split lighting * Tmp commit to switch branch * Finalize build coarse stencil (with debug leftover and render graph NOT handled) * The AA bits (the easy one :-) ) * split in two enums * Distortion vectors bit sorted * SSR bit * Motion vector bit * decals bit * Lighting bits * Use HTile for SSR * HTile SSS -> Incomplete, verify and test. * SSS fixes, but still not working (probably not HTile related, but main stencil) * Make decal patch normal work and remove stencil bit * some leftover fixes * was commited by mistake * Update materials * Revert "Update materials" This reverts commit 4a0de82ef51750b77546020d77ad6b5d773e60af. * Fix issues with MSAA and with migration * Forgot this out * update materials and maps * default materials * don't have SSR on unlit * Fix some leftovers * Renaming * Revert "update materials and maps" This reverts commit 103f1cb71d8fffa49b0c2ef57f1b41b36d0a3dbf. * Revert "default materials" This reverts commit 978740acd825562717a01437dcc0c74fc4cfefb0. * Fix migration * white line * Fix migration * Add render queue overide to the material placer. Also add PackageInfo.cs to HDRP, so the graphic tests can call it's internal methods and objects. * Default material post migration * com.unity.testing.hdrp post reimport * Updated materials from test * Disable tests that are to be updated or not needed anymore * Fix VFX issues (To be fixed better by @PaulDemeulenaere ) * Lit hardcoded default was off * Update VFX Test materials ( @PaulDemeulenaere for awareness ) * Fix issue with stencil in TAA * Revert lighting data * revert light map data * Revert other lighting asset * Cleanup post processor. * Update DXR test material * Update commnets * Early (need testing) new migration workflow * Revert "Early (need testing) new migration workflow" This reverts commit 2db025002d66165dd00e90f5f5d3c944ed53f361. * Update post processor * Add manual option to migrate * Add dialog box Co-authored-by: RemyUnity <[email protected]> * Push updated hdrp version in test project (#5617) * Push m_LastMaterialVersion update * Dont open dialog on yamato * Update test projects with recent stencil refector PR (#5618) * Update runtime test project * Create HDRPProjectSettings.asset * update DXR project * Revert "update caption for geometric normal debug in forward" This reverts commit 150d68279b891529be272b37f374c36b879646f4. * Run reimport during update (to avoid unwanted extra dialog during dialog box) (#5620) * Make user stencil bits public (#5616) * Expose bits to user * Update documentation * Update HDStencilUsage.cs Co-authored-by: sebastienlagarde <[email protected]> * Implement history rejection based on object velocity (#5532) * Implement history rejection based on object velocity * Update changelog * Fix an issue with ambient occlusion denoising being broken after adding the history rejection feature Adding the GPU Light type for history validation and rejection Co-authored-by: sebastienlagarde <[email protected]> * Fixed initial state of material created through the context menu. (#5603) * Fixed an issue where materials newly created from the contextual menu would have an invalid state, causing various problems until it was edited. * Forgot DecalUI (for non shader graph decals) Co-authored-by: sebastienlagarde <[email protected]> * Update HDLightUI.Skin.cs * Cookie and planar atlas (#5518) * Added support for cookie atlas * Begin to move planar reflection into atlas * Added texture atlas for planar reflection probe plus a limit to on screen planar probes * Removed debug log * Fixed planar probe atlas scale issue and useless mipmap generation of the atlas * Refactor Texture2D atlas * Move ScaleBias for planar probes to a separate list * Fix cookie mode for directional lights * Added error log for non square cookie textures in the atlas * Fix merge * Fixed cookie atlas * Trying to fix area light cookies * Fixed area light cookie * Disable mipmap for non area light cookies * Added cookie atlas format control + fixed size warnings in HDRP cookie ui * Add resolution in Capture Settings reflection probe drawer * Removed warnings * Added the point light cookie texture array in the debug menu * Fix cookies in ray tracing + celestial body texture * Update dynamic light cookie screenshot * Update Animated cookie test + fix reflection probe texture format * Fix area light cookie * Update HDRP asset cookie and planar atlas sizes * Increase cookie atlas size for area light test * Simplify code * Fix cookie mip clamp * Fixed compilation and CG alloc * Added atlas layouting when there is no more space * Fix directional light cookie * Updated reference image of cookie area lights * Fix hardcoded format and cookie layout * Remove useless mip update * Fix area light cookie x flip * Added the debug exposure option for debug planar reflection atlas * reverted the fix for area light cookie x flip * Tried to simplify the code of the atlas * Update reference image * Added an error when max planar reflection probe on screen is reached * Fixed space parenthesis * Fixed mipmap not updated properly and area light cookie convolution temp texture format * Fixed atlas reset mips * Update tooltip and fixed cookie insertion order when there is no more space in the atlas * Enable exposure on cookie atlas debug * Fix debug overlap * Update reference image * Added migration code for the cookie atlas size and fixed point light cookie debug exposure * Added planar atlas size upgrade code * Updated planar reflection atlas message * Fixed resolution dependent cookie mip maps * Updated changelog * Fixed cookies for ray tracing * Fix cookie in the ray tracing light loop requested without being reserved * Clamp UV when doing the area light convolution * Update reference images * Remove debug symbols * Fixed area light convolution UV limit * Fixed half pixel clamp and updated reference images * Fixed planar reflection mip map edge bleeding and update reference images * Updated more image reference * Updated DXR cookie test scene * Fix default material transparent created with ZWrite enabled (#5621) * Fixed transparent material craeted with ZWrite enabled * Updated changelog Co-authored-by: sebastienlagarde <[email protected]> * Hdrp/fix decal gizmo mouseover (#5626) * Remove controlID on projection direction of DecalProjector that conflict with other handles * Update CHANGELOG.md Co-authored-by: sebastienlagarde <[email protected]> * Hdrp/smallfixes lookdev (#5619) * Fix zoom being stuck around 0 * fix crash forbiding view manipulation while using directly hdri without passing by an environment * Fix hitch in FPS displacement mode * Fix when user destroy the EnvironmentLibrary being used. * Update CHANGELOG.md Co-authored-by: sebastienlagarde <[email protected]> * Mask was never set for some debug pixel deferred shaders [Skip CI] (#5627) * Mask was never set * changelog * Added comments Co-authored-by: sebastienlagarde <[email protected]> * Fixed an issue where creating decals at runtime could cause a null reference exception. (#5594) Co-authored-by: sebastienlagarde <[email protected]> * Make APIs internal when they should be - 1 - [Skip CI] (#5531) * First pass of making APIs internal when they should be. * Indentation * Compilation fixes + review feedback. * Make APIs internal when they should be - 2 - [Skip CI] (#5533) * First pass of making APIs internal when they should be. * Indentation * WIP * Missing file * More * Revert some changes based on review feedback * Compilation fix * Compilation fixes + review feedback. * Updated HDUtils accessibility * More editor internals. * Better (not hardcoded) stencil handling in VFX (#5624) * Stencil update for vfx * Fix issues * fix missing templates * Avoid displaying material upgrader dialog on new project (#5631) * Don't run dialog on new project creation * skip only on first creation * Check file existence before showing dialog * typo * Push test materials after ZWrite PR (#5632) * Update HDRP_Test project * Update DXR test assets * Update run time tests * Discard invalid pixels when doing deferred lighting in compute (for camera stacking) (#5339) * Discard invalid pixels when doing deferred lighting in compute (as required for camera stacking) Small comment modification Update changelog * Use stencil buffer (instead of normals) to discard pixels in deferred compute * Remove not required if statement when binding the stencil * Small fixes to API visibility. (#5637) * Fixed some more public APIs to internal. * Made hasCustomRender public again. * Moved the tier defining from the asset to the concerned volume components. (#5519) * Alpha post-processing bugfixes and improvements (#5512) * Bug fix for post processing alpha with chrommatic aberation + minor fixes * Avoid double blending in DOF * Unit tests for alpha post-processing (TAA/DoF) Vulkan test images Vulkan meta files * Fix runtime tests (#5639) * Update runtime test screenshots * Update planar resolution * Add test (#5641) * fix material and project settings for VFX (#5642) * Revert change to GBuffer (normalbuffer usage) as it broke the raytracing code * Fix various issues with time and animated materials (#5480) * Fix various issues with time and animated materials * Changelog * Add getters * Only update time once per frame * Fix animation in reflection * Fix null ref exception * Re-applied code after impossible merge. * Comment change * Remove commented code. Co-authored-by: JulienIgnace-Unity <[email protected]> Co-authored-by: sebastienlagarde <[email protected]> * fix graphic test (#5651) * renaming test 1901 -> 1451 and 1709 -> 1710 * Update EditorBuildSettings.asset * Update 1710_Decals_Normal_Patch.png * update screenshots * update scene backgroud * Update manifest.json * Update decal patch screenshots * update 4052_TAA * Changing the tier system for a preset mode system and removing unnecessary options (#5646) * Changing from a tier management to a "mode" management for reflection and GI and removing the ability to enable/disable deferred and ray bining (they are now implied by performance mode) * Update the scene scenes * Update changelog * Fixing an instability with the light shado…
1 parent b68a599 commit c843738

File tree

17 files changed

+164
-55
lines changed

17 files changed

+164
-55
lines changed
Lines changed: 2 additions & 2 deletions
Loading
Lines changed: 2 additions & 2 deletions
Loading

com.unity.render-pipelines.core/Editor/Volume/VolumeComponentListEditor.cs

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,24 +16,24 @@ namespace UnityEditor.Rendering
1616
/// in the inspector:
1717
/// <code>
1818
/// using UnityEngine.Rendering;
19-
///
19+
///
2020
/// [CustomEditor(typeof(VolumeProfile))]
2121
/// public class CustomVolumeProfileEditor : Editor
2222
/// {
2323
/// VolumeComponentListEditor m_ComponentList;
24-
///
24+
///
2525
/// void OnEnable()
2626
/// {
2727
/// m_ComponentList = new VolumeComponentListEditor(this);
2828
/// m_ComponentList.Init(target as VolumeProfile, serializedObject);
2929
/// }
30-
///
30+
///
3131
/// void OnDisable()
3232
/// {
3333
/// if (m_ComponentList != null)
3434
/// m_ComponentList.Clear();
3535
/// }
36-
///
36+
///
3737
/// public override void OnInspectorGUI()
3838
/// {
3939
/// serializedObject.Update();
@@ -58,6 +58,8 @@ public sealed class VolumeComponentListEditor
5858
Dictionary<Type, Type> m_EditorTypes; // Component type => Editor type
5959
List<VolumeComponentEditor> m_Editors;
6060

61+
int m_CurrentHashCode;
62+
6163
/// <summary>
6264
/// Creates a new instance of <see cref="VolumeComponentListEditor"/> to use in an
6365
/// existing editor.
@@ -195,9 +197,12 @@ public void OnGUI()
195197
if (asset == null)
196198
return;
197199

198-
if (asset.isDirty)
200+
// Even if the asset is not dirty, the list of component may have been changed by another inspector.
201+
// In this case, only the hash will tell us that we need to refresh.
202+
if (asset.isDirty || asset.GetHashCode() != m_CurrentHashCode)
199203
{
200204
RefreshEditors();
205+
m_CurrentHashCode = asset.GetHashCode();
201206
asset.isDirty = false;
202207
}
203208

com.unity.render-pipelines.core/Editor/Volume/VolumeProfileFactory.cs

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,12 +56,22 @@ public static VolumeProfile CreateVolumeProfile(Scene scene, string targetName)
5656
{
5757
var scenePath = Path.GetDirectoryName(scene.path);
5858
var extPath = scene.name;
59-
var profilePath = scenePath + "/" + extPath;
59+
var profilePath = scenePath + Path.DirectorySeparatorChar + extPath;
6060

6161
if (!AssetDatabase.IsValidFolder(profilePath))
62-
AssetDatabase.CreateFolder(scenePath, extPath);
62+
{
63+
var directories = profilePath.Split(Path.DirectorySeparatorChar);
64+
string rootPath = "";
65+
foreach (var directory in directories)
66+
{
67+
var newPath = rootPath + directory;
68+
if (!AssetDatabase.IsValidFolder(newPath))
69+
AssetDatabase.CreateFolder(rootPath.TrimEnd(Path.DirectorySeparatorChar), directory);
70+
rootPath = newPath + Path.DirectorySeparatorChar;
71+
}
72+
}
6373

64-
path = profilePath + "/";
74+
path = profilePath + Path.DirectorySeparatorChar;
6575
}
6676

6777
path += targetName + " Profile.asset";

com.unity.render-pipelines.core/Runtime/Volume/VolumeProfile.cs

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -279,5 +279,23 @@ public bool TryGetAllSubclassOf<T>(Type type, List<T> result)
279279

280280
return count != result.Count;
281281
}
282+
283+
284+
/// <summary>
285+
/// A custom hashing function that Unity uses to compare the state of parameters.
286+
/// </summary>
287+
/// <returns>A computed hash code for the current instance.</returns>
288+
public override int GetHashCode()
289+
{
290+
unchecked
291+
{
292+
int hash = 17;
293+
294+
for (int i = 0; i < components.Count; i++)
295+
hash = hash * 23 + components[i].GetHashCode();
296+
297+
return hash;
298+
}
299+
}
282300
}
283301
}

com.unity.render-pipelines.high-definition/CHANGELOG.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -507,6 +507,14 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
507507
- Fixed drag area width at left of Light's intensity field in Inspector.
508508
- Fixed light type resolution when performing a reset on HDAdditionalLightData (case 1220931)
509509
- Fixed reliance on atan2 undefined behavior in motion vector debug shader.
510+
- Fixed an usage of a a compute buffer not bound (1229964)
511+
- Fixed an issue where changing the default volume profile from another inspector would not update the default volume editor.
512+
- Fix issues in the post process system with RenderTexture being invalid in some cases, causing rendering problems.
513+
- Fixed an issue where unncessarily serialized members in StaticLightingSky component would change each time the scene is changed.
514+
- Fixed a weird behavior in the scalable settings drawing when the space becomes tiny (1212045).
515+
- Fixed a regression in the ray traced indirect diffuse due to the new probe system.
516+
- Fix for range compression factor for probes going negative (now clamped to positive values).
517+
- Fixed path validation when creating new volume profile (case 1229933)
510518

511519
### Changed
512520
- Color buffer pyramid is not allocated anymore if neither refraction nor distortion are enabled

com.unity.render-pipelines.high-definition/Editor/RenderPipeline/Settings/DefaultSettingsPanel.cs

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ public class Styles
4545
ReorderableList m_BeforeTransparentCustomPostProcesses;
4646
ReorderableList m_BeforePostProcessCustomPostProcesses;
4747
ReorderableList m_AfterPostProcessCustomPostProcesses;
48+
int m_CurrentVolumeProfileHash;
4849

4950
public void OnGUI(string searchContext)
5051
{
@@ -207,6 +208,13 @@ void Draw_VolumeInspector()
207208
}
208209
EditorGUILayout.EndHorizontal();
209210

211+
// The state of the profile can change without the asset reference changing so in this case we need to reset the editor.
212+
if (m_CurrentVolumeProfileHash != asset.GetHashCode() && m_CachedDefaultVolumeProfileEditor != null)
213+
{
214+
m_CurrentVolumeProfileHash = asset.GetHashCode();
215+
m_CachedDefaultVolumeProfileEditor = null;
216+
}
217+
210218
Editor.CreateCachedEditor(asset, Type.GetType("UnityEditor.Rendering.VolumeProfileEditor"), ref m_CachedDefaultVolumeProfileEditor);
211219
EditorGUIUtility.labelWidth -= 18;
212220
bool oldEnabled = GUI.enabled;
@@ -230,13 +238,13 @@ void Draw_VolumeInspector()
230238
hdrpAsset.defaultLookDevProfile = newLookDevAsset;
231239
EditorUtility.SetDirty(hdrpAsset);
232240
}
233-
241+
234242
if (GUILayout.Button(EditorGUIUtility.TrTextContent("New", "Create a new Volume Profile for default in your default resource folder (defined in Wizard)"), GUILayout.Width(38), GUILayout.Height(18)))
235243
{
236244
DefaultVolumeProfileCreator.CreateAndAssign(DefaultVolumeProfileCreator.Kind.LookDev);
237245
}
238246
EditorGUILayout.EndHorizontal();
239-
247+
240248
Editor.CreateCachedEditor(lookDevAsset, Type.GetType("UnityEditor.Rendering.VolumeProfileEditor"), ref m_CachedLookDevVolumeProfileEditor);
241249
EditorGUIUtility.labelWidth -= 18;
242250
oldEnabled = GUI.enabled;
@@ -311,7 +319,7 @@ static string GetDefaultName(Kind kind)
311319
}
312320
return defaultName;
313321
}
314-
322+
315323
public static void CreateAndAssign(Kind kind)
316324
{
317325
var assetCreator = ScriptableObject.CreateInstance<DefaultVolumeProfileCreator>();

com.unity.render-pipelines.high-definition/Editor/RenderPipeline/Settings/SerializedScalableSetting.cs

Lines changed: 43 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -136,29 +136,55 @@ ScalableSettingSchema schema
136136
static void MultiField<T>(Rect position, GUIContent[] subLabels, T[] values)
137137
where T: struct
138138
{
139+
// The number of slots we need to fit into this rectangle
139140
var length = values.Length;
140-
var num = (position.width - (float) (length - 1) * 3f) / (float) length;
141-
var position1 = new Rect(position)
142-
{
143-
width = num
144-
};
145-
var labelWidth = EditorGUIUtility.labelWidth;
141+
142+
// Let's compute the space allocated for every field including the label
143+
var num = position.width / (float) length;
144+
145+
// Reset the indentation
146146
var indentLevel = EditorGUI.indentLevel;
147147
EditorGUI.indentLevel = 0;
148+
149+
// Variable to keep track of the current pixel shift in the rectangle we were assigned for this whole section.
150+
float pixelShift = 0;
151+
152+
// Loop through the levels
148153
for (var index = 0; index < values.Length; ++index)
149154
{
150-
EditorGUIUtility.labelWidth = CalcPrefixLabelWidth(subLabels[index], (GUIStyle) null);
151-
if (typeof(T) == typeof(int))
152-
values[index] = (T)(object)EditorGUI.DelayedIntField(position1, subLabels[index], (int)(object)values[index]);
153-
else if (typeof(T) == typeof(bool))
154-
values[index] = (T)(object)EditorGUI.Toggle(position1, subLabels[index], (bool)(object)values[index]);
155-
else if (typeof(T) == typeof(float))
156-
values[index] = (T)(object)EditorGUI.FloatField(position1, subLabels[index], (float)(object)values[index]);
157-
else
158-
throw new ArgumentOutOfRangeException($"<{typeof(T)}> is not a supported type for multi field");
159-
position1.x += num + 4f;
155+
// Let's first compute what is the width of the label of this scalable setting level
156+
// We make sure that the label doesn't go beyond the space available for this scalable setting level
157+
var labelWidth = Mathf.Clamp(CalcPrefixLabelWidth(subLabels[index], (GUIStyle)null), 0, num);
158+
159+
// Draw the Label at the expected position
160+
EditorGUI.LabelField(new Rect(position.x + pixelShift, position.y, labelWidth, position.height), subLabels[index]);
161+
162+
// We need to remove from the position the label size that we've just drawn and shift by it's length
163+
pixelShift += labelWidth;
164+
165+
// The amount of space left for the field
166+
float spaceLeft = num - labelWidth;
167+
168+
// If at least two pixels are left to draw this field, draw it, otherwise, skip
169+
if (spaceLeft > 2)
170+
{
171+
// Define the rectangle for the field
172+
var fieldSlot = new Rect(position.x + pixelShift, position.y, num - labelWidth, position.height);
173+
174+
// Draw the right field depending on its type.
175+
if (typeof(T) == typeof(int))
176+
values[index] = (T)(object)EditorGUI.DelayedIntField(fieldSlot, (int)(object)values[index]);
177+
else if (typeof(T) == typeof(bool))
178+
values[index] = (T)(object)EditorGUI.Toggle(fieldSlot, (bool)(object)values[index]);
179+
else if (typeof(T) == typeof(float))
180+
values[index] = (T)(object)EditorGUI.FloatField(fieldSlot, (float)(object)values[index]);
181+
else
182+
throw new ArgumentOutOfRangeException($"<{typeof(T)}> is not a supported type for multi field");
183+
}
184+
185+
// Shift by the slot that was left for the field
186+
pixelShift += spaceLeft;
160187
}
161-
EditorGUIUtility.labelWidth = labelWidth;
162188
EditorGUI.indentLevel = indentLevel;
163189
}
164190

com.unity.render-pipelines.high-definition/Runtime/Lighting/LightLoop/LightLoop.cs

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1264,7 +1264,7 @@ internal void GetDirectionalLightData(CommandBuffer cmd, HDCamera hdCamera, Visi
12641264

12651265
lightData.shadowDimmer = additionalLightData.shadowDimmer;
12661266
lightData.volumetricShadowDimmer = additionalLightData.volumetricShadowDimmer;
1267-
GetContactShadowMask(additionalLightData, HDAdditionalLightData.ScalableSettings.UseContactShadow(m_Asset), hdCamera, true, ref lightData.contactShadowMask,ref lightData.isRayTracedContactShadow);
1267+
GetContactShadowMask(additionalLightData, HDAdditionalLightData.ScalableSettings.UseContactShadow(m_Asset), hdCamera, isRasterization: true, ref lightData.contactShadowMask,ref lightData.isRayTracedContactShadow);
12681268

12691269
// We want to have a colored penumbra if the flag is on and the color is not gray
12701270
bool penumbraTint = additionalLightData.penumbraTint && ((additionalLightData.shadowTint.r != additionalLightData.shadowTint.g) || (additionalLightData.shadowTint.g != additionalLightData.shadowTint.b));
@@ -1365,7 +1365,7 @@ bool EnoughScreenSpaceShadowSlots(GPULightType gpuLightType, int screenSpaceChan
13651365
}
13661366

13671367
internal void GetLightData(CommandBuffer cmd, HDCamera hdCamera, HDShadowSettings shadowSettings, VisibleLight light, Light lightComponent,
1368-
ProcessedLightData processedData, int shadowIndex, BoolScalableSetting contactShadowsScalableSetting, bool isRasterization, ref Vector3 lightDimensions, ref int screenSpaceShadowIndex, ref int screenSpaceChannelSlot, ref LightData lightData)
1368+
in ProcessedLightData processedData, int shadowIndex, BoolScalableSetting contactShadowsScalableSetting, bool isRasterization, ref Vector3 lightDimensions, ref int screenSpaceShadowIndex, ref int screenSpaceChannelSlot, ref LightData lightData)
13691369
{
13701370
var additionalLightData = processedData.additionalLightData;
13711371
var gpuLightType = processedData.gpuLightType;
@@ -2370,7 +2370,7 @@ void PrepareGPULightdata(CommandBuffer cmd, HDCamera hdCamera, CullingResults cu
23702370
LightData lightData = new LightData();
23712371

23722372
// Punctual, area, projector lights - the rendering side.
2373-
GetLightData(cmd, hdCamera, hdShadowSettings, light, lightComponent, m_ProcessedLightData[lightIndex], shadowIndex, contactShadowScalableSetting, isRasterization: true, ref lightDimensions, ref m_ScreenSpaceShadowIndex, ref m_ScreenSpaceShadowChannelSlot, ref lightData);
2373+
GetLightData(cmd, hdCamera, hdShadowSettings, light, lightComponent, in m_ProcessedLightData[lightIndex], shadowIndex, contactShadowScalableSetting, isRasterization: true, ref lightDimensions, ref m_ScreenSpaceShadowIndex, ref m_ScreenSpaceShadowChannelSlot, ref lightData);
23742374

23752375
// Add the previously created light data
23762376
m_lightList.lights.Add(lightData);
@@ -2938,7 +2938,8 @@ static void ClearLightLists( in BuildGPULightListParameters parameters,
29382938
// Note we clear the whole content and not just the header since it is fast enough, happens only in one frame and is a bit more robust
29392939
// to changes to the inner workings of the lists.
29402940
// Also, we clear all the lists and to be resilient to changes in pipeline.
2941-
ClearLightList(parameters, cmd, resources.tileAndClusterData.bigTileLightList);
2941+
if (parameters.runBigTilePrepass)
2942+
ClearLightList(parameters, cmd, resources.tileAndClusterData.bigTileLightList);
29422943
ClearLightList(parameters, cmd, resources.tileAndClusterData.lightList);
29432944
ClearLightList(parameters, cmd, resources.tileAndClusterData.perVoxelOffset);
29442945

com.unity.render-pipelines.high-definition/Runtime/Material/BuiltinUtilities.hlsl

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,9 @@ void InitBuiltinData(PositionInputs posInput, float alpha, float3 normalWS, floa
3838

3939
builtinData.opacity = alpha;
4040

41+
// Use uniform directly - The float need to be cast to uint (as unity don't support to set a uint as uniform)
42+
builtinData.renderingLayers = _EnableLightLayers ? asuint(unity_RenderingLayer.x) : DEFAULT_LIGHT_LAYERS;
43+
4144
// We only want to read the screen space buffer that holds the indirect diffuse signal if this is not a transparent surface
4245
#if RAYTRACING_ENABLED && (SHADERPASS == SHADERPASS_GBUFFER || SHADERPASS == SHADERPASS_FORWARD) && !defined(_SURFACE_TYPE_TRANSPARENT)
4346
if (_RaytracedIndirectDiffuse == 1)
@@ -54,12 +57,11 @@ void InitBuiltinData(PositionInputs posInput, float alpha, float3 normalWS, floa
5457
}
5558
else
5659
#endif
60+
{
61+
// Sample lightmap/probevolume/lightprobe/volume proxy
62+
builtinData.bakeDiffuseLighting = SampleBakedGI(posInput, normalWS, builtinData.renderingLayers, texCoord1.xy, texCoord2.xy);
63+
}
5764

58-
// Use uniform directly - The float need to be cast to uint (as unity don't support to set a uint as uniform)
59-
builtinData.renderingLayers = _EnableLightLayers ? asuint(unity_RenderingLayer.x) : DEFAULT_LIGHT_LAYERS;
60-
61-
// Sample lightmap/probevolume/lightprobe/volume proxy
62-
builtinData.bakeDiffuseLighting = SampleBakedGI(posInput, normalWS, builtinData.renderingLayers, texCoord1.xy, texCoord2.xy);
6365
// We also sample the back lighting in case we have transmission. If not use this will be optimize out by the compiler
6466
// For now simply recall the function with inverted normal, the compiler should be able to optimize the lightmap case to not resample the directional lightmap
6567
// however it may not optimize the lightprobe case due to the proxy volume relying on dynamic if (to verify), not a problem for SH9, but a problem for proxy volume.

0 commit comments

Comments
 (0)