Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Internal/master #8110

Merged
merged 85 commits into from
Nov 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
85 commits
Select commit Hold shift + click to select a range
2e86277
[RG] Render Graph Disable Pass Merging Debug Setting
gmitrano-unity Nov 1, 2024
60a1790
Fix for glclientwaitsync errors in powervr devices
satishdhanyamraju Nov 1, 2024
cad34f9
Enable URP reflection probe tests
belgaard Nov 1, 2024
34c9fc8
Fix APV assets missing from .unitypackage exports
pema99 Nov 2, 2024
63896ea
Remove Unnecessary RandomWrite Requirement in STP Shaders
gmitrano-unity Nov 2, 2024
0a2e150
[2d] Fix (Case UUM-85335) 2D Renderer Breaks When Animating Material …
venkify Nov 4, 2024
7ac77d6
Fix SSS Bleeding
alelievr Nov 4, 2024
9fe5f5b
[WebGPU] Test Updates and Bugfixes
christing12 Nov 4, 2024
18d83c0
[6000.1][UUM-83013][UUM-83351] Fix active buffers for overlay in Rend…
kennytann Nov 4, 2024
0188827
[URP][Volume] Fix GUID collision of default volume profile between te…
RSlysz Nov 4, 2024
45783a7
[6.1][URP] Foundation Project test fixes
ellioman Nov 5, 2024
0f7d0fc
[VFX] Custom attribute with same name as built-in attribute sanitize …
julienamsellem Nov 6, 2024
78b3cd4
Prevent eviction of light with preserveCachedShadow from cachedShadow…
laylaarab Nov 6, 2024
44be70b
[VFX] Compilation Optimisation - Speed-up string building
ludovic-theobald Nov 7, 2024
9055702
Add clamp to HairAngleWorld to prevent nan from FastASin
mseonkim-unity Nov 7, 2024
e30d813
Fix for HDRP entity water excluders
ApoorvaJ Nov 7, 2024
d9be71a
Fix DebugDisplay Camera list going beyond number of active cameras
ApoorvaJ Nov 7, 2024
7b86f28
[VFX] CustomHLSL Extend Arbitrary Buffer Support to Texture
PaulDemeulenaere Nov 7, 2024
de9e5f6
[VFX] Fix subgraph block nesting
julienf-unity Nov 8, 2024
9596375
Fix Vulkan URP 2D crash on some android devices
brendan-duncan Nov 8, 2024
e786b0c
Docs/graphics/docg 5740 ray tracing troubleshooting 1
ocarrere Nov 8, 2024
6af9129
[VFX] Compilation Optimisation - Cache implicit blocks
ludovic-theobald Nov 8, 2024
5ff8a6e
[HDRP] Assertion printed when Maximum Reflection Probe count is highe…
YvainRaeymaekers Nov 8, 2024
1149858
[HDRP] Fix building errors in water samples
remi-chapelain Nov 8, 2024
15bb643
[HDRP] Empty template starts with incorrect Physically Based Sky (inc…
SuminCho1 Nov 11, 2024
540478b
Graphics: Refactor shader code of dynamic branching fog in URP
karasusan Nov 11, 2024
ac554d8
Graphics: Use Reflection to fix compiling error when using old URP co…
karasusan Nov 11, 2024
a3a3801
Add dynamic resolution / upscaling docs page
markg-unity Nov 11, 2024
5d2d7e6
Fix Depth attachment texture for DX11
cprasad-rythmos Nov 12, 2024
ba3c73c
[UUM-67179] fixed the crash happening when APV tries to stream in blo…
katana7755 Nov 13, 2024
0cee6f1
[HDRP] Better material creation for PBR Sky Custom Material
remi-chapelain Nov 13, 2024
64cc7a8
Fix the RenderGraphPass clear function not working correctly.
Charles-H-Unity Nov 13, 2024
e6b9643
[URP] Fixing an issue where Transparent Receive Shadows toggle wasn't…
ellioman Nov 13, 2024
e6dfbc2
Multiview Per View Viewports Part 2
janice-see Nov 14, 2024
e027ad3
Fix URP Lit shader for mobile WebGL
brendan-duncan Nov 14, 2024
39a711c
[SRPF] Fixed key duplication exception for Render Grah Viewer
kirill-titov-u Nov 14, 2024
ace5e19
[VFX] Added support for CustomRenderTexture in our object property field
julienamsellem Nov 15, 2024
1245ff9
Fix picking and outline for all BatchRendererGroup draw types
JussiKnuuttila Nov 16, 2024
f3b2f2e
docg-5833-mask-and-current-water-decals
ocarrere Nov 16, 2024
d7ee228
[VFX] Add a button to install learning templates
julienamsellem Nov 16, 2024
bd8530f
Add documentation for shadow matte interaction with stencil shadows
KEngelstoft Nov 16, 2024
d6363d9
Graphics/SRP/RPF - [UUM-87121] - STP is disabled when TAA is disabled
axoloto Nov 16, 2024
fc5bd6e
[VFX][Optimisation] Optimise Attribute Layout to avoid holes and redu…
ludovic-theobald Nov 18, 2024
4732e58
Bind dummy depth texture for MRT in Volumetric Clouds Combine pass
MinseokLee-Unity Nov 18, 2024
4f19139
[HDRP] Fix errors when building XR player with Water samples
MinseokLee-Unity Nov 18, 2024
691ed29
[VFX] Exception Using ArcTorus & VFXParameter Controller
PaulDemeulenaere Nov 19, 2024
350bc93
[VFX][Optimisation] Threaded LocalToWorld cache
ludovic-theobald Nov 19, 2024
b55494a
[VFX/SG] Fix FogNode usage in URP
PaulDemeulenaere Nov 19, 2024
44aba84
HDRP Composition Layer fixes
joao-maia-u3d Nov 20, 2024
9b33768
[VFX] Allow properties to be reordered inside a category
julienamsellem Nov 20, 2024
015883b
Use correct per-eye world space position when sampling APV in HDRP
pema99 Nov 20, 2024
79fa650
UUM-86959: Fix environement lighting not updated when running in play…
YvainRaeymaekers Nov 20, 2024
e39271f
https://jira.unity3d.com/browse/DOCG-4866
ocarrere Nov 20, 2024
16cbdee
[VFX] Label are not visible when node is collapsed
julienamsellem Nov 21, 2024
833b471
Graphics/SRP/RPF - [UUM-87865] Make SetViewAndProjectionMatrices() av…
axoloto Nov 21, 2024
6e26f6c
reduce package list to minimal for BRG tests
arnaudcarre Nov 21, 2024
6b702f2
Fixed shader global state invalid when using override camera renderin…
alelievr Nov 21, 2024
f4a4f02
Fix Final Depth Copy Parameters & Unnecessary Scene View Prepass
gmitrano-unity Nov 21, 2024
fccd3d4
RenderGraph - Improve maximum number of resources allocated
YohannVaastUnity Nov 22, 2024
841fe0f
[Render Graph Viewer]Properly show the values for clear and bindMs
alex-vazquez-unity3d Nov 22, 2024
77986f6
Revert Changes from UUM-29958
RoseHirigoyen Nov 22, 2024
f5ae94f
[VFX] Compilation Optimisation - Change attributes manager to use dic…
ludovic-theobald Nov 22, 2024
5fa6a37
UUM-78573: "Bake Probe Volumes" button does not store that lights are…
pema99 Nov 22, 2024
eb5649b
[HDRP] Fix decal projector material creation
remi-chapelain Nov 22, 2024
e33e6ae
Move Graphics Test Framework to Standard Path
giorgospetkakis Nov 22, 2024
f149172
[VFX] In some specific circumstances, an exception can prevent openin…
julienamsellem Nov 23, 2024
f56798b
[editor] Fixed scene filtering with rendergraph not working on metal
alexey-unity Nov 23, 2024
9869ee0
Fixed compute shader for baking probe volumes
Adrian1066 Nov 23, 2024
29d7721
Variable Rate Shading SRP Core + URP
eh-unity Nov 25, 2024
119ae90
[SRPF] Hide test shaders for stripping
alex-vazquez-unity3d Nov 26, 2024
3fde051
docg-4247: Fix broken link
ocarrere Nov 26, 2024
d244235
docg-5758: Remove link to AOV Recorder
ocarrere Nov 26, 2024
8c2a6ef
Leak Detected message appears in Play Mode with High-Definition 3D Te…
SuminCho1 Nov 26, 2024
c882549
[UUM-73947] Added SS Shadow coord transform to TransformWorldToShadow…
mseonkim-unity Nov 27, 2024
2f6a854
Graphics: Remove the reflection code in runtime with the preprocessor
karasusan Nov 27, 2024
0d322a6
Fix for complex lit base shader being interpreted as the wrong shader…
lpledouxUnity Nov 27, 2024
e57e24d
Add additional checks to show the HDRP wizard.
alex-vazquez-unity3d Nov 27, 2024
ee94826
Docs/graphics/docg 5180: fix typos
ocarrere Nov 27, 2024
0715933
DOCG-5973 linear gradient, DOCG-4959 VFX snippet "position" capitaliz…
oleks-k Nov 27, 2024
08268fb
Graphics docs feedback fixes November 2024 (part 1)
markg-unity Nov 28, 2024
1636e87
Graphics docs feedback fixes November 2024 (part 2)
markg-unity Nov 28, 2024
cab799a
[URP Foundation] Reenable 190_SampleDepth
theopnv Nov 28, 2024
4adbf9c
[Switch] [SRP] [Tests] Enable Asserts for Switch SRP tests on Yamato …
Wilfrid-Unity Nov 28, 2024
99295dd
docg-5996: Add note about Detail Mask and clarify description
ocarrere Nov 28, 2024
15f0495
Graphics docs feedback fixes November 2024 (part 3)
markg-unity Nov 28, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ This page covers the process of how to use the RenderGraph API to write a render
To begin, your render pipeline needs to maintain at least one instance of [RenderGraph](../api/UnityEngine.Rendering.RenderGraphModule.RenderGraph.html). This is the main entry point for the API. You can use more than one instance of a render graph, but be aware that Unity does not share resources across `RenderGraph` instances so for optimal memory usage, only use one instance.

```c#
using UnityEngine.Rendering;
using UnityEngine.Rendering.RenderGraphModule;

public class MyRenderPipeline : RenderPipeline
Expand All @@ -21,8 +22,11 @@ public class MyRenderPipeline : RenderPipeline
void CleanupRenderGraph()
{
m_RenderGraph.Cleanup();
m_RenderGraph = null;
m_RenderGraph = null;
}

...

}
```

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,9 @@ class CommandBufferGenerator
new FunctionInfo("SetFoveatedRenderingMode", textureArg: "", modifiesGlobalState: true),
new FunctionInfo("ConfigureFoveatedRendering", textureArg: "", modifiesGlobalState: true),
new FunctionInfo("SetWireframe", textureArg: "", modifiesGlobalState: true),
};
new FunctionInfo("SetShadingRateFragmentSize", textureArg: "", modifiesGlobalState: false),
new FunctionInfo("SetShadingRateCombiner", textureArg: "", modifiesGlobalState: false),
};

// Functions for unsafe (wrapper around Commandbuffer) only
static List<FunctionInfo> unsafeFunctions = new List<FunctionInfo> {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#pragma only_renderers d3d11 playstation xboxone xboxseries vulkan metal
#pragma only_renderers d3d11 playstation xboxone xboxseries vulkan metal webgpu
#define UNIFIED_RT_GROUP_SIZE_X 64
#define UNIFIED_RT_GROUP_SIZE_Y 1

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
using System;
using System.Collections.Generic;
using System.IO;
using System.Runtime.CompilerServices;
using Unity.Collections;
using UnityEditor;
Expand All @@ -8,7 +9,7 @@
using UnityEngine.LightTransport.PostProcessing;
using UnityEngine.Rendering.Sampling;
using UnityEngine.Rendering.UnifiedRayTracing;

using UnityEngine.SceneManagement;
using TouchupVolumeWithBoundsList = System.Collections.Generic.List<(UnityEngine.Rendering.ProbeReferenceVolume.Volume obb, UnityEngine.Bounds aabb, UnityEngine.Rendering.ProbeAdjustmentVolume volume)>;

namespace UnityEngine.Rendering
Expand Down Expand Up @@ -584,13 +585,16 @@ public void Dispose()
}
}

// The contribution from all Baked and Mixed lights in the scene should be disabled to avoid double contribution.
static void UpdateLightStatus()
{
var lightingSettings = ProbeVolumeLightingTab.GetLightingSettings();

// The contribution from all Baked and Mixed lights in the scene should be disabled to avoid double contribution.
var lights = Object.FindObjectsByType<Light>(FindObjectsSortMode.None);
foreach (var light in lights)
var sceneLights = new Dictionary<Scene, List<Light>>();

// Modify each baked light, take note of which scenes they belong to.
var allLights = Object.FindObjectsByType<Light>(FindObjectsSortMode.None);
foreach (var light in allLights)
{
if (light.lightmapBakeType != LightmapBakeType.Realtime)
{
Expand All @@ -600,6 +604,56 @@ static void UpdateLightStatus()
bakingOutput.mixedLightingMode = lightingSettings.mixedBakeMode;
light.bakingOutput = bakingOutput;
}

// Take note of the lights from each scene
var scene = light.gameObject.scene;
if (!sceneLights.TryGetValue(scene, out var sceneLightList))
{
sceneLightList = new List<Light>();
sceneLights.Add(scene, sceneLightList);
}
sceneLightList.Add(light);
}

// Now we make the modifications persistent by modifying Lighting Data Assets (LDA) on disk.
string ldaFolderPath = Path.GetDirectoryName(AssetDatabase.GetAssetPath(m_BakingSet));
for (int i = 0; i < m_BakingSet.sceneGUIDs.Count; i++)
{
string guid = m_BakingSet.sceneGUIDs[i];
Scene scene = SceneManager.GetSceneByPath(AssetDatabase.GUIDToAssetPath(guid));
if (!scene.isLoaded)
continue;

LightingDataAsset prevLDA = Lightmapping.GetLightingDataAssetForScene(scene);
LightingDataAsset newLDA = prevLDA;

// If the scene has no (modifiable) LDA, create a new one.
bool isDefaultLDA = prevLDA && prevLDA.hideFlags.HasFlag(HideFlags.NotEditable);
if (prevLDA == null || isDefaultLDA)
{
newLDA = new LightingDataAsset(scene);
}

// Update the LDA with the new light settings
if (sceneLights.TryGetValue(scene, out var lights))
newLDA.SetLights(lights.ToArray());
else
newLDA.SetLights(Array.Empty<Light>());

// If the scene was using the builtin/default LDA before, copy over environment lighting, so it doesn't change.
if (prevLDA != null)
{
newLDA.SetAmbientProbe(prevLDA.GetAmbientProbe());
newLDA.SetDefaultReflectionCubemap(prevLDA.GetDefaultReflectionCubemap());
}

// Save the LDA to disk and assign it to the scene.
if (newLDA != prevLDA)
{
string ldaPath = $"{ldaFolderPath}/LightingData-{i}.asset".Replace('\\', '/');
AssetDatabase.CreateAsset(newLDA, ldaPath);
Lightmapping.SetLightingDataAssetForScene(scene, newLDA);
}
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1234,7 +1234,7 @@ static void FixSeams(NativeArray<int> positionRemap, NativeArray<Vector3> positi
// the dilation process consits in doing a trilinear sample of the higher subdivision brick and override the lower subdiv with that
// We have to mark the probes on the boundary as valid otherwise leak reduction at runtime will interfere with this method


// Use an indirection structure to ensure mem usage stays reasonable
VoxelToBrickCache cache = new VoxelToBrickCache();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,10 @@
using UnityEditor.Build.Reporting;
using UnityEngine;
using UnityEngine.Rendering;
using UnityEngine.SceneManagement;

namespace UnityEditor.Rendering
{
class ProbeVolumeBuildProcessor : BuildPlayerProcessor, IProcessSceneWithReport
class ProbeVolumeBuildProcessor : BuildPlayerProcessor, IPostprocessBuildWithReport
{
const string kTempAPVStreamingAssetsPath = "TempAPVStreamingAssets";

Expand All @@ -18,15 +17,27 @@ string GetTempAPVStreamingAssetsPath()
return Path.Combine(libraryPath, kTempAPVStreamingAssetsPath);
}

void PrepareStreamableAsset(ProbeVolumeStreamableAsset asset, string basePath, bool useStreamingAsset)
// Include an asset in the build. The mechanism for doing so depends on whether we are using StreamingAssets path.
static void IncludeStreamableAsset(ProbeVolumeStreamableAsset asset, string basePath, bool useStreamingAsset)
{
asset.UpdateAssetReference(useStreamingAsset);

if (useStreamingAsset)
{
asset.ClearAssetReferenceForBuild();
CopyStreamableAsset(asset, basePath);
}
else
{
asset.EnsureAssetLoaded();
}
}

// Ensure that an asset is not included in the build.
static void StripStreambleAsset(ProbeVolumeStreamableAsset asset)
{
asset.ClearAssetReferenceForBuild();
}

void CopyStreamableAsset(ProbeVolumeStreamableAsset asset, string basePath)
static void CopyStreamableAsset(ProbeVolumeStreamableAsset asset, string basePath)
{
var assetPath = asset.GetAssetPath();
if (!File.Exists(assetPath))
Expand Down Expand Up @@ -60,6 +71,9 @@ void GetProbeVolumeProjectSettings(BuildTarget target, out bool supportProbeVolu
}
}

// Keep track of which assets we touched during the build, so we can restore them after the build.
private static HashSet<ProbeVolumeBakingSet> s_BakingSetsProcessedLastBuild = new();

public override void PrepareForBuild(BuildPlayerContext buildPlayerContext)
{
GetProbeVolumeProjectSettings(buildPlayerContext.BuildPlayerOptions.target, out bool supportProbeVolume, out var maxSHBands);
Expand Down Expand Up @@ -89,16 +103,15 @@ public override void PrepareForBuild(BuildPlayerContext buildPlayerContext)

Directory.CreateDirectory(tempStreamingAssetsPath);

HashSet<ProbeVolumeBakingSet> processedBakingSets = new HashSet<ProbeVolumeBakingSet>();

s_BakingSetsProcessedLastBuild.Clear();
foreach (var scene in buildPlayerContext.BuildPlayerOptions.scenes)
{
var sceneGUID = AssetDatabase.AssetPathToGUID(scene);
var bakingSet = ProbeVolumeBakingSet.GetBakingSetForScene(sceneGUID);
if (bakingSet != null)
{
// Already processed (different scenes can belong to the same baking set).
if (processedBakingSets.Contains(bakingSet))
if (s_BakingSetsProcessedLastBuild.Contains(bakingSet))
continue;

if (!bakingSet.cellSharedDataAsset.IsValid()) // Not baked
Expand All @@ -111,89 +124,53 @@ public override void PrepareForBuild(BuildPlayerContext buildPlayerContext)

bool useStreamingAsset = !GraphicsSettings.GetRenderPipelineSettings<ProbeVolumeGlobalSettings>().probeVolumeDisableStreamingAssets;

PrepareStreamableAsset(bakingSet.cellSharedDataAsset, basePath, useStreamingAsset);
PrepareStreamableAsset(bakingSet.cellBricksDataAsset, basePath, useStreamingAsset);
IncludeStreamableAsset(bakingSet.cellSharedDataAsset, basePath, useStreamingAsset);
IncludeStreamableAsset(bakingSet.cellBricksDataAsset, basePath, useStreamingAsset);
// For now we always strip support data in build as it's mostly unsupported.
// Later we'll need a proper option to strip it or not.
bool stripSupportData = true;
if (!stripSupportData)
PrepareStreamableAsset(bakingSet.cellSupportDataAsset, basePath, useStreamingAsset);
if (stripSupportData)
StripStreambleAsset(bakingSet.cellSupportDataAsset);
else
IncludeStreamableAsset(bakingSet.cellSupportDataAsset, basePath, useStreamingAsset);

foreach (var scenario in bakingSet.scenarios)
{
PrepareStreamableAsset(scenario.Value.cellDataAsset, basePath, useStreamingAsset);
IncludeStreamableAsset(scenario.Value.cellDataAsset, basePath, useStreamingAsset);
if (maxSHBands == ProbeVolumeSHBands.SphericalHarmonicsL2)
PrepareStreamableAsset(scenario.Value.cellOptionalDataAsset, basePath, useStreamingAsset);
PrepareStreamableAsset(scenario.Value.cellProbeOcclusionDataAsset, basePath, useStreamingAsset);
IncludeStreamableAsset(scenario.Value.cellOptionalDataAsset, basePath, useStreamingAsset);
else
StripStreambleAsset(scenario.Value.cellOptionalDataAsset);
IncludeStreamableAsset(scenario.Value.cellProbeOcclusionDataAsset, basePath, useStreamingAsset);
}

processedBakingSets.Add(bakingSet);
s_BakingSetsProcessedLastBuild.Add(bakingSet);
}
}

buildPlayerContext.AddAdditionalPathToStreamingAssets(tempStreamingAssetsPath, AdaptiveProbeVolumes.kAPVStreamingAssetsPath);
}

private static bool IsBundleBuild(BuildReport report, bool isPlaying)
{
// We are entering playmode, so not building a bundle.
if (isPlaying)
return false;

// Addressable builds do not provide a BuildReport. Because the Addressables package
// only supports AssetBundle builds, we infer that this is not a player build.
if (report == null)
return true;

return report.summary.buildType == BuildType.AssetBundle;
}

// This codepath handles the case of building asset bundles, i.e. not a full player build. It updates the references
// to individual data assets in the baking sets for each scene, such that the assets are included in the bundle.
public override int callbackOrder => 1;
public void OnProcessScene(Scene scene, BuildReport report)
public void OnPostprocessBuild(BuildReport report)
{
// Only run for bundle builds.
if (!IsBundleBuild(report, Application.isPlaying))
return;

// Only run when APV is enabled.
GetProbeVolumeProjectSettings(EditorUserBuildSettings.activeBuildTarget, out bool supportProbeVolume, out var maxSHBands);
if (!supportProbeVolume)
return;

// Reload the map from scene to baking set if we couldn't find the specific baking set.
if (ProbeVolumeBakingSet.sceneToBakingSet == null || ProbeVolumeBakingSet.sceneToBakingSet.Count == 0)
ProbeVolumeBakingSet.SyncBakingSets();

// Get the baking set for the scene.
var bakingSet = ProbeVolumeBakingSet.GetBakingSetForScene(scene.GetGUID());
if (bakingSet == null || !bakingSet.cellSharedDataAsset.IsValid())
if (s_BakingSetsProcessedLastBuild == null || s_BakingSetsProcessedLastBuild.Count == 0)
return;

bool useStreamingAsset = !GraphicsSettings.GetRenderPipelineSettings<ProbeVolumeGlobalSettings>().probeVolumeDisableStreamingAssets;
if (useStreamingAsset)
// Go over each asset reference we touched during the last build, make sure asset references are intact.
foreach (var bakingSet in s_BakingSetsProcessedLastBuild)
{
Debug.LogWarning(
"Attempted to build an Asset Bundle containing Adaptive Probe Volume data, but streaming assets are enabled. This is unsupported. " +
"To use Adaptive Probe Volumes with Asset Bundles, please check 'Probe Volume Disable Streaming Assets' under Graphics Settings.");
bakingSet.cellBricksDataAsset.EnsureAssetLoaded();
bakingSet.cellSharedDataAsset.EnsureAssetLoaded();
bakingSet.cellSupportDataAsset.EnsureAssetLoaded();
foreach (var scenario in bakingSet.scenarios)
{
scenario.Value.cellDataAsset.EnsureAssetLoaded();
scenario.Value.cellOptionalDataAsset.EnsureAssetLoaded();
scenario.Value.cellProbeOcclusionDataAsset.EnsureAssetLoaded();
}
}

// Update all the asset references.
bakingSet.cellSharedDataAsset.UpdateAssetReference(useStreamingAsset);
bakingSet.cellBricksDataAsset.UpdateAssetReference(useStreamingAsset);

bool stripSupportData = true;
if (!stripSupportData)
bakingSet.cellSupportDataAsset.UpdateAssetReference(false);

foreach (var scenario in bakingSet.scenarios)
{
scenario.Value.cellDataAsset.UpdateAssetReference(useStreamingAsset);
if (maxSHBands == ProbeVolumeSHBands.SphericalHarmonicsL2)
scenario.Value.cellOptionalDataAsset.UpdateAssetReference(useStreamingAsset);
scenario.Value.cellProbeOcclusionDataAsset.UpdateAssetReference(useStreamingAsset);
}
s_BakingSetsProcessedLastBuild.Clear();
}
}
}
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#pragma kernel DilateCell

#pragma only_renderers d3d11 playstation xboxone xboxseries vulkan metal switch
#pragma only_renderers d3d11 playstation xboxone xboxseries vulkan metal switch webgpu

#include "Packages/com.unity.render-pipelines.core/ShaderLibrary/Common.hlsl"
#include "Packages/com.unity.render-pipelines.core/ShaderLibrary/CommonLighting.hlsl"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
using System.Linq;
using System.Reflection;
using System.Collections.Generic;
using System.IO;
using UnityEditor;
using UnityEditor.Rendering;
using UnityEditor.SceneManagement;
Expand Down Expand Up @@ -510,7 +511,9 @@ void SaveTempBakingSetIfNeeded()
string path = string.IsNullOrEmpty(scene.path) ?
ProbeVolumeBakingSet.GetDirectory("Assets/", "Untitled") :
ProbeVolumeBakingSet.GetDirectory(scene.path, scene.name);
path = System.IO.Path.Combine(path, activeSet.name + ".asset");
if (!Directory.Exists(path))
Directory.CreateDirectory(path);
path = Path.Combine(path, activeSet.name + ".asset");
path = AssetDatabase.GenerateUniqueAssetPath(path);

AssetDatabase.CreateAsset(activeSet, path);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
#pragma kernel VoxelizeProbeVolumeData
#pragma kernel Subdivide

#pragma only_renderers d3d11 playstation xboxone xboxseries vulkan metal switch
#pragma only_renderers d3d11 playstation xboxone xboxseries vulkan metal switch webgpu

// #pragma enable_d3d11_debug_symbols

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#pragma only_renderers d3d11 playstation xboxone xboxseries vulkan metal
#pragma only_renderers d3d11 playstation xboxone xboxseries vulkan metal webgpu switch
#define UNIFIED_RT_GROUP_SIZE_X 64
#define UNIFIED_RT_GROUP_SIZE_Y 1

Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading