[HDRP][Compositor] Do not allow users to directly reset/edit the compositor .asset file #1499
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Purpose of this PR
https://fogbugz.unity3d.com/f/cases/1265631/
https://fogbugz.unity3d.com/f/cases/1263319/
https://fogbugz.unity3d.com/f/cases/1265647/
The compositor .asset file contains values/settings that are auto-generated from the compositor runtime, and we don't expect/want users to reset this file or manually change the values in it (they should use the compositor UI for that) because it will get out-of-sync with the corresponding shader file.
Therefore this PR makes the .asset file not editable, so the "reset" option and the values in the asset are grayed-out:
Note: The compositor .asset files are useful when trying to share composition graphs and settings between two projects and this was the main idea behind their creation.
Also we now make sure that we don't throw any exceptions when the user manually deletes compositor resources from disk
(the compositor .asset or the shader graph file).
Testing status