Skip to content

Commit

Permalink
fix: TargetSet is not invalidated when GetTargetGroups context is inv…
Browse files Browse the repository at this point in the history
…alidated (#343)
  • Loading branch information
bdunderscore authored Aug 20, 2024
1 parent 587a73d commit 39a7dee
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Added

### Fixed
- [#343] TargetSet is not invalidated when GetTargetGroups context is invalidated

### Changed

Expand Down
4 changes: 1 addition & 3 deletions Editor/PreviewSystem/Rendering/TargetSet.cs
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Linq;
using nadena.dev.ndmf.cs;
using UnityEditor;
using UnityEditor.SceneManagement;
using UnityEngine;
using UnityEngine.Profiling;

Expand Down Expand Up @@ -39,6 +36,7 @@ public TargetSet(ImmutableList<IRenderFilter> filters)
if (!filter.IsEnabled(_targetSetContext)) continue;

var ctx = new ComputeContext("StageDescriptor for " + filter);
ctx.Invalidates(_targetSetContext);

Profiler.BeginSample("TargetSet.GetTargetGroups[" + filter + "]");
var groups = filter.GetTargetGroups(ctx);
Expand Down

0 comments on commit 39a7dee

Please sign in to comment.